Quickstart
Connect with OpenAI, Anthropic, or the AI SDK. Pick a method tab, set the base URL and API key, then call catalog models.
Setting up with an AI assistant (ChatGPT, Claude, Cursor)? Grab a copy-paste snippet (Markdown/JSON) from Set up with AIand paste it to your AI — that's it.
Get started in 3 steps#
- 1
Create an account
Sign up with email.
- 2
Top up credits
Local payments are coming soon — once live, you can add credits under Dashboard → Billing.
- 3
Issue an API key
Create a key starting with
plm_under Dashboard → API Keys and paste it into the code below.
Connect#
Choose AI SDK, Chat Completions, Messages, Responses, or Images. For the Anthropic SDK, use the root origin without /v1 (https://apirouter.pleum.ai). See AI SDK for the provider package.
chat.ts
OpenAI Chat Completions API
import OpenAI from "openai";
const client = new OpenAI({
apiKey: "plm_xxxxxxxxxxxxxxxx",
baseURL: "https://apirouter.pleum.ai/v1",
});
const response = await client.chat.completions.create({
model: "gpt-4.1",
messages: [{ role: "user", content: "Why is the sky blue?" }],
});
console.log(response.choices[0].message.content);OpenAI Chat Completions API
from openai import OpenAI
client = OpenAI(
api_key="plm_xxxxxxxxxxxxxxxx",
base_url="https://apirouter.pleum.ai/v1",
)
response = client.chat.completions.create(
model="gpt-4.1",
messages=[{"role": "user", "content": "Why is the sky blue?"}],
)
print(response.choices[0].message.content)OpenAI Chat Completions API
curl https://apirouter.pleum.ai/v1/chat/completions \
-H "Authorization: Bearer plm_xxxxxxxxxxxxxxxx" \
-H "Content-Type: application/json" \
-d '{
"model": "gpt-4.1",
"messages": [{"role": "user", "content": "Why is the sky blue?"}]
}'Chat Completions responses include a
cost field; Messages/Responses expose cost via X-Cost-* headers.