List runs across the space (global view)

Org + space scoped paginated list. Supports filtering by user=me (self-owned, also implicit for end-user impersonation), kind (all, package, inline), status, a date range, and the chat session that launched the run. Every filter composes: user=me narrows to the caller's own runs and the remaining filters still apply on top of it. Inline runs surface via package_ephemeral: true on each row.

GET/api/runs

Authorization

better-auth.session_token<token>

Cookie session from Better Auth. Requires X-Org-Id header for org-scoped routes.

In: cookie

Query Parameters

user?string

Filter runs by user. me is the only accepted value and returns strictly the runs the caller launched — even for a caller who may read the whole space — composed with every other filter on this operation. Omit (or send an empty value) for all org runs the caller may see. Any other value — an arbitrary user id, for instance — is rejected with 400; it is never ignored, so a filtered response is never silently widened to the whole org.

Value in"me"
limit?integer
Default20
Range1 <= value <= 100
offset?integer

Number of items to skip before the first returned item.

Default0
Range0 <= value
kind?string

Filter runs by kind. Omit (or send an empty value) for every kind. Any value outside the enum is rejected with 400; it is never ignored, so a filtered response is never silently widened.

Value in"all" | "package" | "inline"
status?string

Filter runs by lifecycle status. Omit (or send an empty value) for every status. Any value outside the enum is rejected with 400; it is never ignored, so a filtered response is never silently widened.

Value in"pending" | "running" | "success" | "failed" | "timeout" | "cancelled"
start_date?string
Formatdate-time
end_date?string
Formatdate-time
chat_session_id?string

Return only runs launched from this chat session.

Header Parameters

X-Org-Id?string

Organization ID. Required for cookie auth. Not needed for API key auth (org resolved from key).

Formatuuid
X-Space-Id?string

Space ID. Required for space-scoped routes (agents, runs, schedules, and space-scoped module routes). Not needed for API key auth (space resolved from key).

Appstrate-User?string

End-user ID (eu_ prefix) to execute the request on behalf of. API key auth only — rejected with 400 on cookie auth.

curl -X GET "https://your-instance/api/runs"
{
  "object": "list",
  "data": [
    {
      "id": "string",
      "packageId": "string",
      "userId": "string",
      "orgId": "string",
      "status": "pending",
      "input": {},
      "result": {
        "output": null
      },
      "artifacts": {
        "status": "complete",
        "published": 0,
        "failed": [
          {
            "name": "string",
            "code": "string"
          }
        ]
      },
      "checkpoint": {},
      "error": "string",
      "token_usage": {
        "input_tokens": 0,
        "output_tokens": 0,
        "cache_creation_input_tokens": 0,
        "cache_read_input_tokens": 0
      },
      "started_at": "2019-08-24T14:15:22Z",
      "completed_at": "2019-08-24T14:15:22Z",
      "duration": 0,
      "scheduleId": "string",
      "version_label": "string",
      "version_ref": "string",
      "proxy_label": "string",
      "model_label": "string",
      "model_source": "system",
      "cost": 0,
      "cost_pricing_status": "priced",
      "endUserId": "string",
      "apiKeyId": "string",
      "spaceId": "string",
      "metadata": {},
      "generation": {
        "temperature": 0,
        "reasoning_level": "off"
      },
      "generation_override": {
        "temperature": 0,
        "reasoning_level": "off"
      },
      "user_name": "string",
      "end_user_name": "string",
      "api_key_name": "string",
      "schedule_name": "string",
      "runner_name": "string",
      "runner_kind": "string",
      "agent_scope": "string",
      "agent_name": "string",
      "package_ephemeral": true,
      "file_counts": {
        "input": 0,
        "output": 0
      },
      "inline_manifest": {},
      "inline_prompt": "string",
      "unread": true,
      "runNumber": 0,
      "runOrigin": "platform",
      "contextSnapshot": {},
      "modelCredentialId": "string",
      "connection_overrides": {
        "property1": [
          "497f6eca-6276-4993-bfeb-53cbbbba6f08"
        ],
        "property2": [
          "497f6eca-6276-4993-bfeb-53cbbbba6f08"
        ]
      },
      "dependency_overrides": {
        "property1": "string",
        "property2": "string"
      },
      "connections_used": [
        {
          "integration_package_id": "string",
          "label": "string",
          "account_id": "string",
          "source": "admin_pin"
        }
      ]
    }
  ],
  "total": 0,
  "hasMore": true
}
{
  "type": "http://example.com",
  "title": "string",
  "status": 0,
  "detail": "string",
  "instance": "string",
  "code": "string",
  "request_id": "string",
  "param": "string",
  "retry_after": 0,
  "errors": [
    {
      "field": "string",
      "code": "string",
      "message": "string",
      "title": "string",
      "candidate_connections": [
        {
          "id": "string",
          "label": "string",
          "account_id": "string",
          "owned_by_actor": true,
          "needs_reconnection": true
        }
      ],
      "connection_id": "string",
      "missing_scopes": [
        "string"
      ],
      "owned_by_actor": true,
      "required_scopes": [
        "string"
      ],
      "auth_key": "string",
      "required_auth_key": "string",
      "available_auth_keys": [
        "string"
      ],
      "connect_url": "http://example.com",
      "expiresAt": "2019-08-24T14:15:22Z",
      "packageId": "string"
    }
  ]
}
{
  "type": "https://docs.appstrate.dev/errors/unauthorized",
  "title": "Unauthorized",
  "status": 401,
  "detail": "Invalid or missing session",
  "code": "unauthorized",
  "request_id": "req_abc123"
}
{
  "type": "https://docs.appstrate.dev/errors/forbidden",
  "title": "Forbidden",
  "status": 403,
  "detail": "Insufficient permissions",
  "code": "forbidden",
  "request_id": "req_abc123"
}