Skip to content
This repository has been archived by the owner on Aug 10, 2023. It is now read-only.

Incorrect API key provided #55

Closed
narakai opened this issue Dec 6, 2022 · 27 comments
Closed

Incorrect API key provided #55

narakai opened this issue Dec 6, 2022 · 27 comments

Comments

@narakai
Copy link

narakai commented Dec 6, 2022

Hi,

Thanks for the great work!
I have done !refresh and also try to login via my email & password, but still the error occurs:

{"detail":{"message":"Incorrect API key provided: Bearer. You can find your API key at https://beta.openai.com.","type":"invalid_request_error","param":null,"code":"invalid_api_key"}}
Something went wrong!
Response is not in the correct format.

Please kindly advice.

@superswan
Copy link
Contributor

Have you tried the latest commit?

@narakai
Copy link
Author

narakai commented Dec 6, 2022

yes, it's the latest commit.

@acheong08
Copy link
Owner

The service went down just now. It's back up

@acheong08
Copy link
Owner

Try again (with correct username and password)

@acheong08
Copy link
Owner

I haven't written handlers to check for validity of username and password

@zhwang4ai
Copy link

I also meet such problem right now.
'''
{"detail":{"message":"Incorrect API key provided: Bearer. You can find your API key at https://beta.openai.com.","type":"invalid_request_error","param":null,"code":"invalid_api_key"}}
'''

@acheong08
Copy link
Owner

Fixing right now

@acheong08
Copy link
Owner

@zhwang1694 @superswan
I can't replicate this. Can you try again?

@superswan
Copy link
Contributor

I get an error when attempting to authenticate with session key

@acheong08
Copy link
Owner

The API now blocks remote requests. I'm unsure if I can fix this

@moozilla
Copy link

moozilla commented Dec 6, 2022

I was able to fix this by adding a user agent header, will try to get a PR up

@acheong08
Copy link
Owner

Thank you so much

@zhwang4ai
Copy link

@acheong08 @moozilla Thanks a lot.

@acheong08
Copy link
Owner

Fixed

@moozilla
Copy link

moozilla commented Dec 6, 2022

Looks like you beat me to it: moozilla@de86da1

@acheong08
Copy link
Owner

Superfast panic mode lol

@narakai
Copy link
Author

narakai commented Dec 6, 2022

Works fine now, thanks guys!

@imcda
Copy link

imcda commented Dec 6, 2022

have update the latest version, but still got this error

{"detail":{"message":"Incorrect API key provided: Bearer. You can find your API key at https://beta.openai.com.","type":"invalid_request_error","param":null,"code":"invalid_api_key"}}

and another alert

Captcha detected

should I create a API from openAI, the type into the config.json?

@acheong08
Copy link
Owner

Captcha is not supported for this library as it requires writing to disk and having a desktop environment. Use https://github.com/rawandahmad698/PyChatGPT for proper Captcha support

@CheCoelho
Copy link

I am also having this issue - I pass in my correct configuration and get a return value with the error data: Request failed with status code 401 'Incorrect API key provided: sk----***************************************---. You can find your API key at https://beta.openai.com.'

@acheong08
Copy link
Owner

acheong08 commented Jan 13, 2023

You're meant to use the session_token cookie, not API key. Read https://github.com/acheong08/ChatGPT/wiki/Setup

@wxlund
Copy link

wxlund commented Mar 29, 2023

I am having the same error. I just updated to GenieAI but the API KEY from ChatGPT was lost in the process. I can not see where to input my API Key. It prompted me the first time but I had an error with the paste and I'm lost as to where to place the correct key. Mine shows:
`
An error occured. ChatGPT error 401: { "error": { "message": "Incorrect API key provided: Write a **********************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************ion.. You can find your API key at https://platform.openai.com/account/api-keys.", "type": "invalid_request_error", "param": null, "code": "invalid_api_key" } }' #

@acheong08
Copy link
Owner

For V3, use official API keys

@Okamiobidala
Copy link

Hi - So I have had this error message come up asking for a correct API key and giving me a place to find it, but when I follow the link I can't make and account or log into an existing account. I thought that I'd hit the jackpot when I found this thread but the solutions don't make sense to me - there are words and techniques I don't understand and I don't get why the app I payed for can just stop working like this : / Please - if you could - explain it to me like I'm five? I would be most grateful. - Thanks for reading

@acheong08
Copy link
Owner

Hi - So I have had this error message come up asking for a correct API key and giving me a place to find it, but when I follow the link I can't make and account or log into an existing account. I thought that I'd hit the jackpot when I found this thread but the solutions don't make sense to me - there are words and techniques I don't understand and I don't get why the app I payed for can just stop working like this : / Please - if you could - explain it to me like I'm five? I would be most grateful. - Thanks for reading

What version are you using?

@Okamiobidala
Copy link

Okamiobidala commented Apr 15, 2023 via email

@Okamiobidala
Copy link

Okamiobidala commented Apr 15, 2023 via email

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

9 participants