26 May 2023 08:37 PM - last edited on 20 Aug 2024 02:57 PM by Michal_Gebacki
Hello,
I've written several scripts for various tasks with the Dynatrace API but updated security requirements are going to be prohibiting me from having our API token hard coded in the script. I was wondering how others have dealt with this... how I can pass a credential to the API without having it in the actual script that would satisfy our security team.
Thanks in advance for any thoughts on this.
-Jeff
Solved! Go to Solution.
27 May 2023 03:11 PM
Hi,
Maybe you can use environment variables or asking token in prompt.
Best regards
01 Jun 2023 02:36 PM
I'd second @AntonPineiro's response. If it's an interactive application, prompting the user is probably the safest approach. Otherwise, environment variables are also often used in this context (of course, you'll still need to make sure those are secure as well) or reading the values from a (possibly encrypted) database or configuration file.