Prompty Authentication in Python runtime #147
Unanswered
eightfold999
asked this question in
Q&A
Replies: 0 comments
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
-
Hi,
I have the prompty extension installed in VSCode and can open a .prompty file and run it successfully. It returns what I expect. When I try and run the same .prompty file in python in the same folder with the prompty.execute function I get
openai.AuthenticationError: Error code: 401 - {'error': {'code': 'PermissionDenied', 'message': 'Principal does not have access to API/Operation.'}}
I have added Cognitive Services OpenAI User and Contributor to all the accounts I think it might be using but I'm not logged into VSCode or the terminal and it does not prompt me for an account.
How can I tell which account its trying to use?
How do I specify credentials to run the prompty as?
Do I need to do anything specific in the python code? All the examples just show using execute with no authentication code?
Beta Was this translation helpful? Give feedback.
All reactions