Skip to quickstart

Documentation

From a drawn flow to a call in production.

What a decision flow is made of, how to test it, and the API your systems call once it is live. One endpoint, one API key, one response that explains itself.

Quickstart

Four steps to a decision you can call.

  1. 01

    Build the flow

    Draw the decision on the canvas — rules, decision tables, splits, and code steps connected into one graph. Every outcome has an explicit path, so a reviewer can follow the logic without reading code.

  2. 02

    Test it in Sandbox

    Run representative cases through the draft. The trace shows the path taken node by node, so you fix the logic before a customer meets it — not after.

  3. 03

    Publish a version

    Publishing makes a version eligible for live traffic. Your integration keeps calling the same endpoint; the version behind it is a decision you make in the product, not a deploy.

  4. 04

    Call it

    POST the input to the flow's decide endpoint with your API key. The response carries the output, the version that produced it, and the trace behind it.

Decision API

One POST, and the reasoning comes back with the answer.

Request
curl -X POST https://api.arborule.com/run/api/v1/flows/YOUR_FLOW_SLUG/decide \
  -H "X-Api-Key: $ARBORULE_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{
    "data": { "first_name": "Grace", "last_name": "Hopper" },
    "metadata": { "grouping_id": "application-4821" }
  }'
Response
{
  "decision_id": "01J8ZQ...",
  "status_code": "succeeded",
  "created_at": "2026-07-30T14:02:11Z",
  "environment": "live",
  "grouping_id": "application-4821",
  "duration_ms": 41,
  "input": { "first_name": "Grace", "last_name": "Hopper" },
  "output": { "decision": "approve", "limit": 12000 },
  "trace": [ /* node-by-node record of the path taken */ ]
}

Authentication

Every call carries an X-Api-Key header. Keys are created per workspace and scoped to what they may do, so an integration that only decides cannot also edit a flow.

Request fields

data
The decision's input, matching the flow version's input schema. Everything your rules read comes from here.
metadata.grouping_id
Your identifier for the thing being decided — an application, a customer, a transaction. Keeps repeated calls on the same routed version and groups them in history.
metadata.version
Optional. Pin a published version by name instead of letting traffic routing choose.
control.async
Optional. Return as soon as the run is accepted instead of waiting for the verdict.

Endpoints

MethodPathWhat it does
POST/run/api/v1/flows/:slug/decideRun the published version of a flow against live traffic. Traffic-routed by weight and sticky per grouping_id.
POST/run/api/v1/flows/:slug/sandbox/decideRun a draft version in Sandbox. Same request and response shape as live, so the call you test is the call you ship.
GET/run/api/v1/flows/:slug/versionsList the flow's versions and their status, so a caller can pin one by name.
GET/history/api/v1/decisionsPage through recorded decisions, filtered by flow, environment or grouping_id.

Each flow also publishes an OpenAPI 3.1 document describing its own input and output schema, generated from the version you published — so client code is generated from the flow, not hand-copied from a page like this one.

Environments and versions

Sandbox and Live are the same flow at different confidence.

Sandbox runs a draft; Live runs a published version. Both take the same request body and return the same response shape, so nothing about the integration changes when a flow graduates.

Live traffic is routed across published versions by weight and kept sticky per grouping_id, so the same application does not get two different answers mid-journey while a new version is ramping.

  • SandboxDraft versions. Same request, same response, no customer impact.
  • LivePublished versions only. Weighted routing, sticky per grouping_id.
  • HistoryEvery run in both environments, queryable by flow, environment or grouping_id.

Node reference

What you can put on the canvas.

Decide

The logic itself — the part a policy owner edits.

  • Rule
  • Decision Table
  • 2D Matrix
  • Scorecard
  • Split
  • Merge
  • Loop
  • Decision Flow

Fetch and shape

Bring in what the decision needs and put it in the right shape.

  • Input
  • Output
  • Assignment
  • Code
  • PostgreSQL
  • Connection
  • Inbound Webhook
  • Read Entity
  • Create or update Entity

Models and agents

Where a decision needs judgment a table cannot express.

  • AI
  • Agent
  • ML Model

Hand to a human

For the decisions that should not be made automatically.

  • Manual Review
  • Create Case
  • Update Case

Common questions

What teams ask before integrating.

How do I call a decision flow from my application?

Send a POST to /run/api/v1/flows/:slug/decide on api.arborule.com with an X-Api-Key header and a JSON body containing your input under `data`. The response carries the decision id, the outcome under `output`, the environment it ran in, how long the engine took, and the node-by-node trace of the path taken. It is an ordinary HTTP call — there is no SDK to adopt and no callback to host for the synchronous case.

What is the difference between the Sandbox and Live endpoints?

/run/api/v1/flows/:slug/sandbox/decide runs a draft version; /run/api/v1/flows/:slug/decide runs a published one. The request body and the response shape are identical, so the call you test is the call you ship — the only thing that changes is which version answers and whether the run counts as production traffic. Both are recorded in decision history under their own environment.

How do I pin a decision to a specific flow version?

Set metadata.version to a published version's name. Leave it out and live traffic is routed across published versions by weight, kept sticky per grouping_id so the same application does not get two different answers while a new version is ramping. Pinning is what you want for a replay or a regression test; routing is what you want in production.

How do I find a decision after it has run?

Every response includes a decision_id. GET /history/api/v1/decisions returns recorded decisions filtered by flow_slug, environment or grouping_id, so you can retrieve one by its id or list everything that happened to a given application. The record keeps the input, the output, the version that produced it and the trace — which is what an adverse-action notice or a file review needs.

What happens when a decision needs a person?

Two different things, and the difference matters. A Manual Review node pauses the run: the API returns a pending decision and a review case immediately, and the same execution resumes from that node once someone answers. A Create Case node does not pause anything — the flow opens a case for a reviewer and carries on returning its answer, so nothing waits on a human.

Do I need an SDK, or a specific language?

No. The decision API is HTTP and JSON, called with an API key header, so anything that can make a request can call it. Each flow also publishes an OpenAPI 3.1 document describing its own input and output schema, generated from the version you published — so if you do want a typed client, generate it from the flow rather than hand-writing one against this page.

Start reading in the product

The rest of the docs live next to the flow.

Every flow carries its own API reference, generated from the version you published. Create a workspace to build one and read the docs it produces.

See what it costs