Home/BYOK AI

BYOK AI: Use Your Own API Key with Any OpenAI-Compatible Tool

One JuiceFactory key. EU-hosted inference. Works in Cursor, n8n, Continue, Cline, LangChain — anywhere that takes an OpenAI-compatible base URL.

No per-tool subscriptions. No US data routing. Change one config value.

BYOK (Bring Your Own Key) is the pattern where you plug your inference provider's API key into a third-party tool instead of using that tool's built-in AI subscription. The tool sends requests to your provider's endpoint — in this case, our EU servers in Sweden — rather than to OpenAI's US infrastructure.

The practical upshot: your code editor, your automation workflows, your data pipelines all run against EU-hosted, zero-retention inference with a single API key and a single bill. No more "which tool is shipping my prompts where."

Quick start: two lines of change

Grab a key from portal.juicefactory.ai then swap your base URL. That's it.

Python
import openai

client = openai.OpenAI(
    base_url="https://api.juicefactory.ai/v1",
    api_key="jf-your-key-here",  # from portal.juicefactory.ai
)

response = client.chat.completions.create(
    model="qwen3-235b-a22b",   # or any model in your plan
    messages=[{"role": "user", "content": "Hello from the EU!"}],
)
print(response.choices[0].message.content)
TypeScript / Node
import OpenAI from 'openai';

const client = new OpenAI({
  baseURL: 'https://api.juicefactory.ai/v1',
  apiKey: process.env.JUICEFACTORY_API_KEY,
});

const response = await client.chat.completions.create({
  model: 'qwen3-235b-a22b',
  messages: [{ role: 'user', content: 'Hello from the EU!' }],
});
console.log(response.choices[0].message.content);

The openai SDK is the only client you need — no JuiceFactory SDK, no wrapper libraries.

Supported tools

Any tool with an OpenAI-compatible custom endpoint option works. Here are the ones we've tested and documented.

Cursor
AI code editor
guide

Settings → Models → OpenAI-compatible → paste base_url + key

Setup guide →
n8n
Workflow automation
guide

OpenAI node → custom base URL credential

Setup guide →
Continue
VS Code / JetBrains AI
guide

config.json → provider: "openai", apiBase, apiKey

Setup guide →
Cline
Autonomous coding agent
guide

Settings → API Provider: OpenAI Compatible → base URL + key

Setup guide →
LangChain
LLM orchestration framework

ChatOpenAI(base_url=..., api_key=...)

LlamaIndex
Data framework for LLMs

OpenAI(api_base=..., api_key=...) or OpenAILike()

Why BYOK with JuiceFactory

EU data, always

Prompts from every tool route to Sweden. No US routing, no CLOUD Act exposure. Works for teams in regulated industries where data residency is non-negotiable.

One key, unified billing

Replace per-tool AI subscriptions with one usage-based API bill. Tag keys by tool for cost attribution. No surprise per-seat fees when your team grows.

Model choice

Pick Qwen, Llama, Mistral, or embedding models — not whatever the tool vendor negotiated. Try new models without waiting for tool updates.

More BYOK resources

FAQ

What does BYOK actually mean?

Bring Your Own Key means you use your own API credential (issued by JuiceFactory) with third-party tools instead of, or alongside, the tool's own AI subscription. So Cursor uses your JuiceFactory key to call our EU endpoint instead of routing through OpenAI's US servers. You pay JuiceFactory directly for inference; the tool just talks to our API.

Why would I BYOK instead of using the tool's built-in AI?

Three reasons: (1) Data sovereignty — your prompts go to Sweden, not US datacenters. (2) Cost control — one usage-based API bill instead of per-seat subscriptions for each tool. (3) Model choice — you pick from our full model catalogue including Qwen, Llama, Mistral variants, and others, rather than being locked to whatever the tool vendor has negotiated.

Does the tool need to support OpenAI-compatible APIs?

Yes. If the tool has a "custom base URL" or "OpenAI-compatible" option, it will work with JuiceFactory. We expose the full OpenAI REST schema: /v1/chat/completions, /v1/embeddings, /v1/models, streaming, function calling, and JSON mode. If a tool only supports proprietary providers, BYOK won't apply.

Is one key really enough for all my tools?

One key works across all tools simultaneously — there is no per-tool registration. If you want cost attribution or rate limits per tool, you can create separate keys in the portal and label them (Cursor key, n8n key, etc.) at no extra cost. Each key maps to the same billing account.

What happens to my prompts when I use BYOK with Cursor or n8n?

Prompts travel from the tool to our EU inference endpoint over TLS. They are processed in memory and not persisted after the response is returned. Zero retention is guaranteed by our DPA. The tool vendor never sees the raw inference request — only you and our API endpoint are in the path.

Get your key, configure your tool

Free tier available. Cursor setup takes under 3 minutes. Your prompts stay in the EU.