TypeSafe Decisions
Evaluate shared input for judgments, classification, scoring, tool selection and image localization.
Provide a shared state and named questions to receive structured answers synchronously. Both endpoints use the same requests and responses and do not support streaming. Replace MODEL_ID with an available decision model ID.
/v1/decisions/v1/systemoneAuthorization
bearerAuth Use an API Key issued by the current site.
In: header
Header Parameters
Set to true for image or Box requests; omit for plain text requests.
Value in
- "true"
Set to true when a longer context is needed; omitted by default. See the selected model's documentation for context limits.
Value in
- "true"
TypeScript Definitions
Use the request body type in TypeScript.
Response Body
application/json
application/json
application/json
Question types and reading results
| Type | Returned content and how to read it |
|---|---|
noul · Judgment | noul is the probability that the condition holds, from 0–1; set a threshold for your business needs |
choice · Classification or tool selection | Read choice for the option name, probabilities for each option's probability, and confidence for distribution certainty |
score · Scoring | criteria is numbered from 0; score is probability-weighted, can be fractional, and ranges from 0 to the number of levels minus 1; legend contains the original level descriptions |
box · Image localization | Read box.top/bottom/left/right; coordinates are normalized to 0–1 relative to image height and width; confidence may be null |
answers uses the question IDs from the request. For example, for question ID ticket, read answers.ticket. A request can mix question types, all sharing one state. IDs only associate questions with answers; put the complete rules in instructions.
confidence is not business accuracy. Tool selection returns an action name for your application to execute; this request does not execute tools. Scoring usually uses at least two levels to give higher and lower results a clear meaning.
Image input rules
| Configuration | Usage |
|---|---|
assets and references | Register each image once and reference it in string values in state, instructions or criteria. Use unique strings; object keys are not replaced with images, and unused assets are rejected |
| JSON Base64 | Set data_base64 and format: png/jpg/jpeg; omit the data: prefix, line breaks and whitespace |
| Multipart | Send the request JSON part first, followed by image files. In assets, part must match file part names. When both part and Base64 are provided, part takes precedence |
| Image switch | Add TypeSafe-Danger-Zone-Images: true for image or Box requests; omit for plain text requests |
| Image limits | Static PNG/JPEG, at most 16 MiB per image; width and height must each be 280–1568 pixels. Resize oversized images locally first; automatic resizing is not performed |
| Request size | The request body, all processed images, and the request after reference expansion are each limited to 32 MiB. Repeated references to one image count repeatedly toward the expanded size |
Box locates one specified target. If the target may be absent, add a Noul question in the same request to confirm its presence before using the coordinates.
Token usage
usage.input_tokens and usage.output_tokens report input and output Tokens. Images, question instructions and option descriptions also count toward input usage. For current model prices, see the Model Marketplace.