One API for every model that is live.
Use familiar OpenAI SDKs, discover the verified model catalog at runtime, and stream responses through one endpoint.
https://ai.developpeurcasablanca.com/v1
Authentication
Send your developer key as a Bearer token with every request.
Never expose a developer key in browser JavaScript, a mobile bundle or a public repository.
Authorization: Bearer dk_your_key_here
Quickstart
Replace the placeholder key and model with values from your account.
curl https://ai.developpeurcasablanca.com/v1/chat/completions \
-H "Authorization: Bearer dk_your_key_here" \
-H "Content-Type: application/json" \
-d '{
"model": "your-model-id",
"messages": [
{"role": "user", "content": "Hello"}
]
}'
from openai import OpenAI
client = OpenAI(
api_key="dk_your_key_here",
base_url="https://ai.developpeurcasablanca.com/v1",
)
reply = client.chat.completions.create(
model="your-model-id",
messages=[{"role": "user", "content": "Hello"}],
)
print(reply.choices[0].message.content)
Do not hard-code a guessed model name: call GET /v1/models and use an ID returned for your key.
GET /v1/models
Returns only enabled models currently available to the provider keys behind the service.
curl https://ai.developpeurcasablanca.com/v1/models \
-H "Authorization: Bearer dk_your_key_here"
{
"object": "list",
"data": [{
"id": "model-id",
"object": "model"
}]
}
POST /v1/chat/completions
Create a response with the same request shape used by OpenAI chat completions.
modelRequiredA model ID returned by /v1/models.
messagesRequiredAn ordered list of role and content objects.
streamOptionalSet true to receive incremental server-sent events.
Streaming
Set stream to true to start receiving tokens as soon as they are generated.
stream = client.chat.completions.create(
model="your-model-id",
messages=[{"role": "user", "content": "Write a haiku"}],
stream=True,
)
for chunk in stream:
print(chunk.choices[0].delta.content or "", end="")
Errors
Errors use standard HTTP status codes and a JSON error message.
| Status | Meaning | What to do |
|---|---|---|
400 | Invalid request | Check the JSON fields and model ID. |
401 | Missing or invalid key | Create or replace your developer key. |
402 | Insufficient credit | Add prepaid API credit in your account. |
429 | Too many requests | Retry with exponential backoff. |
5xx | Temporary service problem | Retry safely after a short delay. |
Ready to make your first call?
Create an account, issue a developer key, then discover the live models available to it.