You'd be getting a different error if your key wasn't getting through at all. Can you double check that you're using the right OpenAI api key, have enough api credits (as distinct from chatgpt quota), and haven't hit any max spend limits? You can check here: https://platform.openai.com/account/api-keys