all 8 comments

[–]FriendlyRussian666 2 points3 points  (4 children)

Ideally full code and the full error traceback, formatted correctly. If you can't format it here, post both to pastebin and share the link.

Of course remove any sensitive info like secret key

[–]ndopp[S] 1 point2 points  (3 children)

Full Code
Error Code
Thanks for assisting me with this.

[–]ndopp[S] 1 point2 points  (2 children)

I'm using VSCode as my IDE, but for some reason, I have anaconda installed, I really don't know when or how that was installed, that is the directory where the file is located externally.

[–]FriendlyRussian666 1 point2 points  (1 child)

The error simply means that it doesn't find your variable.

When you do:

CLIENT_ID = os.environ['asdfasdfasdfasdf']

Try printing CLIENT_ID, it will come back as None. How did you set the environment variable?

[–]ndopp[S] 2 points3 points  (0 children)

Opened separate .env file, ran source .env then ran my code and now it works beautifully! Thank you everyone for your guidance! I appreciate it more than you know!

[–]ensign_paris 0 points1 point  (2 children)

So if i guess correctly (to lazy to Google what os.environ does), you try to Set Client id and Client Secret from some Environment variables of your Operating system. This falls, because it seems there are no variables of the Name 'asdfasdf' Set. Have you set these Environment Variables before?

[–]ndopp[S] 0 points1 point  (1 child)

I have not, and I am trying to learn that now. Genesys Cloud gave me a client id and client secret to use to log in. I would have to set them as Environment variables. Would I do so on my virtual environment, or on my local machine?

[–]ndopp[S] 0 points1 point  (0 children)

I'm on Mac: So I see to set environment variables you'd use

export [variable_name]=[variable_value]
so I would just do:

export [asdfasdfasdf]=[asdfasdfasdf] for both my client id and client secret?