Error: Invalid or missing API key

Hi Guys,
What am I missing here?

Thanks
Alex

Hey @anikolaibackup! Could you please give some more information on how you and running oTToDev?

Hi @ColeMedin
thanks for replying
I followed the Read me and I try to run oTToDev in Docker
I can open Bolt but my Open Ai Api Key is not being recognized

Rename .env.local to just .env as it says on line 1 of that file.

1 Like

I did that too but I got the same error

not sure, if renaming it to “.env” will work. it should be “.env.local”.
UPDATE: I was wrong. “.env” works.

If you’re using docker it “should” reload the env file. If not, you certainly need to restart bolt (npm run dev)and refresh the browser.

1 Like

i will try that thanks

1 Like

I changed the .env from .env.local no luck

I am getting Grock to work but both OpenAI and Claude will not even though I have updated the above file and entered the key through Bolt

Make sure there are no quotation marks around your API keys.

My OpenAI key is 51 characters long and starts with sk-
My Anthropic key is 108 characters long and starts with sk-ant-api

Hey make sure the model names are accurate, in my case the provided model name for gpt-3.5-turbo does not exist anymore, it should be gpt-3.5-turbo-0125 and some models have limitation on max tokens allowed. Changing that fixed those issues for me.

1 Like