---
title: "GET /projects/{projectId}/agent-cases/{caseId}"
method: GET
path: "/projects/{projectId}/agent-cases/{caseId}"
---

# GET /projects/{projectId}/agent-cases/{caseId}

`GET /projects/{projectId}/agent-cases/{caseId}`

## Request

- Base URL: `https://api.caveman.so/api/v1`
- URL: `https://api.caveman.so/api/v1/projects/{projectId}/agent-cases/{caseId}`
- Auth: one of:
  - OAuth 2
    - Authorization code: `/api/v1/oauth/authorize`
    - Token URL: `/api/v1/oauth/token` scopes: `trace:read_metadata`
  - HTTP bearer
  - API key in cookie `cave_access`
  - API key in cookie `__Secure-cave_identity.session_token`

GET /api/v1/projects/{projectId}/agent-cases/{caseId} on the Caveman Cloud control plane. Requires the trace:read_metadata scope. Not exposed to autonomous agents: Native user authority over factory case admission, bounded policy, binding approval and cancellation. An agent session must never read a case, resolve a setup blocker, approve an execution binding, admit paid improvement work or cancel a fence.

## Response `200`

Case projection with its pinned shared allowance and separate case spend.

- FactoryCaseAllowanceProjection: Shared-allowance and case-spend fields of the full factory case. Additional setup, execution, evidence and publication fields retain their existing contracts. A null allowance means historical per-case authorization, not a fresh zero-spend allowance.
  - `id` string, uuid, required
  - `agent_id` string, uuid, required
  - `work_kind` 'setup' | 'improvement', required
  - `allowance` FactoryAllowance, required
    - `id` string, uuid, required
    - `policy_revision` integer, required
    - `limit_micros` string, required: Exact integer micro amount.
    - `spent_micros` string, required: Exact integer micro amount.
    - `reserved_micros` string, required: Exact integer micro amount.
    - `held_micros` string, required: Unknown paid outcomes included in reserved_micros, never added twice.
    - `remaining_micros` string, required: Shared allowance remaining after spend and reservations; organization, project, repository and case ceilings still apply independently.
    - `approved_by` string, uuid, required
    - `approved_at` string, date-time, required
    - `basis` 'attempt_budget_rows_and_gateway_case_keys' | 'attempt_budget_rows', required: attempt_budget_rows_and_gateway_case_keys: the attempt budget row plus the gateway's spend on the factory keys of every case of the attempt. attempt_budget_rows: the row alone, when the gateway could not be read.
  - `spend` FactoryCaseSpend, required
    - `spent_micros` integer, required
    - `reserved_micros` integer, required
    - `held_micros` integer, required
    - `limit_micros` integer, nullable, required
    - `basis` 'case_budget_rows_and_gateway_case_keys' | 'case_budget_rows', required: case_budget_rows_and_gateway_case_keys: the case budget row plus the gateway's spend on the case's factory keys. case_budget_rows: the row alone (no role run or case key, or the gateway could not be read).
  - `authorization` FactoryCaseAuthorization, required
    - `remaining_micros` integer, nullable, required
    - `revoked` boolean, required: Case closure/cancellation fence, separate from a pause on new admissions.
    - `stale_policy` boolean, required
    - `new_admissions_paused` boolean, required
    - `expires_at` string, date-time, nullable, required

## Other responses

- `403`: Native user authority required.
- `404`: Case unavailable in this scope.
- `4XX`: Structured failure. `error.code` is stable; `error.request_id` is echoed in the x-cave-request-id header.
- `5XX`: Structured failure. `error.code` is stable; `error.request_id` is echoed in the x-cave-request-id header.

---

[API](https://skmtc.dev/caveman/apis/caveman-cloud-api.md) - [All operations](https://skmtc.dev/caveman/apis/caveman-cloud-api/llms.txt) - [OpenAPI document](https://skmtc.dev/caveman/apis/caveman-cloud-api/revisions/508312d01cfc?raw)
