Skip to content

How to use your own OpenAI key (BYOK)

BYOK (“bring your own key”) routes all AI work — translation, step parsing, visual regression — through your own OpenAI account. Calls don’t count against your Marriska AI-creations or visual-compares quota; you pay OpenAI directly for the tokens.

For the why behind BYOK (price, latency, control), see The BYOK concept.

If you’re running the backend yourself (Docker Compose, your own infra), the platform-level OpenAI key is set via the OPENAI_API_KEY environment variable. Set it in your .env:

Terminal window
OPENAI_API_KEY=sk-...
PARSING_PROVIDER=openai
PARSING_MODEL=gpt-4o-mini
TRANSLATION_PROVIDER=openai
TRANSLATION_MODEL=gpt-4o-mini
VISUAL_COMPARISON_PROVIDER=openai
VISUAL_COMPARISON_MODEL=gpt-4o-mini

Restart the backend after editing the file. Provider and model defaults live in backend/app/config/settings.py.

See and change which providers your platform uses

Section titled “See and change which providers your platform uses”

Provider/model selection lives in the super-admin panel: Admin → LLM config. The panel shows which provider keys are configured (from the deploy’s environment) and which provider + model is assigned to each task — translation, parsing, and visual regression.

A super-admin can change the provider/model per task there at runtime: the choice is stored in the database and hot-reloaded across all workers within ~30s — no redeploy. Env vars supply the defaults until an admin overrides them. (This is deploy-wide platform config, not per-user — the per-user “bring your own key” surface is the separate, still-in-progress feature described in the callout above.)

When per-user BYOK ships, you’ll be able to:

  1. Open Settings → LLM Models
  2. Paste your OpenAI API key into a “Your OpenAI key” field
  3. Save — Marriska validates the key with a no-op call
  4. From that point, AI calls run against your key and don’t count against your quota

The Free plan will still get its 100 monthly AI creations on Marriska’s key as a starter pool; once configured, BYOK takes over and is unlimited.

  • Heavy AI users: stay below your tier’s monthly AI creations and visual compares limit (see Plan tier limits).
  • Hit the cap? Upgrade is the only path until per-user BYOK ships.
  • Self-hosters: use the env-var setup above; you’re already running on your own OpenAI key.