Ask a chat model to classify a support ticket and you will get back a paragraph. Ask it to “reply in JSON” and you will get JSON — usually. Sometimes with a polite sentence glued to the front, sometimes with a label that does not exist in your enum, and almost always without a trustworthy signal about how confident the model really is. That gap between fluent text and typed, machine-safe values is where a surprising number of production AI projects quietly stall: the demo works, the parser is brittle, and nobody wants to put an unvalidated string behind a payment, a shipment, or a robot.

A decision API closes that gap. Instead of generating language and hoping your validation layer survives, it accepts state, evaluates questions you define in code, and returns answers in a fixed, schema-valid shape — with calibrated confidence attached to every one. For developers, product teams, and ops engineers, that changes the integration model from “prompt and pray” to something closer to calling a database.

What a Decision API Is, and Why “Reply in JSON” Is Not One

A decision API is an HTTPS endpoint that treats a model as a function rather than a conversationalist. You send two things: the state (the text, structured data, or imagery the decision depends on) and the questions (the specific judgments you need, declared with their allowed answers). What comes back is not prose with structure bolted on afterwards — it is a typed result set that maps directly onto the variables your code already uses.

The answer types are deliberately narrow, because narrow types are what production systems can act on. A choice returns one of the labels you supplied — nothing outside your enum. A score returns a level on an ordered scale you defined. A truth returns a calibrated probability between 0.00 and 1.00. A number returns a value snapped to your grid. A point or a box returns a location or region inside an image. No markdown fences, no schema drift between calls, no downstream regular expressions holding the whole pipeline together.

Two properties separate this from wrapping a chat completion in a JSON instruction. The first is calibration: every answer carries a confidence that means what it says, so your code can act instantly above a threshold and route to a safe path, a second check, or a human below it. The second is determinism: the same request returns the same answer. That makes decisions testable, replayable, cacheable, and auditable — properties that are extremely difficult to engineer on top of sampled text generation.

It also distinguishes a decision API from a traditional rules engine. Hand-written rules are deterministic but blind: they cannot read a support message, judge a product photo, or weigh ambiguous evidence. A decision API handles exactly the fuzzy, semantic inputs that push teams toward brittle heuristics in the first place. Platforms such as DecisionNode expose this as a single decision api endpoint — POST /v1/decide — built on a “System One” decision model that returns typed, calibrated decisions instead of generated text.

Anatomy of a Decision Request: State, Questions, One Round Trip

The request contract is where most of the engineering value lives, so it is worth walking through concretely. Everything travels to one endpoint as a single call. The state can be plain text, a JSON object, or up to sixteen images or video frames attached to the same request. That last part matters for teams doing visual work: instead of stitching together an OCR service, a detector, and a classifier, the frames go in with the questions and the judgments come back together.

Questions are declared in code, which means the label set, the ordered scale, the numeric grid, and the image regions are versioned alongside your application. When a product decision changes a queue name or adds a severity level, that is a code review and a deploy, not a prompt edit buried in a config bucket. The model answers all questions in one pass — there is no chain of prompts, no tool-calling loop, and no follow-up call whose only job is to validate the previous one.

Latency and cost are the parts that usually decide whether an integration ships. DecisionNode offers two models: Flash, at roughly 5 ms server-side and about 19 ms end to end, priced at $0.035 per 1M input tokens, and MoE, at roughly 9 ms server-side, priced at $0.042 per 1M input tokens. Output tokens are always free, which removes the usual penalty for long, verbose answers, and batch discounts plus a free daily tier make it practical to run decisions in development, in CI, and in shadow mode before they touch real traffic.

Client ergonomics are handled with SDKs for TypeScript, Python, Go, Ruby, and curl, plus MCP tools for AI agents and webhooks for async fan-out. For high-frequency loops — above ten decisions per second — WebSocket sessions keep the connection warm, which is the pattern drones, robots, simulators, and continuous machine monitoring need. Optional boosters, including human age estimation, AI-generated image detection, face detection and recognition, OCR, depth, and segmentation, compose into the same call rather than requiring a separate computer-vision stack.

Decision Patterns in Production: Routing, Gating, Fraud, and Visual QC

The most useful engineering pattern is threshold routing on calibrated confidence. A ticket-triage service might auto-assign a queue when the choice confidence is above 0.95, auto-assign with an audit flag between 0.70 and 0.95, and hold anything below 0.70 for a human or a clarifying question. Because the probability is calibrated rather than merely plausible-looking, those thresholds can be tuned against real outcomes instead of guesswork, and the same structure applies to order and shipping decisions, moderation, and scoring.

Fraud and promo-abuse checks benefit from treating the model as a probabilistic evidence source rather than an oracle. Hard constraints — velocity limits, blocklists, account age — stay in deterministic code where they belong, while the ambiguous questions (“does this order pattern look like resale abuse?”, “is this review likely coordinated?”) come back as truth probabilities that feed a risk score. The confidence value tells you when to spend a manual review and when to let the transaction through.

For AI agent builders, decision calls act as a gate before action. An agent about to issue a refund, send an outbound email, or invoke a destructive tool can first ask a cheap, typed question — is this action within scope, is this amount consistent with the order, does this message match the escalation policy — and branch on the answer. MCP tools and webhooks make that wiring short, and the free daily tier keeps it affordable during agent development loops.

Visual operations teams get the most direct fit. Quality control on a production line can send each frame with a question set that returns a box for the defect region and a choice for the defect class, all through one WebSocket session running above ten decisions per second. Warehouse and traffic monitoring follow the same shape: point and box answers over camera frames, with confidence deciding which frames get human eyes. Ops teams migrating off brittle hand-written rule stacks typically keep their deterministic guards, route the fuzzy remainder to decisions, and log every typed answer — which, thanks to determinism, can be replayed exactly when an incident needs explaining.

Categories: Technology

Callum Fraser

Edinburgh raised, Seoul residing, Callum once built fintech dashboards; now he deconstructs K-pop choreography, explains quantum computing, and rates third-wave coffee gear. He sketches Celtic knots on his tablet during subway rides and hosts a weekly pub quiz—remotely, of course.