Get started
Quickstart
Top up your wallet, create an API key, and send your first request to deepseek-flash.
On this page
You need an account, a funded wallet, and an API key. There is no free credit, so your first request needs a top-up.
Create an account
Sign up in the console with your email and a password, then confirm your email address from the link we send you.
Top up your wallet
In the console, open Billing, choose an amount between $1.00 and $100.00, and scan the QRIS code with any Indonesian banking or e-wallet app. The invoice shows the exchange rate, the 1% admin fee, and the total in Rupiah before you pay. Your balance updates as soon as the payment is confirmed.
See Topping up with QRIS for the details.
Create an API key
Open API keys and select Create key. Give it a name, such as development, and optionally a monthly budget. Copy the key — it starts with lr_live_ and is shown only once.
Store it in an environment variable rather than in your code:
export LARAS_API_KEY="lr_live_your_key_here"
Send your first request
Point any OpenAI client at https://api.larasrouter.com/v1 and use the model deepseek-flash:
curl https://api.larasrouter.com/v1/chat/completions \
-H "Authorization: Bearer $LARAS_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"model": "deepseek-flash",
"messages": [
{"role": "user", "content": "Explain recursion in one short paragraph."}
]
}'
import os
from openai import OpenAI
client = OpenAI(
base_url="https://api.larasrouter.com/v1",
api_key=os.environ["LARAS_API_KEY"],
)
response = client.chat.completions.create(
model="deepseek-flash",
messages=[{"role": "user", "content": "Explain recursion in one short paragraph."}],
)
print(response.choices[0].message.content)
import OpenAI from "openai";
const client = new OpenAI({
baseURL: "https://api.larasrouter.com/v1",
apiKey: process.env.LARAS_API_KEY,
});
const response = await client.chat.completions.create({
model: "deepseek-flash",
messages: [{ role: "user", content: "Explain recursion in one short paragraph." }],
});
console.log(response.choices[0].message.content);
Install the SDK first if you use one: pip install openai for Python, npm install openai for Node.js.
What you get back
A standard Chat Completions response. The usage object is what your request is charged from:
{
"id": "chatcmpl-…",
"object": "chat.completion",
"created": 1760241600,
"model": "deepseek-flash",
"choices": [
{
"index": 0,
"message": {
"role": "assistant",
"content": "Recursion is when a function solves a problem by calling itself on a smaller part of it…"
},
"finish_reason": "stop"
}
],
"usage": {
"prompt_tokens": 14,
"completion_tokens": 120,
"total_tokens": 134,
"prompt_cache_hit_tokens": 0,
"prompt_cache_miss_tokens": 14
}
}
The response also carries an X-Laras-Request-ID header. Keep it if you need to ask us about a charge.