Retool's OpenAI API Key Is Failing

We've been using the Retool Vectors for a while now, but yesterday they all started failing with the following message. It's clear that the Retool / OpenAI api key has changed, but our app isn't getting the new key.

vectorize failed (66.268s):Error generating embeddings Error creating embedding: 401 Incorrect API key provided: 1e7f5374************************e463. You can find your API key at https://platform.openai.com/account/api-keys.

Tried create a new vector bucket - same error. It looks like Retool's API key was rotated by OpenAI and Retool has not updated their system.

Hey @mrgoynes! Welcome to the community. :slight_smile: Thanks for stopping by office hours this morning, as well.

Can you quickly check and confirm that none of the AI resources - other than the Retool managed ones - at https://your_domain.retool.com/resources/retool_ai have been configured? I was able to replicate the error that you're seeing by incorrectly configuring the OpenAI resource:

This is interesting. I've never been to this settings page before, and the "retool managed" is both "disabled" and "disable-able" at the same time.

I'm pretty sure adding your own OpenAI key automatically disables the Retool managed integration, meaning the error that you're seeing is with that specific configuration. :+1:

Sorry if I wasn't clear: we don't have an OpenAI key, so we haven't actually updated that screen. I'll verify that none of my colleagues did either.

In the meantime, I just toggled the disabled button on the "Retool managed" section, and that seems like it did it.

For anyone experiencing the same symptoms ("disabled" and "disable" states at the same time), just click the button a few times.

Glad to hear that it's working now! The screenshot that you shared above shows that a custom OpenAI integration is at least partially configured, which likely explains how the Retool managed version was disabled.