Python | Dalle2 | Incorrect API key provided

Hey Everyone,
I’ve been trying to use Dalle2 through python for the past couple of days, but I keep getting this error:

“error”: {
“message”: “Incorrect API key provided: sess-uRY*****************************************QLVt. You can find your API key at OpenAI API”,
“type”: “invalid_request_error”,
“param”: null,
“code”: “invalid_api_key”
}

My key is correct. I saw this is a problem that’s been recurring, but haven’t seen any solution that worked for me (clearing cache, relogging…)

Does anyone have an idea to fix this?

Thanks!

I thought API keys all started with a “sk-” instead of “sess-”.
I might be wrong though, I haven’t used dalle apis yet.

Keys starting with “sk*” seems correct as well.

OpenAI API is where I find my account keys.