API 参考
遥测与优化
上报在网关之外发起的调用、为请求选择模型、查找和存储缓存的回答、检查智能体是否陷入循环、压缩长内容,以及查询提供商市场。
路由摘要和字段名称均以英文撰写,本页与文件中都是如此。
/api/ingest
POST /api/ingest
Ingest AI usage events
认证
API 密钥
密钥作用域
ingest:write请求体
events (必填)应答
200 · 400 validation_failed · 401 api_key_missing, api_key_invalid · 402 budget_exceeded · 403 api_key_scope_denied, api_key_role_denied, ip_not_allowed, eu_storage_unavailable · 413 validation_failed · 429 ingest_queue_full · 500 internal_error · 503 service_unavailable · 504/api/arbiter
POST /api/arbiter/route
Select optimal model for a request
认证
API 密钥
密钥作用域
inference:write请求体
agentId · promptTokens · mode · qualityFloor · latencyCeilingMs · budgetUsd · candidates应答
200 · 400 validation_failed · 401 api_key_missing, api_key_invalid · 402 budget_exceeded · 403 policy_blocked, sovereignty_blocked, jurisdiction_blocked, kill_switch_active, human_review_not_resumable, api_key_scope_denied · 429 · 500 internal_error · 503 budget_unavailable, governance_error/api/cache
POST /api/cache/lookup
Look up a cached answer for a prompt
认证
API 密钥
密钥作用域
cache:read请求体
prompt (必填) · threshold · model应答
200 · 400 validation_failed · 401 api_key_missing, api_key_invalid · 403 api_key_scope_denied, api_key_role_denied, ip_not_allowed · 429 · 500 internal_errorPOST /api/cache/store
Store a prompt and its answer in the cache
认证
API 密钥
密钥作用域
cache:write请求体
prompt (必填) · response (必填) · model (必填) · provider (必填) · costUsd · ttlMs应答
200 · 400 validation_failed · 401 api_key_missing, api_key_invalid · 403 api_key_scope_denied, api_key_role_denied, ip_not_allowed · 429 · 500 internal_error/api/loops
POST /api/loops/check
Check an agent for a loop, reset its counters, or read its state
认证
API 密钥
密钥作用域
advisory:read请求体
action · agentId (必填) · workflowId · prompt · model · costUsd应答
200 · 400 validation_failed · 401 api_key_missing, api_key_invalid · 403 api_key_scope_denied, api_key_role_denied, ip_not_allowed · 429 · 500 internal_error/api/v1/compress
POST /api/v1/compress
Compress long reasoning content (levels L1 to L3)
认证
API 密钥
密钥作用域
advisory:read模块
在部署运行
FEATURE_CCE 时提供。请求体
content (必填) · level · agentId · workflowId · traceId应答
200 · 400 validation_failed · 401 api_key_missing, api_key_invalid · 403 api_key_scope_denied, api_key_role_denied, ip_not_allowed · 429 · 500 internal_error · 501 feature_disabled/api/v1/reconstruct
POST /api/v1/reconstruct
Reconstruct compressed content from its id
认证
API 密钥
密钥作用域
advisory:read模块
在部署运行
FEATURE_CCE 时提供。请求体
cognitiveStateId (必填)应答
200 · 400 validation_failed · 401 api_key_missing, api_key_invalid · 403 api_key_scope_denied, api_key_role_denied, ip_not_allowed · 404 not_found · 429 · 500 internal_error · 501 feature_disabled/api/v1/marketplace
GET /api/v1/marketplace
The best-fit model of the provider marketplace for your constraints
认证
API 密钥
密钥作用域
advisory:read模块
在部署运行
FEATURE_MARKETPLACE 时提供。参数
mode · maxCostPer1k · maxLatencyMs · minQuality · requiresVision · requiresTools · minContextWindow应答
200 · 401 api_key_missing, api_key_invalid · 403 api_key_scope_denied, api_key_role_denied, ip_not_allowed · 404 · 429 · 500 internal_error · 501 feature_disabled