Preview · The API is in the works
Stabily in your platform – with just a few lines of code
Your teachers are already signed in on your platform? Then they can use Stabily straight away, without a second account. Our AI conflict coach comes to you as a simple web API.
- REST + JSON
- Servers in the EU
- OpenAPI (planned)
Available today
What Stabily can already do
Everything you see here is already live for teachers on stabily.ai, and it will come to you through the API step by step.
- Live in Stabily
AI conflict coach
Teachers describe a difficult situation. Stabily assesses it and suggests next steps – based on a curated knowledge base, with sources.
Via API at launch
- Live in Stabily
Guided intake
For a new case, Stabily first asks for the most important key facts, so that the recommendation really fits.
Via API later
- Live in Stabily
Action plan
The conversation turns into a plan with the situation, an assessment and next steps, also as a PDF to take away.
Via API at launch
- Live in Stabily
Worksheets
View and download suitable worksheets, or have Stabily adapt them for your own class.
Via API later
- Live in Stabily
Replacing names
If someone writes real names, Stabily automatically replaces them with “Person A”, “Person B” and so on.
Always included
- Live in Stabily
Safety first
If Stabily detects signs of a crisis, an emergency notice appears with the emergency number 112 and support services.
Always included
- Live in Stabily
Dictation and voice mode
Dictate your questions or have the whole conversation with Stabily by voice, right in the browser.
Via API later
- Live in Stabily
AI and servers in the EU
The answers are generated by AI models from Mistral AI in the EU; our server functions run in Frankfurt am Main.
Always included
In three steps
It’s that simple
Your teachers sign in to your platform and nowhere else. Your server talks to ours, and Stabily is there straight away.
- Step 1
Get a key
You get an API key for your server. It stays there and never reaches the browser.
- Step 2
Pass on the teacher’s ID
Your server sends your internal ID for the teacher. No name, no email, no second login.
- Step 3
Ask the coach
Question in, answer out: with sources, follow-up questions and, if needed, a safety notice.
Try it out
The four requests you’ll need most
Choose a request and a variant, look at the code, change it and send it. The answers are examples: nothing goes to a server here, and you can’t break anything.
Choose a request
Start without a second login
POSThttps://api.stabily.ai/v1/sessions
What’s happening here?
The teacher is already signed in on your platform. Your server asks Stabily for a one-time link and sends them there: they land straight in the chat, without an account or a password with us. As “user”, you send your internal ID, never an email address or a name.
Variant
The teacher is using Stabily for the first time: we set them up quietly in the background.
curl -X POST "https://api.stabily.ai/v1/sessions" \
-H "Authorization: Bearer $STABILY_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"user": "teacher-48151",
"return_url": "https://your-platform.example/courses/7b"
}'Try it out: delete a required field like “user”, enter an email address or add an unknown field.
Response
Demo answer – not a real requestPress “Send request” to see what the API sends back.
Understanding errors
When something goes wrong
Every error says clearly whether the problem is on your side or ours, and what to do next. If it’s on ours, our system tries again by itself, logs it and lets our team know – you don’t need to report anything.
Error on our side
Not your fault: we’re already on it. Keep the “incident_id” in case you want to ask us about it, and try again after “Retry-After”.
- Error detectedOur server notices straight away that something is wrong.
- Retried automaticallyIt tries again by itself before you notice anything.
- LoggedIf that doesn’t work, the error goes into our log with an ID.
- Team informedOur team is notified and takes care of it.
How the API responds500 Internal Server Error
Retry-After: 30
{
"error": {
"type": "server_error",
"code": "internal_error",
"message": "Something went wrong on our side – not on yours. We automatically tried again, logged the error and informed our team. You don’t need to report anything.",
"incident_id": "inc_7F3KQ9",
"retryable": true,
"retry_after": 30,
"logged": true,
"team_notified": true
}
}Built in, can’t be switched off
Safety comes first
If Stabily detects signs of a crisis, the answer carries an emergency notice. Your app always shows it in full, just like the Stabily chat.
- The “safety” field can’t be switched off.
- Stabily automatically replaces real names with placeholders such as “Person A”.
- The AI comes from Mistral AI in the EU; our servers run in Frankfurt am Main.
{
"safety": {
"signal": "selbstgefaehrdung",
"must_display": true,
"notice": {
"title": "If someone is in acute danger",
"text": "Don’t leave the person alone, get a responsible person to join you and call for help straight away in an emergency. You’ll find the numbers and support services for your country under “Open emergency help”.",
"emergency_number": "112",
"help_label": "Open emergency help",
"help_url": "https://stabily.ai/en/emergency-help"
}
}
}How to show it
If someone is in acute danger
Don’t leave the person alone, get a responsible person to join you and call for help straight away in an emergency.
Made for coding agents
Let your coding agent do the work
The API is built so that AI coding assistants understand it straight away. Copy the prompt, add your stack, and your first draft is ready.
- Clear JSON structuresThe same fields everywhere, meaningful names, no surprises.
- Unambiguous errorsEvery error has the same shape and a code, and says whether it’s worth trying again.
- OpenAPI and llms.txtA machine-readable description that your coding agent understands straight away (planned).
You are my coding agent. Integrate the Stabily API into our platform.
Setup:
- Base URL: https://api.stabily.ai/v1 (REST, JSON, answers optionally as server-sent events).
- The API key is in the environment variable STABILY_API_KEY. Use it only on our server: never in the browser, never in a log.
- As "user", we send our internal, opaque user ID for the teacher. No email address, no name.
Tasks:
1. A server route that calls POST /v1/sessions for the signed-in teacher and redirects them to the returned "url" (embedding without a second login).
2. A server function askCoach(userId, message) that calls POST /v1/conversations and returns the text, sources, answer options and "safety".
3. A UI component that shows the answer. If "safety" is not null, always show "safety.notice" in full: title, text, emergency number and the link to the emergency help.
4. Show "names_replaced" subtly below the teacher’s message ("Names replaced: Jonas → Person A").
Errors:
- Every error has the shape { "error": { "type", "code", "message", "request_id", "retryable" } }.
- Retry only if "retryable" is true: at most three times, with increasing delays (exponential backoff), and respect "Retry-After".
- For every error, log "request_id" (and "incident_id", if present), never the content of the message.
Tests:
- Write tests with mocked responses in the format of the examples at https://stabily.ai/en/developers, including 401, 422, 429 and 500.Outlook
What’s coming
This page is a preview. If you want to be on board early, write to us: the first partners help shape the API.
Developer workspace
Create your own keys, see your usage, invite your team.
Sandbox
Real requests with test data, without real teachers.
Live access
The coach, the action plan and embedding first, the rest will follow.
Pricing
We’ll discuss prices and terms with you personally.
Want to add Stabily to your platform?
Tell us briefly what you’re building. We’ll get back to you with the next steps and answer your technical questions.
or write directly to kiarash@stabilimkopf.com