Skip to main content

Documentation Index

Fetch the complete documentation index at: https://docs.offloadapi.com/llms.txt

Use this file to discover all available pages before exploring further.

Endpoint

GET /cases/{id}

Purpose

Returns the current public state of a case owned by the authenticated client.

Authentication

x-api-key: your-api-key

Path Parameters

ParameterTypeRequiredNotes
idstringYesThe case ID returned by POST /cases.

Query Parameters

ParameterTypeRequiredNotes
includeTranscriptstringNoWhen the value is the literal string true, Offload fetches the tracked AgentMail thread and includes conversationThread.

Returned Fields

FieldNotes
caseIdOffload case ID
clientReferenceIdPresent when provided at creation time
statusCurrent case status
createdAtUnix timestamp in milliseconds
updatedAtUnix timestamp in milliseconds
nextActionAtScheduled timestamp, or the unscheduled sentinel 253402300799999
attemptCountNumber of outbound messages sent so far
maxAttemptsMaximum follow-up attempts after the initial outreach
channelCurrent schema allows EMAIL or SMS, but production workflow is email-based
counterpartyPublic counterparty object
attachmentsInbound attachment metadata only
resultStatusOpen string for workflow outcome
resultPresent when the case has structured output
goalOriginal goal object
resultSchemaPresent if provided at creation time
senderPersonaOriginal sender persona
constraintsPresent if provided at creation time
inputRequestnull or { id, question, status, requestedAt }
conversationThreadOnly included when includeTranscript=true

Important Omissions

GET /cases/{id} does not currently return:
  • metadata
  • failureReason
  • clientWebhookUrl
  • internal scheduling fields like nextActionType

Example Response

{
  "ok": true,
  "data": {
    "caseId": "4fc5904d-0e44-4ed3-aa57-c4a47ad0ae4f",
    "clientReferenceId": "vendor_2048",
    "status": "INPUT_NEEDED",
    "createdAt": 1774131000000,
    "updatedAt": 1774131900300,
    "nextActionAt": 253402300799999,
    "attemptCount": 1,
    "maxAttempts": 3,
    "channel": "EMAIL",
    "counterparty": {
      "address": "ap@northstar.example",
      "name": "Maya Chen",
      "company": "Northstar Supplies",
      "timezone": "America/Los_Angeles"
    },
    "attachments": [],
    "goal": {
      "objective": "Collect a signed W-9 from the vendor"
    },
    "resultSchema": {
      "type": "object"
    },
    "senderPersona": {
      "name": "Avery",
      "role": "Accounts Payable"
    },
    "constraints": ["Email only"],
    "inputRequest": {
      "id": "c8c6a7ca-a913-4d13-8cd8-5887efb0531c",
      "question": "The vendor asked whether a signed PDF is acceptable. How should I respond?",
      "status": "PENDING",
      "requestedAt": 1774131900300
    }
  }
}

Example Response With Transcript

Request:
GET /cases/{id}?includeTranscript=true
Response:
{
  "ok": true,
  "data": {
    "caseId": "4fc5904d-0e44-4ed3-aa57-c4a47ad0ae4f",
    "status": "RUNNING",
    "createdAt": 1774131000000,
    "updatedAt": 1774131900000,
    "nextActionAt": 1774387500000,
    "attemptCount": 2,
    "maxAttempts": 3,
    "channel": "EMAIL",
    "counterparty": {
      "address": "ap@northstar.example",
      "name": "Maya Chen"
    },
    "attachments": [],
    "goal": {
      "objective": "Collect a signed W-9 from the vendor"
    },
    "senderPersona": {
      "name": "Avery"
    },
    "inputRequest": null,
    "conversationThread": "From: Avery <avery@agentmail.to>\nTimestamp: 2026-03-20T18:10:00.000Z\nMessage: Hi Maya, could you send the signed W-9?\n\n---\n\nFrom: Maya Chen <ap@northstar.example>\nTimestamp: 2026-03-21T15:42:00.000Z\nMessage: Attached here."
  }
}
conversationThread is formatted plain text, not an array of structured messages.

Attachment Downloads

Use GET /cases/{id}/attachments/{attachmentId} when you need a fresh downloadUrl.

Errors

StatusCodeMeaning
400INVALID_REQUESTMissing case ID
401UNAUTHORIZEDMissing or invalid API key
403FORBIDDENInactive API key or case belongs to another user
404CASE_NOT_FOUNDNo case exists for that ID
If includeTranscript=true and the live AgentMail fetch fails, the current implementation may return a generic platform 500 instead of the standard JSON error envelope.