接入与恢复指南
- 01
发现能力 → 获取报价 → 确认预算 → 执行 → 查询结果
使用 API Key 调用 HTTPS API。获取报价不调用付费上游。保存幂等键和请求体;响应丢失时用原值恢复,不要重复发起付费请求。
curl https://api.anyuse.app/v1/quotes \ -H "Authorization: Bearer $ANYUSE_API_KEY" \ -H "Content-Type: application/json" \ -d '{ "operation": "search.exa.web", "input": { "query": "agent tools" } }' - 02
requires_budget 为 true 时,设置明确的最高预算;否则使用 price_usd。unknown 状态需要核对账单,不表示免费失败。
curl 'https://api.anyuse.app/v1/executions?wait_ms=10000' \ -H "Authorization: Bearer $ANYUSE_API_KEY" \ -H "Idempotency-Key: $SAVED_IDEMPOTENCY_KEY" \ -H "Content-Type: application/json" \ -d '{"quote_id":"<quote.id>","max_cost_usd":"<approved budget>"}' curl https://api.anyuse.app/v1/executions/<execution.id> \ -H "Authorization: Bearer $ANYUSE_API_KEY" - 03
- OpenAPI 3.1下载 Agent 指南JavaScript SDK