Quickstart
-
Get an ingest key. Sign in to the portal, and copy the key shown at the end of workspace creation, or make one under Settings → API keys. Set two variables wherever your agent runs:
Terminal window export STRATL_API_URL="https://api.stratl.ai" # or http://localhost:8000export STRATL_API_KEY="sk_stratl_..." -
Install the SDK and record one decision.
Terminal window uv add stratl # or: pip install stratlimport stratlclient = stratl.Client() # reads STRATL_API_URL and STRATL_API_KEYwith stratl.decision(agent="support-bot", subject=("order", "48213"), client=client) as d:d.input(ticket_text)d.model("openai", "gpt-5", prompt, response)d.tool("orders.read", {"order_id": "48213"}, order)d.policy("refunds_above_100_require_approval", version=7, result="human_required")d.approval(required=True, approver="priya@example.com", authority="support_lead",decision="approved", identity_provider="okta")d.action("refunds.issue", target="order/48213", result="executed", params={"amount": 180})d.outcome(adverse=False, category="refund")print(d.last.decision_id, d.status) # "recorded", or "spooled" if the API was unreachableTerminal window npm install @stratl/sdkimport { Client, decision } from "@stratl/sdk";const client = new Client(); // reads STRATL_API_URL, STRATL_API_KEY and STRATL_SPOOL_DIRconst { record, submitted } = await decision("support-bot", ["order", "48213"], async (d) => {await d.input(ticketText);await d.model("openai", "gpt-5", prompt, response);await d.tool("orders.read", { order_id: "48213" }, order);await d.policy("refunds_above_100_require_approval", { version: 7, result: "human_required" });await d.approval({ required: true, approver: "priya@example.com", authority: "support_lead",decision: "approved", identityProvider: "okta" });await d.action("refunds.issue", { target: "order/48213", result: "executed", params: { amount: 180 } });await d.outcome({ adverse: false, category: "refund" });}, client);console.log(record.decision_id, submitted?.status);Everything you pass in is fingerprinted on your side. The record carries only fingerprints; the SDK uploads the original bytes to custody so they can be re-hashed later. How content is handled.
-
Look at it. Open the portal’s Decisions page. The record is there with seven events, signed and chained. Open it and read the lineage.
-
Seal it. Custody → Checkpoint now. The checkpoint is signed and dated by an outside authority.
-
Verify it without Stratl. Export the bundle from the decision page, then:
Terminal window stratl verify DEC-....stratl.zipTwelve checks, all passing, on your machine, with no account and no network. What they prove.
Next: the Python SDK reference, the TypeScript SDK reference, or the record format walkthrough.