{
  "$schema": "runback.audit/v2",
  "manifest": {
    "run_id": "sbx-notify-customer-16010cd03875",
    "generated_at": "2026-11-07T07:28:18.060Z",
    "event_count": 7,
    "algorithm": "sha256-chain",
    "content_digest": "44bb5d62a59c2643eff72243f88ca3f41664f020bf9a2dc8c6456dd750d9604d",
    "replay": {
      "cassette_digest": "cb63f3a2257f03e92fcc16c04c242c6281529368d40865b9474c1fc9c44e4008",
      "entry_count": 5,
      "algorithm": "oracle-chain/sha256",
      "note": "The run's oracle stream — every model response and tool output, hash-chained. Re-execute the agent against `events` with @runback/replay and the cassette digest must reproduce. This is proof the recording IS the deterministic input stream of the run — an audit you can re-run, not just read."
    },
    "signed": true,
    "signature": {
      "alg": "Ed25519",
      "value": "3a1e853ebaf43327db3e362cc1c747833182d790bbe262bf02ec2c12a8f0a26f18eedac0c908eb5de78b129548d85f55e2910a424f75ebce5ed2cb92d74edd03",
      "pubkey": "-----BEGIN PUBLIC KEY-----\nMCowBQYDK2VwAyEArDPmR+Gvu1HawnSvM6xjZao7BVPPQ80Qq3sa1hAYvDU=\n-----END PUBLIC KEY-----\n"
    },
    "verify": "Recompute the event chain h_i = SHA-256(h_{i-1} + canonical(event_i)) over `events` → must equal content_digest. Recompute the oracle-stream digest from `events` → must equal replay.cassette_digest. The signature covers `${content_digest}:${cassette_digest}`. Ed25519: verify with the public key embedded in manifest.signature.pubkey (no server key needed — fully offline-verifiable). HMAC-SHA256 (legacy): requires AUDIT_SIGNING_KEY. POST this record to /api/audit/verify.",
    "spec_url": "https://runback.dev/spec",
    "verifier_url": "https://runback.dev/verify"
  },
  "run": {
    "run_id": "sbx-notify-customer-16010cd03875",
    "name": "notify-customer-agent",
    "status": "success",
    "input": "Send today's priority notifications: customer #6650 — refund processed.",
    "output": {
      "summary": "Sent an email to customer #6650 notifying them that their refund has been processed."
    },
    "error": null,
    "metadata": {
      "agent": {
        "description": "Sends the day's priority notifications. Runback demo agent: real model calls and real policy decisions; its tools act on a sandbox of synthetic customers, orders and accounts.",
        "systemOfRecord": "Runback demo sandbox (synthetic data)"
      },
      "model": "openai/gpt-oss-20b",
      "demo_agent": true,
      "est_cost_usd": 0.00006,
      "sandbox_tools": true,
      "scenario_seed": "notify-customer-agent:2026-11-07:12"
    },
    "step_count": 3,
    "total_tokens": 1318,
    "started_at": "2026-11-07T02:10:53.165+00:00",
    "ended_at": "2026-11-07T02:10:55.364+00:00",
    "actor_type": null,
    "actor_id": null
  },
  "events": [
    {
      "seq": 0,
      "name": "notify-customer-agent",
      "type": "run",
      "error": null,
      "input": "Send today's priority notifications: customer #6650 — refund processed.",
      "phase": "start",
      "output": null,
      "run_id": "sbx-notify-customer-16010cd03875",
      "status": "running",
      "ts_end": "2026-11-07T02:10:55.364Z",
      "span_id": "r",
      "metadata": {
        "agent": {
          "description": "Sends the day's priority notifications. Runback demo agent: real model calls and real policy decisions; its tools act on a sandbox of synthetic customers, orders and accounts.",
          "systemOfRecord": "Runback demo sandbox (synthetic data)"
        },
        "model": "openai/gpt-oss-20b",
        "demo_agent": true,
        "est_cost_usd": 0.00006,
        "sandbox_tools": true,
        "scenario_seed": "notify-customer-agent:2026-11-07:12"
      },
      "ts_start": "2026-11-07T02:10:53.165Z",
      "parent_span_id": null,
      "schema_version": 1,
      "_hash": "abbd6cbe2326e6bbdc1bbb60931edd18f24279a0c48b66423505ee6fc2807e92"
    },
    {
      "seq": 1,
      "type": "llm",
      "error": null,
      "model": {
        "model_id": "openai/gpt-oss-20b",
        "provider": "groq"
      },
      "usage": {
        "input_tokens": 319,
        "total_tokens": 407,
        "output_tokens": 88
      },
      "run_id": "sbx-notify-customer-16010cd03875",
      "ts_end": "2026-11-07T02:10:53.729Z",
      "request": {
        "tools": [
          {
            "name": "get_customer_contact",
            "parameters": {
              "type": "object",
              "required": [
                "customer_id"
              ],
              "properties": {
                "customer_id": {
                  "type": "number",
                  "description": "Customer id"
                }
              },
              "additionalProperties": false
            },
            "description": "Get a customer's contact details and SMS opt-in."
          },
          {
            "name": "send_email",
            "parameters": {
              "type": "object",
              "required": [
                "customer_id",
                "subject",
                "body"
              ],
              "properties": {
                "body": {
                  "type": "string",
                  "description": "Body"
                },
                "subject": {
                  "type": "string",
                  "description": "Subject"
                },
                "customer_id": {
                  "type": "number",
                  "description": "Customer id"
                }
              },
              "additionalProperties": false
            },
            "description": "Send an email."
          },
          {
            "name": "send_sms",
            "parameters": {
              "type": "object",
              "required": [
                "customer_id",
                "message"
              ],
              "properties": {
                "message": {
                  "type": "string",
                  "description": "Under 160 characters"
                },
                "customer_id": {
                  "type": "number",
                  "description": "Customer id"
                }
              },
              "additionalProperties": false
            },
            "description": "Send an SMS."
          }
        ],
        "params": {
          "temperature": 0,
          "max_output_tokens": 500
        },
        "system": "You are Acme's customer notification agent. You are running in Runback's public demo sandbox: every customer, order, invoice and account is synthetic, and your tools act on test data only. For each event, look up the customer's contact preferences and send one short notification: SMS only to customers who opted in, email otherwise. Use the tools to act; when you are done, reply with a one-sentence summary of what you did.",
        "messages": [
          {
            "role": "user",
            "content": "Send today's priority notifications: customer #6650 — refund processed."
          }
        ]
      },
      "span_id": "l1",
      "response": {
        "text": null,
        "reasoning": null,
        "tool_calls": [
          {
            "input": {
              "customer_id": 6650
            },
            "tool_name": "get_customer_contact",
            "tool_call_id": "fc_a62092cb-738d-47ba-8259-8549754aee97"
          }
        ],
        "finish_reason": "tool-calls"
      },
      "ts_start": "2026-11-07T02:10:53.165Z",
      "latency_ms": 564,
      "parent_span_id": "r",
      "schema_version": 1,
      "_hash": "3d8990767d33ea2b6f1a14398fd827c967764bfc10c2c4f147ab4d41e0fc4cd4"
    },
    {
      "seq": 2,
      "type": "tool",
      "error": null,
      "input": {
        "customer_id": 6650
      },
      "output": {
        "email": "sage.example6650@example.com",
        "sms_opt_in": false,
        "customer_id": 6650
      },
      "run_id": "sbx-notify-customer-16010cd03875",
      "ts_end": "2026-11-07T02:10:53.755Z",
      "span_id": "t1",
      "ts_start": "2026-11-07T02:10:53.729Z",
      "tool_name": "get_customer_contact",
      "latency_ms": 26,
      "tool_call_id": "fc_a62092cb-738d-47ba-8259-8549754aee97",
      "parent_span_id": "l1",
      "schema_version": 1,
      "_hash": "ae81fd894ddba287cfa941e62b85402f8a6187c67d9b504a35bb2a8262ebe568"
    },
    {
      "seq": 3,
      "type": "llm",
      "error": null,
      "model": {
        "model_id": "openai/gpt-oss-20b",
        "provider": "groq"
      },
      "usage": {
        "input_tokens": 369,
        "total_tokens": 466,
        "output_tokens": 97
      },
      "run_id": "sbx-notify-customer-16010cd03875",
      "ts_end": "2026-11-07T02:10:54.970Z",
      "request": {
        "tools": [
          {
            "name": "get_customer_contact",
            "parameters": {
              "type": "object",
              "required": [
                "customer_id"
              ],
              "properties": {
                "customer_id": {
                  "type": "number",
                  "description": "Customer id"
                }
              },
              "additionalProperties": false
            },
            "description": "Get a customer's contact details and SMS opt-in."
          },
          {
            "name": "send_email",
            "parameters": {
              "type": "object",
              "required": [
                "customer_id",
                "subject",
                "body"
              ],
              "properties": {
                "body": {
                  "type": "string",
                  "description": "Body"
                },
                "subject": {
                  "type": "string",
                  "description": "Subject"
                },
                "customer_id": {
                  "type": "number",
                  "description": "Customer id"
                }
              },
              "additionalProperties": false
            },
            "description": "Send an email."
          },
          {
            "name": "send_sms",
            "parameters": {
              "type": "object",
              "required": [
                "customer_id",
                "message"
              ],
              "properties": {
                "message": {
                  "type": "string",
                  "description": "Under 160 characters"
                },
                "customer_id": {
                  "type": "number",
                  "description": "Customer id"
                }
              },
              "additionalProperties": false
            },
            "description": "Send an SMS."
          }
        ],
        "params": {
          "temperature": 0,
          "max_output_tokens": 500
        },
        "system": "You are Acme's customer notification agent. You are running in Runback's public demo sandbox: every customer, order, invoice and account is synthetic, and your tools act on test data only. For each event, look up the customer's contact preferences and send one short notification: SMS only to customers who opted in, email otherwise. Use the tools to act; when you are done, reply with a one-sentence summary of what you did.",
        "messages": [
          {
            "role": "user",
            "content": "Send today's priority notifications: customer #6650 — refund processed."
          },
          {
            "role": "assistant",
            "content": [
              {
                "type": "tool-call",
                "input": {
                  "customer_id": 6650
                },
                "toolName": "get_customer_contact",
                "toolCallId": "fc_a62092cb-738d-47ba-8259-8549754aee97"
              }
            ]
          },
          {
            "role": "tool",
            "content": [
              {
                "type": "tool-result",
                "output": {
                  "type": "json",
                  "value": {
                    "email": "sage.example6650@example.com",
                    "sms_opt_in": false,
                    "customer_id": 6650
                  }
                },
                "toolName": "get_customer_contact",
                "toolCallId": "fc_a62092cb-738d-47ba-8259-8549754aee97"
              }
            ]
          }
        ]
      },
      "span_id": "l2",
      "response": {
        "text": null,
        "reasoning": null,
        "tool_calls": [
          {
            "input": {
              "body": "Your refund has been processed successfully.",
              "subject": "Refund Processed",
              "customer_id": 6650
            },
            "tool_name": "send_email",
            "tool_call_id": "fc_528d178c-48ff-4f11-a4d2-60dc5b3a92f2"
          }
        ],
        "finish_reason": "tool-calls"
      },
      "ts_start": "2026-11-07T02:10:53.755Z",
      "latency_ms": 1215,
      "parent_span_id": "r",
      "schema_version": 1,
      "_hash": "db92dffe54f8e6d429c9d9777fc621f1bee1a7b2b6587f38146a1edc054ad19c"
    },
    {
      "seq": 4,
      "type": "tool",
      "error": null,
      "input": {
        "body": "Your refund has been processed successfully.",
        "subject": "Refund Processed",
        "customer_id": 6650
      },
      "output": {
        "sent": true,
        "channel": "email",
        "sandbox": true
      },
      "run_id": "sbx-notify-customer-16010cd03875",
      "ts_end": "2026-11-07T02:10:55.008Z",
      "span_id": "t2",
      "ts_start": "2026-11-07T02:10:54.970Z",
      "tool_name": "send_email",
      "latency_ms": 38,
      "tool_call_id": "fc_528d178c-48ff-4f11-a4d2-60dc5b3a92f2",
      "parent_span_id": "l2",
      "schema_version": 1,
      "_hash": "6ef0c4dcb2a4d2e7efffaa58dcb87043585528f131e214791930f2db546407cc"
    },
    {
      "seq": 5,
      "type": "llm",
      "error": null,
      "model": {
        "model_id": "openai/gpt-oss-20b",
        "provider": "groq"
      },
      "usage": {
        "input_tokens": 424,
        "total_tokens": 445,
        "output_tokens": 21
      },
      "run_id": "sbx-notify-customer-16010cd03875",
      "ts_end": "2026-11-07T02:10:55.364Z",
      "request": {
        "tools": [
          {
            "name": "get_customer_contact",
            "parameters": {
              "type": "object",
              "required": [
                "customer_id"
              ],
              "properties": {
                "customer_id": {
                  "type": "number",
                  "description": "Customer id"
                }
              },
              "additionalProperties": false
            },
            "description": "Get a customer's contact details and SMS opt-in."
          },
          {
            "name": "send_email",
            "parameters": {
              "type": "object",
              "required": [
                "customer_id",
                "subject",
                "body"
              ],
              "properties": {
                "body": {
                  "type": "string",
                  "description": "Body"
                },
                "subject": {
                  "type": "string",
                  "description": "Subject"
                },
                "customer_id": {
                  "type": "number",
                  "description": "Customer id"
                }
              },
              "additionalProperties": false
            },
            "description": "Send an email."
          },
          {
            "name": "send_sms",
            "parameters": {
              "type": "object",
              "required": [
                "customer_id",
                "message"
              ],
              "properties": {
                "message": {
                  "type": "string",
                  "description": "Under 160 characters"
                },
                "customer_id": {
                  "type": "number",
                  "description": "Customer id"
                }
              },
              "additionalProperties": false
            },
            "description": "Send an SMS."
          }
        ],
        "params": {
          "temperature": 0,
          "max_output_tokens": 500
        },
        "system": "You are Acme's customer notification agent. You are running in Runback's public demo sandbox: every customer, order, invoice and account is synthetic, and your tools act on test data only. For each event, look up the customer's contact preferences and send one short notification: SMS only to customers who opted in, email otherwise. Use the tools to act; when you are done, reply with a one-sentence summary of what you did.",
        "messages": [
          {
            "role": "user",
            "content": "Send today's priority notifications: customer #6650 — refund processed."
          },
          {
            "role": "assistant",
            "content": [
              {
                "type": "tool-call",
                "input": {
                  "customer_id": 6650
                },
                "toolName": "get_customer_contact",
                "toolCallId": "fc_a62092cb-738d-47ba-8259-8549754aee97"
              }
            ]
          },
          {
            "role": "tool",
            "content": [
              {
                "type": "tool-result",
                "output": {
                  "type": "json",
                  "value": {
                    "email": "sage.example6650@example.com",
                    "sms_opt_in": false,
                    "customer_id": 6650
                  }
                },
                "toolName": "get_customer_contact",
                "toolCallId": "fc_a62092cb-738d-47ba-8259-8549754aee97"
              }
            ]
          },
          {
            "role": "assistant",
            "content": [
              {
                "type": "tool-call",
                "input": {
                  "body": "Your refund has been processed successfully.",
                  "subject": "Refund Processed",
                  "customer_id": 6650
                },
                "toolName": "send_email",
                "toolCallId": "fc_528d178c-48ff-4f11-a4d2-60dc5b3a92f2"
              }
            ]
          },
          {
            "role": "tool",
            "content": [
              {
                "type": "tool-result",
                "output": {
                  "type": "json",
                  "value": {
                    "sent": true,
                    "channel": "email",
                    "sandbox": true
                  }
                },
                "toolName": "send_email",
                "toolCallId": "fc_528d178c-48ff-4f11-a4d2-60dc5b3a92f2"
              }
            ]
          }
        ]
      },
      "span_id": "l3",
      "response": {
        "text": "Sent an email to customer #6650 notifying them that their refund has been processed.",
        "reasoning": null,
        "tool_calls": [],
        "finish_reason": "stop"
      },
      "ts_start": "2026-11-07T02:10:55.008Z",
      "latency_ms": 356,
      "parent_span_id": "r",
      "schema_version": 1,
      "_hash": "0d19ab61b3614087cfbdd1f706c249d7bf2263ea662ee38f3ec51ced66719846"
    },
    {
      "seq": 6,
      "name": "notify-customer-agent",
      "type": "run",
      "error": null,
      "input": null,
      "phase": "end",
      "output": {
        "summary": "Sent an email to customer #6650 notifying them that their refund has been processed."
      },
      "run_id": "sbx-notify-customer-16010cd03875",
      "status": "success",
      "ts_end": "2026-11-07T02:10:55.364Z",
      "span_id": "re",
      "metadata": {
        "demo_agent": true,
        "sandbox_tools": true
      },
      "ts_start": "2026-11-07T02:10:55.364Z",
      "parent_span_id": null,
      "schema_version": 1,
      "_hash": "44bb5d62a59c2643eff72243f88ca3f41664f020bf9a2dc8c6456dd750d9604d"
    }
  ]
}