작업 항목 조회
GET/v1/environments/{environment_id}/work/{work_id}
특정 작업 항목에 대한 자세한 정보를 조회합니다.
이 엔드포인트는 Claude API 키를 허용합니다. 환경 키와 작업 항목의 secret은 거부합니다. Claude Platform on AWS 또는 Claude Models on Google Cloud (Anthropic managed)에서는 대신 해당 플랫폼의 자격 증명을 사용하세요.
작업 항목 조회
require "anthropic"
anthropic = Anthropic::Client.new(api_key: "my-anthropic-api-key")
beta_self_hosted_work = anthropic.beta.environments.work.retrieve("work_id", environment_id: "env_011CZkZ9X2dpNyB7HsEFoRfW")
puts(beta_self_hosted_work)Response 200
{
"id": "id",
"acknowledged_at": "acknowledged_at",
"created_at": "created_at",
"data": {
"id": "id",
"type": "session"
},
"environment_id": "environment_id",
"latest_heartbeat_at": "latest_heartbeat_at",
"metadata": {
"foo": "string"
},
"secret": "secret",
"started_at": "started_at",
"state": "queued",
"stop_requested_at": "stop_requested_at",
"stopped_at": "stopped_at",
"type": "work"
}Returns Examples
Response 200
{
"id": "id",
"acknowledged_at": "acknowledged_at",
"created_at": "created_at",
"data": {
"id": "id",
"type": "session"
},
"environment_id": "environment_id",
"latest_heartbeat_at": "latest_heartbeat_at",
"metadata": {
"foo": "string"
},
"secret": "secret",
"started_at": "started_at",
"state": "queued",
"stop_requested_at": "stop_requested_at",
"stopped_at": "stopped_at",
"type": "work"
}