docs / quickstart
Quickstart

Seal and verify your first receipt in fifteen minutes.

Sequesign ships as an MCP server, so it drops in front of any agent tooling that speaks the Model Context Protocol. You'll bind a template, record two actions, seal the receipt, and verify it offline.

1

Add the Sequesign MCP server

Add Sequesign to your MCP client configuration (Claude Desktop, Claude Code, or any MCP host). Point it at an absolute directory where sealed packages should be written — the value is passed to the server verbatim, so ~ is not expanded.

{
  "mcpServers": {
    "sequesign": {
      "command": "npx",
      "args": ["-y", "@sequesign/mcp"],
      "env": { "SEQUESIGN_PACKAGE_DIR": "/home/you/receipts" }
    }
  }
}

Restart the client. Your agent now has the sequesign_* toolset.

2

Start a session bound to a template

The template is the mandate: what the agent is allowed to do, what evidence each action requires, and who must sign. Its hash, and the hash of your bound parameters, are committed into the chain genesis before the first action is taken.

sequesign_start_session {
  "taskId":      "demo-invoice-001",
  "delegatorId": "you",
  "templateRef": "invoice_approval@2.0.0",
  "params":      { "max_amount": 5000, "currency": "USD" }
}
// returns
sessionId: rec_37c17c5f8b6a50c8 · template bound · genesis committed
Why genesis binding matters: because the mandate hash is part of the chain root, nobody, including us, and including the sealer, can swap in a weaker mandate later. The embedded template either matches the chain or the whole receipt fails.
3

Record the work

Each action is validated against the template's evidence schema and chained to the one before it.

sequesign_record_action {
  "sessionId":  "rec_37c17c5f8b6a50c8",
  "actionType": "invoice_reviewed",
  "evidence": {
    "vendor": "Acme Corp", "invoiceId": "INV-2026-014",
    "amount": 1200.00, "currency": "USD",
    "decision": "approve", "reason": "matches PO, within budget"
  }
}
sequesign_record_action {
  "sessionId":  "rec_37c17c5f8b6a50c8",
  "actionType": "payment_approved",
  "evidence": { "invoiceId": "INV-2026-014", "approvedBy": "you", "amount": 1200.00 }
}
4

Seal the receipt

Finalizing evaluates the recorded work against the mandate, records the conformance result, and has the witness sign the seal. Nonconformant work still seals: a signed record of an agent exceeding its mandate is evidence, and evidence is the point.

sequesign_finalize { "sessionId": "rec_37c17c5f8b6a50c8" }
// returns
sealed · conformant: true · witnessed · package: /home/you/receipts/demo-invoice-001.sequesign
5

Verify, offline, from the files alone

The package embeds the template and bound parameters. Verification recomputes every hash, checks them against the genesis commitment, and re-runs conformance from the embedded mandate. No network. No account. No trust in Sequesign.

sequesign_verify { "packageDirectory": "/home/you/receipts/demo-invoice-001.sequesign" }
// returns
valid:            true
level:            L3_POLICY_BOUND
mandate:          embedded · hash matches genesis
conformant:       true
witnessed:        true
authorship:       self-asserted (anchor a registered key to upgrade)

What each leg proves, and what it requires:

Check Proves Requires
integrity These exact actions, in this order, under this exact mandate Nothing. Offline, zero trust.
conformance The work matched, or violated, the pre-bound mandate Nothing. Offline, zero trust.
authorship A party you trust wrote the mandate / took the actions A key you anchor: pinned, or enrolled via Registry.