响应审查案例
POST/v1/compliance/review/cases/{case_id}/respond
发送您对审查案例的结论。响应会关闭该案例,且已关闭的案例无法重新打开。
只有第一次响应有效。请求可以安全地重复发送:如果已关闭的案例具有相同字段值的响应(列表顺序不限),API 将返回 200 且不做任何更改。如果已关闭的案例具有不同的响应或没有响应,API 将返回 400,并在 error.details.error_code 中包含 case_closed。
如果由您的最终客户而非您来审查此案例,API 将返回 403,并在 error.details.error_code 中包含 case_reviewed_by_end_customer。
具有 write:compliance_review_cases 范围的 Admin API 密钥可以调用此端点。
Parameters
Returns
响应审查案例
package com.anthropic.example;
import com.anthropic.client.AnthropicClient;
import com.anthropic.client.okhttp.AnthropicOkHttpClient;
import com.anthropic.models.beta.compliance.review.cases.BetaComplianceReviewCase;
import com.anthropic.models.beta.compliance.review.cases.BetaComplianceReviewDetermination;
import com.anthropic.models.beta.compliance.review.cases.CaseRespondParams;
public final class Main {
private Main() {}
public static void main(String[] args) {
AnthropicClient client = AnthropicOkHttpClient.fromEnv();
CaseRespondParams params = CaseRespondParams.builder()
.caseId("case_id")
.determination(BetaComplianceReviewDetermination.NO_VIOLATION)
.build();
BetaComplianceReviewCase betaComplianceReviewCase = client.beta().compliance().review().cases().respond(params);
}
}Response 200
{
"id": "id",
"created_at": "2019-12-27T18:11:19.117Z",
"enforcement_action": {
"type": "type"
},
"organization_id": "organization_id",
"policy_categories": [
"cyber"
],
"status": {
"type": "open"
},
"transcripts": [
{
"item_id": "item_id",
"user_profile_id": "user_profile_id"
}
],
"type": "compliance_review_case",
"updated_at": "2019-12-27T18:11:19.117Z",
"workspace_id": "workspace_id"
}Returns Examples
Response 200
{
"id": "id",
"created_at": "2019-12-27T18:11:19.117Z",
"enforcement_action": {
"type": "type"
},
"organization_id": "organization_id",
"policy_categories": [
"cyber"
],
"status": {
"type": "open"
},
"transcripts": [
{
"item_id": "item_id",
"user_profile_id": "user_profile_id"
}
],
"type": "compliance_review_case",
"updated_at": "2019-12-27T18:11:19.117Z",
"workspace_id": "workspace_id"
}