Ask structured choice, yes/no, and ordered-score questions about a state. One request returns calibrated answers for every question.
Send your Arli AI API key as a bearer token to https://api.arliai.com/v1. Decision requests use the same account, plan, and parallel-request limits as text and image requests.
Authorization header
Authorization: Bearer $ARLIAI_API_KEYA request contains a state (the thing being reasoned about) and a map of questions. Each question has a type, optional instructions, and type-specific criteria.
cURL
curl -X POST https://api.arliai.com/v1/systemone \
-H "Authorization: Bearer $ARLIAI_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"model": "d3-flash",
"state": {
"ticket": "I was charged twice for the same order.",
"customer_tier": "pro"
},
"questions": {
"team": {
"type": "choice",
"instructions": "Which team should handle this?",
"criteria": {
"billing": "Payments, charges, and refunds",
"technical": "Bugs and outages"
}
},
"refund": {
"type": "noul",
"instructions": "Does the customer ask for a refund?"
},
"urgency": {
"type": "score",
"instructions": "How urgent is this?",
"criteria": ["Routine", "Soon", "Urgent"]
}
}
}'Python
import requests
response = requests.post(
"https://api.arliai.com/v1/systemone",
headers={"Authorization": "Bearer YOUR_ARLIAI_API_KEY"},
json={
"model": "d3-flash",
"state": {"ticket": "I was charged twice for the same order."},
"questions": {
"team": {
"type": "choice",
"instructions": "Which team should handle this?",
"criteria": {
"billing": "Payments and refunds",
"technical": "Bugs and outages",
},
},
"refund": {
"type": "noul",
"instructions": "Does the customer ask for a refund?",
},
},
},
)
print(response.json())Pick exactly one option. criteria maps option names to an optional description or null.
Yes/no. You may omit criteria, or provide { "true": "...", "false": "..." }.
Pick one ordered level. criteria is an array of two to ten non-empty strings, from lowest to highest.
The response contains an answers object keyed by question id. Choice and score answers include the selected label and per-option probabilities. No user content is logged.
Response example
{
"id": "decision-abc123",
"object": "structured_decision",
"created": 1790000000,
"model": "d3-flash",
"answers": {
"team": {
"type": "choice",
"choice": "billing",
"probabilities": {
"billing": 0.97,
"technical": 0.03
},
"confidence": 0.94
},
"refund": {
"type": "noul",
"choice": "true",
"probabilities": {
"true": 0.88,
"false": 0.12
},
"confidence": 0.76
},
"urgency": {
"type": "score",
"choice": "Soon",
"probabilities": {
"Routine": 0.08,
"Soon": 0.71,
"Urgent": 0.21
},
"confidence": 0.62
}
},
"usage": {
"input_tokens": 142,
"output_tokens": 0
}
}Multimodal decision models can receive images as base64 data URIs. Check the model's capability flags on its detail page before sending media. Video inputs are not supported by decision models.
Image input
{
"model": "d3-flash",
"state": "What is wrong with this screenshot?",
"images": ["data:image/png;base64,<base64-data>"],
"questions": {
"issue": {
"type": "choice",
"instructions": "What kind of issue is shown?",
"criteria": {
"billing": "A billing problem",
"technical": "A technical problem"
}
}
}
}List the decision models available to your account, including capabilities, context size, question limits, and usage stats.
cURL
curl https://api.arliai.com/v1/decision-models \
-H "Authorization: Bearer $ARLIAI_API_KEY"400 — invalid body, unsupported question type, or model limit exceeded.403 — your plan does not include the model, or the account context limit was exceeded.404 — the model name does not exist.503 — the model is disabled or no healthy decision server is available.