获取审查条目
GET/v1/compliance/review/items/{item_id}
读取 Anthropic 标记供您的组织审查的一条消息,包括其请求和响应。
对于该 API 密钥无法读取的消息或未被标记的消息,返回的 404 与不存在的消息相同。对于与用户配置文件一起记录的消息,请在 anthropic-user-profile-id 标头中发送该配置文件的 ID。如果被标记的消息属于该密钥所属组织以外的其他组织,或属于您最终客户的用户配置文件或工作区,也可能返回 404。
如果您的加密密钥或存储桶拒绝读取,API 将返回 400,并在 error.details.error_code 中包含 cmek_key_disabled、storage_bucket_unreadable 或 customer_storage_refusal_unattributed。
该 API 密钥必须具有 read:compliance_review_items、read:compliance_user_data 或 read:org_audit 范围。没有父组织的组织的密钥必须具有 read:compliance_review_items。
Parameters
Returns
获取审查条目
package com.anthropic.example;
import com.anthropic.client.AnthropicClient;
import com.anthropic.client.okhttp.AnthropicOkHttpClient;
import com.anthropic.models.beta.compliance.review.items.BetaComplianceReviewItem;
import com.anthropic.models.beta.compliance.review.items.ItemRetrieveParams;
public final class Main {
private Main() {}
public static void main(String[] args) {
AnthropicClient client = AnthropicOkHttpClient.fromEnv();
BetaComplianceReviewItem betaComplianceReviewItem = client.beta().compliance().review().items().retrieve("item_id");
}
}Response 200
{
"id": "id",
"actor": {
"email_address": "email_address",
"type": "user_actor",
"user_id": "user_id"
},
"content_expires_at": "2019-12-27T18:11:19.117Z",
"created_at": "2019-12-27T18:11:19.117Z",
"details": {
"content": {
"request": {
"foo": "bar"
},
"response": {
"id": "msg_013Zva2CMHLNnXjNJJKqJ2EF",
"container": {
"id": "container_011CpZohnwH4vuy7gazohgSP",
"expires_at": "2019-12-27T18:11:19.117Z",
"skills": [
{
"skill_id": "pdf",
"type": "anthropic",
"version": "latest"
}
]
},
"content": [
{
"citations": null,
"text": "Hi! My name is Claude.",
"type": "text"
}
],
"context_management": {
"applied_edits": [
{
"cleared_input_tokens": 0,
"cleared_tool_uses": 0,
"type": "clear_tool_uses_20250919"
}
]
},
"diagnostics": null,
"model": "claude-opus-5-5",
"role": "assistant",
"stop_details": null,
"stop_reason": "end_turn",
"stop_sequence": null,
"type": "message",
"usage": {
"cache_creation": {
"ephemeral_1h_input_tokens": 0,
"ephemeral_5m_input_tokens": 0
},
"cache_creation_input_tokens": 2051,
"cache_read_input_tokens": 2051,
"fallback_credit": {
"status": {
"type": "redeemed"
}
},
"inference_geo": "global",
"input_tokens": 2095,
"iterations": [
{
"cache_creation": {
"ephemeral_1h_input_tokens": 0,
"ephemeral_5m_input_tokens": 0
},
"cache_creation_input_tokens": 0,
"cache_read_input_tokens": 0,
"input_tokens": 0,
"model": "claude-fable-5-2",
"output_tokens": 0,
"type": "message"
}
],
"output_tokens": 503,
"output_tokens_details": {
"thinking_tokens": 0
},
"server_tool_use": {
"web_fetch_requests": 2,
"web_search_requests": 0
},
"service_tier": "standard",
"speed": "standard"
},
"input_transformations": [
{
"path": "path",
"reason": "model_binding_mismatch",
"type": "thinking_dropped"
}
]
},
"type": "create_message"
},
"content_unavailable_reason": {
"type": "not_captured"
},
"model": "model",
"type": "message"
},
"organization_id": "organization_id",
"read_reason": {
"type": "safeguards_review"
},
"type": "compliance_review_item",
"user_profile_id": "user_profile_id",
"workspace_id": "workspace_id"
}Returns Examples
Response 200
{
"id": "id",
"actor": {
"email_address": "email_address",
"type": "user_actor",
"user_id": "user_id"
},
"content_expires_at": "2019-12-27T18:11:19.117Z",
"created_at": "2019-12-27T18:11:19.117Z",
"details": {
"content": {
"request": {
"foo": "bar"
},
"response": {
"id": "msg_013Zva2CMHLNnXjNJJKqJ2EF",
"container": {
"id": "container_011CpZohnwH4vuy7gazohgSP",
"expires_at": "2019-12-27T18:11:19.117Z",
"skills": [
{
"skill_id": "pdf",
"type": "anthropic",
"version": "latest"
}
]
},
"content": [
{
"citations": null,
"text": "Hi! My name is Claude.",
"type": "text"
}
],
"context_management": {
"applied_edits": [
{
"cleared_input_tokens": 0,
"cleared_tool_uses": 0,
"type": "clear_tool_uses_20250919"
}
]
},
"diagnostics": null,
"model": "claude-opus-5-5",
"role": "assistant",
"stop_details": null,
"stop_reason": "end_turn",
"stop_sequence": null,
"type": "message",
"usage": {
"cache_creation": {
"ephemeral_1h_input_tokens": 0,
"ephemeral_5m_input_tokens": 0
},
"cache_creation_input_tokens": 2051,
"cache_read_input_tokens": 2051,
"fallback_credit": {
"status": {
"type": "redeemed"
}
},
"inference_geo": "global",
"input_tokens": 2095,
"iterations": [
{
"cache_creation": {
"ephemeral_1h_input_tokens": 0,
"ephemeral_5m_input_tokens": 0
},
"cache_creation_input_tokens": 0,
"cache_read_input_tokens": 0,
"input_tokens": 0,
"model": "claude-fable-5-2",
"output_tokens": 0,
"type": "message"
}
],
"output_tokens": 503,
"output_tokens_details": {
"thinking_tokens": 0
},
"server_tool_use": {
"web_fetch_requests": 2,
"web_search_requests": 0
},
"service_tier": "standard",
"speed": "standard"
},
"input_transformations": [
{
"path": "path",
"reason": "model_binding_mismatch",
"type": "thinking_dropped"
}
]
},
"type": "create_message"
},
"content_unavailable_reason": {
"type": "not_captured"
},
"model": "model",
"type": "message"
},
"organization_id": "organization_id",
"read_reason": {
"type": "safeguards_review"
},
"type": "compliance_review_item",
"user_profile_id": "user_profile_id",
"workspace_id": "workspace_id"
}