跳到主要内容

示例(Examples)

下面的请求体与响应是用于对齐形态的参考示例,不代表可以直接调用的公开生产端点。

提示使用方式
  • 把示例当成“形态参考”,字段以 OpenAPI 为准。
  • 不要从示例推导未公开的 URL 或能力;follow-up URL 只取响应返回值。

推荐阅读

先选你要对齐的示例

最小同步请求

{
"domain": "zhenins",
"execution_mode": "sync",
"required_scopes": [],
"text": "I need an insurance consultation."
}

预期形态:200,包含 outputusage_applications,以及可选的 exact_bridge

{
"output": {
"request_id": "req_example_sync_001",
"trace_id": "trace_example_sync_001",
"status": "completed"
},
"usage_applications": []
}

最小异步响应

{
"domain": "zhenins",
"execution_mode": "async",
"required_scopes": [],
"text": "I need an insurance consultation."
}

预期形态:202,包含 workflow_idstream_urlquery_urlcancel_url

带 Scopes、附件与 structured_input 的扩展请求

{
"domain": "zhenins",
"execution_mode": "async",
"required_scopes": ["scope.required.by.your.integration"],
"request_id": "req_example_001",
"trace_id": "trace_example_001",
"idempotency_key": "idem_example_001",
"attachments": [
{
"attachment_id": "att_policy_001",
"kind": "document",
"url": "https://example.com/policy-summary.pdf",
"metadata": {
"filename": "policy-summary.pdf"
}
}
],
"structured_input": {
"protocol_context": {
"demand": {
"identity": {
"demand_id": "dm_example_extended_001",
"protocol_version": "c2ai2x-core/v1",
"created_at": "2026-07-10T00:00:00Z",
"source_surface": "partner_api",
"source_type": "api"
},
"intent": {
"category": "service_request",
"goal": "review_coverage",
"requested_outcome": "next_best_action",
"priority": "normal",
"urgency": "medium",
"budget": {},
"timeline": {},
"region": "US-CA"
},
"input_context": {
"raw_input": "Please review my existing coverage and suggest next steps.",
"structured_summary": "User wants a review of current coverage and recommended next actions.",
"conversation_refs": [],
"attachment_refs": ["att_policy_001"],
"external_refs": []
},
"constraints": {},
"authorization": {
"redaction_policy": "default_redact_contact",
"revocable": true
},
"state": {
"demand_state": "submitted",
"routing_status": "pending",
"execution_status": "not_started",
"settlement_status": "not_applicable"
}
},
"authorization_grant": {
"grant_id": "grant_example_001",
"demand_id": "dm_example_extended_001",
"status": "issued",
"grantor": {
"actor_type": "requester",
"actor_id": "user_001",
"actor_role": "requester"
},
"grantee": {
"actor_type": "service",
"actor_id": "partner_app",
"actor_role": "integrator"
},
"data_scope": ["read_summary"],
"action_scope": ["execute"],
"automation_policy": "human_confirmation_required",
"redaction_policy": "default_redact_contact",
"constraints": {},
"issued_at": "2026-07-10T00:00:00Z"
}
}
}
}

In the current live contract, Demand and AuthorizationGrant are shown here only as protocol-layer objects carried through structured_input. Platform admission still decides whether the request is allowed to execute.

Role choreography case cards

For scenario-driven reference cards (R/A/H/C), see: case-cards.md.

推荐阅读

继续阅读