List Work Items
api/beta/environments/work/list
Nearest release: v2.1.245, published an hour after this site recorded the change. Shown because the two are within 24 hours of each other. Nothing here says the release caused the edit.
api/beta/environments/work/list Changed · +16 / -21 lines
# List Work Items ## Path parameters ## Query parameters ## Headers ## Returns ## Example ### Response (200) ## List Work Items ### Path Parameters ### Query Parameters ### Header Parameters ### Returns ### Example #### Response
---- -title: List Work Items -url: https://platform.claude.com/docs/en/api/beta/environments/work/list ---- +# List Work Items -## List Work Items +**GET** `/v1/environments/{environment_id}/work` -**get** `/v1/environments/{environment_id}/work` - Note: these endpoints are called automatically by the pre-built environment worker provided in the SDKs and CLI, for orchestrating sessions with self-hosted sandbox environments. They are included here as a reference; you do not need to invoke them directly. List work items in an environment. -### Path Parameters +## Path parameters - `environment_id: string` -### Query Parameters +## Query parameters - `limit: optional number` Maximum number of work items to return + default: 20, maximum: 1000, minimum: 1 + - `page: optional string` Opaque cursor from previous response for pagination -### Header Parameters +## Headers - `"anthropic-beta": optional array of AnthropicBeta`
- `"mid-conversation-tool-changes-2026-07-01"` -### Returns +## Returns -- `BetaSelfHostedWorkListResponse object { data, next_page }` +- `BetaSelfHostedWorkListResponse object` Response when listing work items with cursor-based pagination.
Type of work data - - `"session"` - - `environment_id: string` Environment identifier this work belongs to (e.g., `env_...`)
The type of object (always 'work') - - `"work"` + default: work - `next_page: string or null` Opaque cursor for fetching the next page of results -### Example +## Example -```http +```bash curl https://api.anthropic.com/v1/environments/$ENVIRONMENT_ID/work \ -H 'anthropic-version: 2023-06-01' \ -H 'anthropic-beta: managed-agents-2026-04-01' \
-H "X-Api-Key: $ANTHROPIC_API_KEY" ``` -#### Response +### Response (200) ```json {