Get an OpenAI API Key

Generate an OpenAI API key, fund the account, and wire it into m18t encrypted in the Vault. One key serves every brand in the workspace.

What you'll learn

  • How to generate an API key in OpenAI's developer platform.
  • How to wire it into m18t through the connection wizard, encrypted in the Vault.
  • How to confirm it works.

Why you need this

m18t uses OpenAI for AI-driven work like image generation in the Graphics Generator and text drafting. Because m18t is BYOK, it doesn't supply the tokens — you bring your own key and pay OpenAI directly, with no markup. Until a key is in place, the AI surfaces stay disabled with a tooltip.

Step 1 — Generate the key at OpenAI

The provider's dashboard changes over time, so these steps are described by intent rather than exact pixels:

  1. Sign in at platform.openai.com.
  2. Fund the account. OpenAI's API is prepaid — find the billing section and add a payment method or balance. With a zero balance, API calls fail regardless of m18t setup. While you're there, set a hard monthly spend cap; m18t does not throttle your usage for you.
  3. Open the API keys area and create a new secret key. Give it a recognisable name like m18t-studio.
  4. Copy the key the moment it appears (it usually starts with sk-). OpenAI shows the full value once — if you lose it, you generate a new one.

Step 2 — Add it to m18t

In m18t, you don't paste keys into scattered config boxes — you go through the connection wizard, which stores the key in the encrypted Vault and links it to a brand in one pass.

  1. Go to Business Settings → Connections (/studio/business/connections).
  2. Click Add Connection. The wizard opens.
  3. Pick a brand. The connection record is filed under a brand, which is how it appears in that brand's connection list and health checks.
  4. Pick a provider — under AI Providers, choose OpenAI.
  5. On the setup step, set the Environment (Production/Development/Local), confirm the Label, and leave the Base URL at its default unless you proxy OpenAI. Read the Purpose note below before setting one.
  6. On the Authentication step, choose + Add new vault key. The wizard suggests the name OPENAI_API_KEY; paste your sk- value. It's encrypted before it touches the database and saved as vault:OPENAI_API_KEY.
  7. Finish with Create connection.

One key serves the whole workspace. Unlike a Facebook Page or a CMS, which really are wired per brand, m18t's AI features read a single workspace-level OPENAI_API_KEY from the Vault. Whichever brand you file the connection under, every brand uses that same key, so you do not need to repeat this for your other brands.

Careful with Purpose. Purpose filters which features can see a connection, but it does not select between keys: text and image generation both read the same OPENAI_API_KEY. Setting Purpose to text therefore hides the connection from image features without giving them another key to use. Leave it unset unless you are deliberately splitting work across providers.

Step 3 — Confirm it works

On the Connections tab, find the OpenAI card and run its test action.

Read the result carefully. The test asks OpenAI to list the models your key can see, which proves the key is real and accepted. It is not proof that your account can actually generate, since listing models and generating are billed differently. If the test passes but AI features still fail, check your OpenAI balance before touching the key. The honest end-to-end check is to use one real AI feature and see it return something.

Variations

  • Already stored the key? Skip the inline add — on the Authentication step, pick the existing OPENAI_API_KEY from the list.
  • Separate keys for text and images? Not supported today. Both paths read OPENAI_API_KEY, so a second key on another connection is never reached.
  • Multiple brands, one OpenAI account? Nothing extra to do. The AI key is workspace-wide, so one setup covers every brand.

FAQ

My key isn't working — the test fails. The two usual causes: the OpenAI account has a zero balance (top it up and set a cap), or the pasted value was truncated. Re-copy the key at OpenAI, rotate it on the Vault tab, and test again.

The AI buttons are still greyed out. The AI gate is workspace-wide, so filing another connection under a different brand will not change it. Check that the connection exists and shows as healthy, and that its Purpose isn't restricting it to a kind of task the feature doesn't want.

Where did my raw key go? I can't see it anymore. That's by design. The Vault shows only the reference name; the value is encrypted and never displayed again.

Do I have to use OpenAI? No. m18t also supports Gemini and Anthropic. Pick whichever you have an account with, or wire several.

What's next

Was this article helpful?