How do I detect if the current workspace is the development workspace? I our case, the development workspace has different ID’s depending on the developer…
Thank you for your answer.
In my search for the environment variable “TOKEN” that the documentation is mentioning for the API class, I came across an environment variable called “ENVIRONMENT” where the value is “development” in development and “production” in production. Is there a reason why you did not recommend that one?
So the solution can be: os.getenv("ENVIRONMENT") == "development"
Hi @twj,
I wasn’t fully aware of this env variable, that should work fine. Although I’d say be cautious with it, as env variables could potentially be overwritten.
FYI, the ‘token’ variable is there, as it should be set to your Personal access token. This is required to authenticate your api calls.
1 Like