{"openapi":"3.1.0","info":{"title":"AITBC Agent Coordinator","description":"Advanced multi-agent coordination and management system","version":"1.0.0"},"paths":{"/v1/agents/register":{"post":{"summary":"Register Agent","description":"Register a new agent.\n\nIdentity binding (docs/agent-coordinator/agent-signed-envelopes.md §3):\nsupplying ``identity_address`` + ``identity_proof`` binds the agent_id to\nthat secp256k1 wallet (the escrow payout address). Once bound, a plain\nre-registration must re-prove the *bound* key — anything else is a\nhijack attempt and gets 409; rotation goes through\n``PUT /v1/agents/{agent_id}/identity``. In ``enforce`` mode the attestation\nis mandatory; in ``advisory``/``disabled`` agents may still register\nunsigned with ``identity_address = null``.","operationId":"register_agent_v1_agents_register_post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/AgentRegistrationRequest"}}},"required":true},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"additionalProperties":true,"type":"object","title":"Response Register Agent V1 Agents Register Post"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/agents/discover":{"post":{"summary":"Discover Agents","description":"Discover agents based on criteria","operationId":"discover_agents_v1_agents_discover_post","requestBody":{"content":{"application/json":{"schema":{"additionalProperties":true,"type":"object","title":"Query"}}},"required":true},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"additionalProperties":true,"type":"object","title":"Response Discover Agents V1 Agents Discover Post"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/agents/nonce":{"get":{"summary":"Issue Registration Nonce","description":"Issue a one-time 300s nonce for the registration identity claim (doc §3).\n\nThe response echoes ``chain_id`` so the caller knows which value to put in\nthe claim it signs.","operationId":"issue_registration_nonce_v1_agents_nonce_get","parameters":[{"name":"agent_id","in":"query","required":true,"schema":{"type":"string","description":"Agent ID","title":"Agent Id"},"description":"Agent ID"}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","additionalProperties":true,"title":"Response Issue Registration Nonce V1 Agents Nonce Get"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/agents/{agent_id}":{"get":{"summary":"Get Agent","description":"Get agent information by ID","operationId":"get_agent_v1_agents__agent_id__get","parameters":[{"name":"agent_id","in":"path","required":true,"schema":{"type":"string","title":"Agent Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","additionalProperties":true,"title":"Response Get Agent V1 Agents  Agent Id  Get"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/agents/{agent_id}/status":{"put":{"summary":"Update Agent Status","description":"Update agent status.\n\nPhase C agent-scoped: ``enforce`` requires a principal bound to\n``agent_id`` (agent JWT or ``X-Agent-*`` signed headers) or an admin;\n``advisory`` logs and allows; ``disabled`` is a no-op.","operationId":"update_agent_status_v1_agents__agent_id__status_put","parameters":[{"name":"agent_id","in":"path","required":true,"schema":{"type":"string","title":"Agent Id"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/AgentStatusUpdate"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","additionalProperties":true,"title":"Response Update Agent Status V1 Agents  Agent Id  Status Put"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/agents/{agent_id}/identity":{"put":{"summary":"Rotate Agent Identity","description":"Rotate the identity bound to ``agent_id`` — the doc §7 dual-proof scheme.\n\nRequires ``new_proof`` (the new key signing the registration claim, over a\nfresh one-time nonce) **and** ``rotation_proof`` (the currently bound key\nsigning ``{agent_id, old_address, new_address, timestamp}``). Both must\nverify; old messages keep verifying against their embedded ``signer``.","operationId":"rotate_agent_identity_v1_agents__agent_id__identity_put","parameters":[{"name":"agent_id","in":"path","required":true,"schema":{"type":"string","title":"Agent Id"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/IdentityRotationRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","additionalProperties":true,"title":"Response Rotate Agent Identity V1 Agents  Agent Id  Identity Put"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/agents/{agent_id}/heartbeat":{"post":{"summary":"Agent Heartbeat","description":"Receive heartbeat from agent.\n\nPhase C agent-scoped: ``enforce`` requires a principal bound to\n``agent_id`` (agent JWT or ``X-Agent-*`` signed headers) or an admin;\n``advisory`` logs and allows; ``disabled`` is a no-op.","operationId":"agent_heartbeat_v1_agents__agent_id__heartbeat_post","parameters":[{"name":"agent_id","in":"path","required":true,"schema":{"type":"string","title":"Agent Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","additionalProperties":true,"title":"Response Agent Heartbeat V1 Agents  Agent Id  Heartbeat Post"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/tasks/submit":{"post":{"summary":"Submit Task","description":"Submit a task for distribution.\n\nPhase C: in ``enforce`` mode the call must carry a resolvable credential —\na buyer agent JWT, ``X-Agent-*`` signed headers or the shared operator key\n(``advisory`` logs ``admin_auth_missing`` and allows; ``disabled`` is a\nno-op). Any resolved principal may submit; payment escrows are bound to\nthe buyer by the lock transaction's own signature, not by this check.","operationId":"submit_task_v1_tasks_submit_post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/TaskSubmission"}}},"required":true},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"additionalProperties":true,"type":"object","title":"Response Submit Task V1 Tasks Submit Post"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/tasks/status":{"get":{"summary":"Get Task Status","description":"Get task distribution statistics","operationId":"get_task_status_v1_tasks_status_get","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"additionalProperties":true,"type":"object","title":"Response Get Task Status V1 Tasks Status Get"}}}}}}},"/v1/tasks/queues":{"get":{"summary":"Get Queue Sizes","description":"Get task queue sizes","operationId":"get_queue_sizes_v1_tasks_queues_get","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"additionalProperties":true,"type":"object","title":"Response Get Queue Sizes V1 Tasks Queues Get"}}}}}}},"/v1/tasks/queues/{priority}/clear":{"post":{"summary":"Clear Queue","description":"Clear a priority queue.\n\nPhase C admin/operator-only: ``enforce`` → 401 without a principal, 403\nfor a non-admin one; ``advisory`` logs and allows; ``disabled`` is a no-op.","operationId":"clear_queue_v1_tasks_queues__priority__clear_post","parameters":[{"name":"priority","in":"path","required":true,"schema":{"type":"string","title":"Priority"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","additionalProperties":true,"title":"Response Clear Queue V1 Tasks Queues  Priority  Clear Post"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/tasks/queues/stats":{"get":{"summary":"Get Queue Stats","description":"Get detailed queue statistics","operationId":"get_queue_stats_v1_tasks_queues_stats_get","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"additionalProperties":true,"type":"object","title":"Response Get Queue Stats V1 Tasks Queues Stats Get"}}}}}}},"/v1/tasks/escrow/{escrow_id}":{"get":{"summary":"Get Escrow Status","description":"Get payment escrow status by escrow ID.","operationId":"get_escrow_status_v1_tasks_escrow__escrow_id__get","parameters":[{"name":"escrow_id","in":"path","required":true,"schema":{"type":"string","title":"Escrow Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","additionalProperties":true,"title":"Response Get Escrow Status V1 Tasks Escrow  Escrow Id  Get"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/tasks/{task_id}/complete":{"post":{"summary":"Complete Task","description":"Mark a task as complete — releases escrow payment to agent (v0.6.5).\n\nOptional JSON body ``{\"amount_units\": int}`` bills a partial amount of the\nlocked escrow; the unbilled remainder is refunded to the buyer on-chain.\nRequires a signature from the escrow's provider wallet (``entry.agent``)\nover ``{\"action\",\"task_id\",\"signed_at\",\"amount_units\"}`` — only the party\nthat will be paid may release the escrow. The Phase-B3 ``agent_signature``\n(req-v1) form over ``{\"task_id\",\"amount_units\",\"timestamp\",\"nonce\"}`` is\naccepted equivalently — see ``_require_provider_signature``.","operationId":"complete_task_v1_tasks__task_id__complete_post","parameters":[{"name":"task_id","in":"path","required":true,"schema":{"type":"string","title":"Task Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","additionalProperties":true,"title":"Response Complete Task V1 Tasks  Task Id  Complete Post"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/tasks/{task_id}/fail":{"post":{"summary":"Fail Task","description":"Mark a task as failed — refunds escrow payment to requester (v0.6.5).\n\nRequires a signature from the escrow's provider wallet over\n``{\"action\",\"task_id\",\"signed_at\"}`` — the provider reports its own\nfailure; the Phase-B3 ``agent_signature`` (req-v1) form over\n``{\"task_id\",\"reason\",\"timestamp\",\"nonce\"}`` is accepted equivalently.\nBuyer-side refunds happen via the escrow timeout sweeper, not\nthis endpoint.","operationId":"fail_task_v1_tasks__task_id__fail_post","parameters":[{"name":"task_id","in":"path","required":true,"schema":{"type":"string","title":"Task Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","additionalProperties":true,"title":"Response Fail Task V1 Tasks  Task Id  Fail Post"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/tasks/{task_id}/escrow":{"get":{"summary":"Get Task Escrow","description":"Get the payment escrow for a task (v0.25).","operationId":"get_task_escrow_v1_tasks__task_id__escrow_get","parameters":[{"name":"task_id","in":"path","required":true,"schema":{"type":"string","title":"Task Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","additionalProperties":true,"title":"Response Get Task Escrow V1 Tasks  Task Id  Escrow Get"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/tasks/escrow-config":{"get":{"summary":"Get Escrow Config","description":"Escrow settlement parameters for buyers (v0.25).\n\nReturns the node wallet the coordinator settles escrows through, so a\nremote buyer can sign its ESCROW_LOCK to the right custodian without\nknowing the hub's local RPC topology. The address is public on-chain.","operationId":"get_escrow_config_v1_tasks_escrow_config_get","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"additionalProperties":true,"type":"object","title":"Response Get Escrow Config V1 Tasks Escrow Config Get"}}}}}}},"/v1/tasks/escrow/expire-stale":{"post":{"summary":"Expire Stale Escrows","description":"Expire and refund all stale escrows that have passed their timeout (v0.6.5).\n\nPhase C admin/operator-only: ``enforce`` → 401 without a principal, 403\nfor a non-admin one; ``advisory`` logs and allows; ``disabled`` is a no-op.","operationId":"expire_stale_escrows_v1_tasks_escrow_expire_stale_post","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"additionalProperties":true,"type":"object","title":"Response Expire Stale Escrows V1 Tasks Escrow Expire Stale Post"}}}}}}},"/api/v1/agent/messages/send":{"post":{"tags":["agent-messaging"],"summary":"Send Encrypted Message","description":"Send encrypted message to agent, trying WebSocket first then storage.\n\nA client-provided ``message_id`` makes the call idempotent: if a message\nwith that ID already exists, the existing record is returned without\nre-sending.  After the first call the message status is ``pending`` until\nthe WebSocket layer confirms delivery (``delivered``).","operationId":"send_encrypted_message_api_v1_agent_messages_send_post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/SendMessageRequest"}}},"required":true},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"additionalProperties":true,"type":"object","title":"Response Send Encrypted Message Api V1 Agent Messages Send Post"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/agent/messages/inbox":{"get":{"tags":["agent-messaging"],"summary":"Get Inbox","description":"Get agent's inbox. Enforce mode: only the bound principal (or an admin)\nmay read an agent's inbox; advisory/disabled keep the open read.","operationId":"get_inbox_api_v1_agent_messages_inbox_get","parameters":[{"name":"agent_id","in":"query","required":true,"schema":{"type":"string","description":"Agent ID","title":"Agent Id"},"description":"Agent ID"},{"name":"limit","in":"query","required":false,"schema":{"type":"integer","description":"Maximum messages","default":100,"title":"Limit"},"description":"Maximum messages"},{"name":"unread_only","in":"query","required":false,"schema":{"type":"boolean","description":"Only unread messages","default":false,"title":"Unread Only"},"description":"Only unread messages"}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","additionalProperties":true,"title":"Response Get Inbox Api V1 Agent Messages Inbox Get"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/agent/messages/history":{"get":{"tags":["agent-messaging"],"summary":"Get Message History","description":"Get message history with optional filters.\n\nEnforce mode: an authenticated non-admin principal may only read its own\nrecords — ``sender_id``/``receiver_id`` filters must equal its agent_id,\nand an unfiltered query returns only messages it is a party to (never\n``get_all_messages``). Admin principals keep the full view. Advisory and\ndisabled keep the historical open behaviour (mismatches are logged).","operationId":"get_message_history_api_v1_agent_messages_history_get","parameters":[{"name":"sender_id","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"description":"Filter by sender ID","title":"Sender Id"},"description":"Filter by sender ID"},{"name":"receiver_id","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"description":"Filter by receiver ID","title":"Receiver Id"},"description":"Filter by receiver ID"},{"name":"limit","in":"query","required":false,"schema":{"type":"integer","description":"Maximum number of messages","default":100,"title":"Limit"},"description":"Maximum number of messages"},{"name":"offset","in":"query","required":false,"schema":{"type":"integer","description":"Offset for pagination","default":0,"title":"Offset"},"description":"Offset for pagination"}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","additionalProperties":true,"title":"Response Get Message History Api V1 Agent Messages History Get"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/agent/messages/discover":{"get":{"tags":["agent-messaging"],"summary":"Discover Agents","description":"Discover agents by criteria","operationId":"discover_agents_api_v1_agent_messages_discover_get","parameters":[{"name":"capability","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"description":"Filter by capability","title":"Capability"},"description":"Filter by capability"},{"name":"agent_type","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"description":"Filter by agent type","title":"Agent Type"},"description":"Filter by agent type"},{"name":"min_health_score","in":"query","required":false,"schema":{"type":"number","description":"Minimum health score","default":0.0,"title":"Min Health Score"},"description":"Minimum health score"},{"name":"limit","in":"query","required":false,"schema":{"type":"integer","description":"Maximum results","default":50,"title":"Limit"},"description":"Maximum results"}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","additionalProperties":true,"title":"Response Discover Agents Api V1 Agent Messages Discover Get"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/agent/messages/subscribe":{"post":{"tags":["agent-messaging"],"summary":"Subscribe To Topic","description":"Subscribe agent to topic and persist the subscription.\n\nEnforce mode: only the bound principal (or an admin) may subscribe an\nagent; advisory/disabled keep the open behaviour.","operationId":"subscribe_to_topic_api_v1_agent_messages_subscribe_post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/SubscribeRequest"}}},"required":true},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"additionalProperties":true,"type":"object","title":"Response Subscribe To Topic Api V1 Agent Messages Subscribe Post"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/agent/messages/unsubscribe":{"post":{"tags":["agent-messaging"],"summary":"Unsubscribe From Topic","description":"Unsubscribe agent from topic and remove the persisted subscription.\n\nEnforce mode: only the bound principal (or an admin) may unsubscribe an\nagent; advisory/disabled keep the open behaviour.","operationId":"unsubscribe_from_topic_api_v1_agent_messages_unsubscribe_post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/SubscribeRequest"}}},"required":true},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"additionalProperties":true,"type":"object","title":"Response Unsubscribe From Topic Api V1 Agent Messages Unsubscribe Post"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/agent/messages/subscriptions/{agent_id}":{"get":{"tags":["agent-messaging"],"summary":"Get Agent Subscriptions","description":"Get persisted topic subscriptions for an agent.\n\nEnforce mode: only the bound principal (or an admin) may read an agent's\nsubscriptions; advisory/disabled keep the open behaviour.","operationId":"get_agent_subscriptions_api_v1_agent_messages_subscriptions__agent_id__get","parameters":[{"name":"agent_id","in":"path","required":true,"schema":{"type":"string","title":"Agent Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","additionalProperties":true,"title":"Response Get Agent Subscriptions Api V1 Agent Messages Subscriptions  Agent Id  Get"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/agent/messages/broadcast":{"post":{"tags":["agent-messaging"],"summary":"Broadcast Message","description":"Broadcast message to multiple agents.\n\nPhase C admin/operator-only: ``enforce`` → 401 without a principal, 403\nfor a non-admin one; ``advisory`` logs and allows; ``disabled`` is a\nno-op. The stored sender stays the derived ``agent-coordinator`` — the\nbroadcast speaks as the coordinator, never as the caller.","operationId":"broadcast_message_api_v1_agent_messages_broadcast_post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/BroadcastRequest"}}},"required":true},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"additionalProperties":true,"type":"object","title":"Response Broadcast Message Api V1 Agent Messages Broadcast Post"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/agent/messages/id/{message_id}":{"get":{"tags":["agent-messaging"],"summary":"Get Message","description":"Get a specific message by ID.\n\nEnforce mode: only a party to the message (sender or receiver — or an\nadmin) may read it; advisory/disabled keep the open read.","operationId":"get_message_api_v1_agent_messages_id__message_id__get","parameters":[{"name":"message_id","in":"path","required":true,"schema":{"type":"string","title":"Message Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","additionalProperties":true,"title":"Response Get Message Api V1 Agent Messages Id  Message Id  Get"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/agent/messages/id/{message_id}/read":{"post":{"tags":["agent-messaging"],"summary":"Mark Message Read","description":"Mark a specific message as read.\n\nEnforce mode: only the message's receiver (or an admin) may mark it read —\nthe read flag is the receiver's state, so the sender may not flip it;\nadvisory/disabled keep the open behaviour.","operationId":"mark_message_read_api_v1_agent_messages_id__message_id__read_post","parameters":[{"name":"message_id","in":"path","required":true,"schema":{"type":"string","title":"Message Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","additionalProperties":true,"title":"Response Mark Message Read Api V1 Agent Messages Id  Message Id  Read Post"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/agent/messages/load-balancer/stats":{"get":{"tags":["agent-messaging"],"summary":"Get Load Balancer Stats","description":"Get load balancer statistics.\n\nPhase C admin/operator-only: ``enforce`` → 401 without a principal, 403\nfor a non-admin one; ``advisory`` logs and allows; ``disabled`` is a no-op.","operationId":"get_load_balancer_stats_api_v1_agent_messages_load_balancer_stats_get","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"additionalProperties":true,"type":"object","title":"Response Get Load Balancer Stats Api V1 Agent Messages Load Balancer Stats Get"}}}}}}},"/api/v1/agent/messages/registry/stats":{"get":{"tags":["agent-messaging"],"summary":"Get Registry Stats","description":"Get agent registry statistics.\n\nPhase C admin/operator-only: ``enforce`` → 401 without a principal, 403\nfor a non-admin one; ``advisory`` logs and allows; ``disabled`` is a no-op.","operationId":"get_registry_stats_api_v1_agent_messages_registry_stats_get","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"additionalProperties":true,"type":"object","title":"Response Get Registry Stats Api V1 Agent Messages Registry Stats Get"}}}}}}},"/api/v1/agent/messages/agents/service/{service}":{"get":{"tags":["agent-messaging"],"summary":"Get Agents By Service","description":"Get agents that provide a specific service","operationId":"get_agents_by_service_api_v1_agent_messages_agents_service__service__get","parameters":[{"name":"service","in":"path","required":true,"schema":{"type":"string","title":"Service"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","additionalProperties":true,"title":"Response Get Agents By Service Api V1 Agent Messages Agents Service  Service  Get"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/agent/messages/agents/capability/{capability}":{"get":{"tags":["agent-messaging"],"summary":"Get Agents By Capability","description":"Get agents that have a specific capability","operationId":"get_agents_by_capability_api_v1_agent_messages_agents_capability__capability__get","parameters":[{"name":"capability","in":"path","required":true,"schema":{"type":"string","title":"Capability"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","additionalProperties":true,"title":"Response Get Agents By Capability Api V1 Agent Messages Agents Capability  Capability  Get"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/agent/messages/load-balancer/strategy":{"put":{"tags":["agent-messaging"],"summary":"Set Load Balancing Strategy","description":"Set load balancing strategy.\n\nPhase C admin/operator-only: ``enforce`` → 401 without a principal, 403\nfor a non-admin one; ``advisory`` logs and allows; ``disabled`` is a no-op.","operationId":"set_load_balancing_strategy_api_v1_agent_messages_load_balancer_strategy_put","parameters":[{"name":"strategy","in":"query","required":true,"schema":{"type":"string","description":"Load balancing strategy","title":"Strategy"},"description":"Load balancing strategy"}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","additionalProperties":true,"title":"Response Set Load Balancing Strategy Api V1 Agent Messages Load Balancer Strategy Put"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/agent/messages/peers/add":{"post":{"tags":["agent-messaging"],"summary":"Add Peer","description":"Add a peer connection for an agent.\n\nPhase C admin/operator-only: ``enforce`` → 401 without a principal, 403\nfor a non-admin one; ``advisory`` logs and allows; ``disabled`` is a no-op.","operationId":"add_peer_api_v1_agent_messages_peers_add_post","parameters":[{"name":"agent_id","in":"query","required":true,"schema":{"type":"string","description":"Agent ID","title":"Agent Id"},"description":"Agent ID"},{"name":"peer_id","in":"query","required":true,"schema":{"type":"string","description":"Peer agent ID","title":"Peer Id"},"description":"Peer agent ID"}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","additionalProperties":true,"title":"Response Add Peer Api V1 Agent Messages Peers Add Post"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/agent/messages/peers/remove":{"post":{"tags":["agent-messaging"],"summary":"Remove Peer","description":"Remove a peer connection for an agent.\n\nPhase C admin/operator-only: ``enforce`` → 401 without a principal, 403\nfor a non-admin one; ``advisory`` logs and allows; ``disabled`` is a no-op.","operationId":"remove_peer_api_v1_agent_messages_peers_remove_post","parameters":[{"name":"agent_id","in":"query","required":true,"schema":{"type":"string","description":"Agent ID","title":"Agent Id"},"description":"Agent ID"},{"name":"peer_id","in":"query","required":true,"schema":{"type":"string","description":"Peer agent ID","title":"Peer Id"},"description":"Peer agent ID"}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","additionalProperties":true,"title":"Response Remove Peer Api V1 Agent Messages Peers Remove Post"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/agent/messages/peers/{agent_id}":{"get":{"tags":["agent-messaging"],"summary":"Get Agent Peers","description":"Get all peers for a specific agent.\n\nPhase C admin/operator-only: ``enforce`` → 401 without a principal, 403\nfor a non-admin one; ``advisory`` logs and allows; ``disabled`` is a no-op.","operationId":"get_agent_peers_api_v1_agent_messages_peers__agent_id__get","parameters":[{"name":"agent_id","in":"path","required":true,"schema":{"type":"string","title":"Agent Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","additionalProperties":true,"title":"Response Get Agent Peers Api V1 Agent Messages Peers  Agent Id  Get"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/agent/messages/peers":{"get":{"tags":["agent-messaging"],"summary":"Get All Peers","description":"Get all peer connections in the system.\n\nPhase C admin/operator-only: ``enforce`` → 401 without a principal, 403\nfor a non-admin one; ``advisory`` logs and allows; ``disabled`` is a no-op.","operationId":"get_all_peers_api_v1_agent_messages_peers_get","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"additionalProperties":true,"type":"object","title":"Response Get All Peers Api V1 Agent Messages Peers Get"}}}}}}},"/api/v1/agent/messages/{agent_id}":{"get":{"tags":["agent-messaging"],"summary":"Get Messages For Agent Compatibility","description":"Get messages for agent - AgentDaemon compatibility route.\n\nEnforce mode: only the bound principal (or an admin) may read the agent's\nmessages; advisory/disabled keep the open read.","operationId":"get_messages_for_agent_compatibility_api_v1_agent_messages__agent_id__get","parameters":[{"name":"agent_id","in":"path","required":true,"schema":{"type":"string","title":"Agent Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","additionalProperties":true,"title":"Response Get Messages For Agent Compatibility Api V1 Agent Messages  Agent Id  Get"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/agent/keys/{agent_id}":{"get":{"tags":["agent-keys"],"summary":"Get Public Key","description":"Get the registered public key for an agent.","operationId":"get_public_key_api_v1_agent_keys__agent_id__get","parameters":[{"name":"agent_id","in":"path","required":true,"schema":{"type":"string","title":"Agent Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/KeyResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/agent/keys/register":{"post":{"tags":["agent-keys"],"summary":"Register Public Key","description":"Register a public key for an agent.\n\nPhase C agent-scoped: ``enforce`` requires a principal bound to\n``req.agent_id`` (agent JWT or ``X-Agent-*`` signed headers) or an admin,\nand a non-admin principal must carry an ``identity_address`` binding — the\nregistered key is then stamped with the principal's bound identity so the\nrecord shows which wallet authorized it. ``advisory`` logs and allows;\n``disabled`` is a no-op.","operationId":"register_public_key_api_v1_agent_keys_register_post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/RegisterKeyRequest"}}},"required":true},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"additionalProperties":true,"type":"object","title":"Response Register Public Key Api V1 Agent Keys Register Post"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/ai/learning/experience":{"post":{"summary":"Record Learning Experience","description":"Record a learning experience for the AI system (Phase C\nadmin/operator-only — writes shared training state).","operationId":"record_learning_experience_v1_ai_learning_experience_post","requestBody":{"content":{"application/json":{"schema":{"additionalProperties":true,"type":"object","title":"Experience Data"}}},"required":true},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"additionalProperties":true,"type":"object","title":"Response Record Learning Experience V1 Ai Learning Experience Post"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/ai/learning/statistics":{"get":{"summary":"Get Learning Statistics","description":"Get learning system statistics (Phase C: any resolved principal).","operationId":"get_learning_statistics_v1_ai_learning_statistics_get","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"additionalProperties":true,"type":"object","title":"Response Get Learning Statistics V1 Ai Learning Statistics Get"}}}}}}},"/v1/ai/learning/predict":{"post":{"summary":"Predict Performance","description":"Predict performance for a given action (Phase C: any resolved\nprincipal).","operationId":"predict_performance_v1_ai_learning_predict_post","parameters":[{"name":"action","in":"query","required":true,"schema":{"type":"string","title":"Action"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","additionalProperties":true,"title":"Context"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","additionalProperties":true,"title":"Response Predict Performance V1 Ai Learning Predict Post"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/ai/learning/recommend":{"post":{"summary":"Recommend Action","description":"Get AI-recommended action (Phase C: any resolved principal).","operationId":"recommend_action_v1_ai_learning_recommend_post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/Body_recommend_action_v1_ai_learning_recommend_post"}}},"required":true},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"additionalProperties":true,"type":"object","title":"Response Recommend Action V1 Ai Learning Recommend Post"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/ai/neural-network/create":{"post":{"summary":"Create Neural Network","description":"Create a new neural network (Phase C admin/operator-only).","operationId":"create_neural_network_v1_ai_neural_network_create_post","requestBody":{"content":{"application/json":{"schema":{"additionalProperties":true,"type":"object","title":"Config"}}},"required":true},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"additionalProperties":true,"type":"object","title":"Response Create Neural Network V1 Ai Neural Network Create Post"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/ai/neural-network/{network_id}/train":{"post":{"summary":"Train Neural Network","description":"Train a neural network (Phase C admin/operator-only —\ncompute-heavy).","operationId":"train_neural_network_v1_ai_neural_network__network_id__train_post","parameters":[{"name":"network_id","in":"path","required":true,"schema":{"type":"string","title":"Network Id"}},{"name":"epochs","in":"query","required":false,"schema":{"type":"integer","default":100,"title":"Epochs"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"array","items":{"type":"object","additionalProperties":true},"title":"Training Data"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","additionalProperties":true,"title":"Response Train Neural Network V1 Ai Neural Network  Network Id  Train Post"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/ai/neural-network/{network_id}/predict":{"post":{"summary":"Predict With Neural Network","description":"Make prediction with neural network (Phase C: any resolved\nprincipal — read-only inference an agent may legitimately call).","operationId":"predict_with_neural_network_v1_ai_neural_network__network_id__predict_post","parameters":[{"name":"network_id","in":"path","required":true,"schema":{"type":"string","title":"Network Id"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"array","items":{"type":"number"},"title":"Features"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","additionalProperties":true,"title":"Response Predict With Neural Network V1 Ai Neural Network  Network Id  Predict Post"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/ai/ml-model/create":{"post":{"summary":"Create Ml Model","description":"Create a new ML model (Phase C admin/operator-only).","operationId":"create_ml_model_v1_ai_ml_model_create_post","requestBody":{"content":{"application/json":{"schema":{"additionalProperties":true,"type":"object","title":"Config"}}},"required":true},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"additionalProperties":true,"type":"object","title":"Response Create Ml Model V1 Ai Ml Model Create Post"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/ai/ml-model/{model_id}/train":{"post":{"summary":"Train Ml Model","description":"Train an ML model (Phase C admin/operator-only — compute-heavy).","operationId":"train_ml_model_v1_ai_ml_model__model_id__train_post","parameters":[{"name":"model_id","in":"path","required":true,"schema":{"type":"string","title":"Model Id"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"array","items":{"type":"object","additionalProperties":true},"title":"Training Data"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","additionalProperties":true,"title":"Response Train Ml Model V1 Ai Ml Model  Model Id  Train Post"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/ai/ml-model/{model_id}/predict":{"post":{"summary":"Predict With Ml Model","description":"Make prediction with ML model (Phase C: any resolved principal).","operationId":"predict_with_ml_model_v1_ai_ml_model__model_id__predict_post","parameters":[{"name":"model_id","in":"path","required":true,"schema":{"type":"string","title":"Model Id"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"array","items":{"type":"number"},"title":"Features"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","additionalProperties":true,"title":"Response Predict With Ml Model V1 Ai Ml Model  Model Id  Predict Post"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/ai/statistics":{"get":{"summary":"Get Ai Statistics","description":"Get comprehensive AI/ML statistics (Phase C: any resolved\nprincipal).","operationId":"get_ai_statistics_v1_ai_statistics_get","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"additionalProperties":true,"type":"object","title":"Response Get Ai Statistics V1 Ai Statistics Get"}}}}}}},"/v1/consensus/node/register":{"post":{"summary":"Register Consensus Node","description":"Register a node in the consensus network.\n\nPhase C admin/operator-only: consensus membership changes are\noperator-grade, same gate class as ``tasks/queues/*/clear``.","operationId":"register_consensus_node_v1_consensus_node_register_post","requestBody":{"content":{"application/json":{"schema":{"additionalProperties":true,"type":"object","title":"Node Data"}}},"required":true},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"additionalProperties":true,"type":"object","title":"Response Register Consensus Node V1 Consensus Node Register Post"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/consensus/proposal/create":{"post":{"summary":"Create Consensus Proposal","description":"Create a new consensus proposal (Phase C admin/operator-only).","operationId":"create_consensus_proposal_v1_consensus_proposal_create_post","requestBody":{"content":{"application/json":{"schema":{"additionalProperties":true,"type":"object","title":"Proposal Data"}}},"required":true},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"additionalProperties":true,"type":"object","title":"Response Create Consensus Proposal V1 Consensus Proposal Create Post"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/consensus/proposal/{proposal_id}/vote":{"post":{"summary":"Cast Consensus Vote","description":"Cast a vote for a proposal (Phase C admin/operator-only — the\ncoordinator consensus is an operator tool, not agent voting).","operationId":"cast_consensus_vote_v1_consensus_proposal__proposal_id__vote_post","parameters":[{"name":"proposal_id","in":"path","required":true,"schema":{"type":"string","title":"Proposal Id"}},{"name":"node_id","in":"query","required":true,"schema":{"type":"string","title":"Node Id"}},{"name":"vote","in":"query","required":true,"schema":{"type":"boolean","title":"Vote"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","additionalProperties":true,"title":"Response Cast Consensus Vote V1 Consensus Proposal  Proposal Id  Vote Post"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/consensus/proposal/{proposal_id}":{"get":{"summary":"Get Proposal Status","description":"Get proposal status (Phase C: any resolved principal).","operationId":"get_proposal_status_v1_consensus_proposal__proposal_id__get","parameters":[{"name":"proposal_id","in":"path","required":true,"schema":{"type":"string","title":"Proposal Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","additionalProperties":true,"title":"Response Get Proposal Status V1 Consensus Proposal  Proposal Id  Get"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/consensus/algorithm":{"put":{"summary":"Set Consensus Algorithm","description":"Set the consensus algorithm (Phase C admin/operator-only).","operationId":"set_consensus_algorithm_v1_consensus_algorithm_put","parameters":[{"name":"algorithm","in":"query","required":true,"schema":{"type":"string","description":"Consensus algorithm","title":"Algorithm"},"description":"Consensus algorithm"}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","additionalProperties":true,"title":"Response Set Consensus Algorithm V1 Consensus Algorithm Put"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/consensus/statistics":{"get":{"summary":"Get Consensus Statistics","description":"Get consensus statistics (Phase C: any resolved principal — leaks\ninternal consensus state to anonymous callers otherwise).","operationId":"get_consensus_statistics_v1_consensus_statistics_get","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"additionalProperties":true,"type":"object","title":"Response Get Consensus Statistics V1 Consensus Statistics Get"}}}}}}},"/v1/consensus/node/{node_id}/status":{"put":{"summary":"Update Node Status","description":"Update node status (Phase C admin/operator-only).","operationId":"update_node_status_v1_consensus_node__node_id__status_put","parameters":[{"name":"node_id","in":"path","required":true,"schema":{"type":"string","title":"Node Id"}},{"name":"is_active","in":"query","required":true,"schema":{"type":"boolean","title":"Is Active"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","additionalProperties":true,"title":"Response Update Node Status V1 Consensus Node  Node Id  Status Put"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/advanced-features/status":{"get":{"summary":"Get Advanced Features Status","description":"Get status of all advanced features","operationId":"get_advanced_features_status_v1_advanced_features_status_get","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"additionalProperties":true,"type":"object","title":"Response Get Advanced Features Status V1 Advanced Features Status Get"}}}}}}},"/api/v1/auth/login":{"post":{"tags":["authentication"],"summary":"Login","description":"User login with username and password","operationId":"login_api_v1_auth_login_post","requestBody":{"content":{"application/json":{"schema":{"additionalProperties":{"type":"string"},"type":"object","title":"Login Data"}}},"required":true},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"additionalProperties":true,"type":"object","title":"Response Login Api V1 Auth Login Post"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/auth/refresh":{"post":{"tags":["authentication"],"summary":"Refresh Token","description":"Refresh access token using refresh token","operationId":"refresh_token_api_v1_auth_refresh_post","requestBody":{"content":{"application/json":{"schema":{"additionalProperties":{"type":"string"},"type":"object","title":"Refresh Data"}}},"required":true},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"additionalProperties":true,"type":"object","title":"Response Refresh Token Api V1 Auth Refresh Post"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/auth/validate":{"post":{"tags":["authentication"],"summary":"Validate Token","description":"Validate JWT token","operationId":"validate_token_api_v1_auth_validate_post","requestBody":{"content":{"application/json":{"schema":{"additionalProperties":{"type":"string"},"type":"object","title":"Validate Data"}}},"required":true},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"additionalProperties":true,"type":"object","title":"Response Validate Token Api V1 Auth Validate Post"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/auth/api-key/generate":{"post":{"tags":["authentication"],"summary":"Generate Api Key","description":"Generate API key for user","operationId":"generate_api_key_api_v1_auth_api_key_generate_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"user_id","in":"query","required":true,"schema":{"type":"string","title":"User Id"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"anyOf":[{"type":"array","items":{"type":"string"}},{"type":"null"}],"title":"Permissions"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","additionalProperties":true,"title":"Response Generate Api Key Api V1 Auth Api Key Generate Post"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/auth/api-key/validate":{"post":{"tags":["authentication"],"summary":"Validate Api Key","description":"Validate API key","operationId":"validate_api_key_api_v1_auth_api_key_validate_post","parameters":[{"name":"api_key","in":"query","required":true,"schema":{"type":"string","title":"Api Key"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","additionalProperties":true,"title":"Response Validate Api Key Api V1 Auth Api Key Validate Post"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/auth/api-key/{api_key}":{"delete":{"tags":["authentication"],"summary":"Revoke Api Key","description":"Revoke API key","operationId":"revoke_api_key_api_v1_auth_api_key__api_key__delete","security":[{"HTTPBearer":[]}],"parameters":[{"name":"api_key","in":"path","required":true,"schema":{"type":"string","title":"Api Key"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","additionalProperties":true,"title":"Response Revoke Api Key Api V1 Auth Api Key  Api Key  Delete"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/agent/auth/nonce":{"post":{"tags":["agent-auth"],"summary":"Issue Login Nonce","description":"Issue a one-time 300 s nonce for the wallet-login claim.\n\nEchoes ``chain_id`` so the caller signs the same value the coordinator\nrebuilds (same convention as ``GET /v1/agents/nonce``).","operationId":"issue_login_nonce_api_v1_agent_auth_nonce_post","parameters":[{"name":"agent_id","in":"query","required":true,"schema":{"type":"string","description":"Agent ID","title":"Agent Id"},"description":"Agent ID"}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","additionalProperties":true,"title":"Response Issue Login Nonce Api V1 Agent Auth Nonce Post"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/agent/auth/login":{"post":{"tags":["agent-auth"],"summary":"Agent Login","description":"Exchange a wallet signature over the login claim for an agent JWT.\n\nChecks, in order: agent registered → agent identity-bound → claimed wallet\nequals the bound identity → signature over\n``{\"agent_id\",\"wallet_address\",\"chain_id\",\"nonce\"}`` verifies against the\nbound identity → nonce is a live one-time value. The JWT it returns carries\n``agent_id`` + ``wallet`` claims with role ``agent`` and authenticates\nHTTP endpoints (``Authorization: Bearer``) and WebSocket streams\n(``?token=``).","operationId":"agent_login_api_v1_agent_auth_login_post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/AgentLoginRequest"}}},"required":true},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"additionalProperties":true,"type":"object","title":"Response Agent Login Api V1 Agent Auth Login Post"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/agent/auth/session":{"get":{"tags":["agent-auth"],"summary":"Agent Session","description":"Return the authenticated principal — a probe for the Phase B1 credentials.","operationId":"agent_session_api_v1_agent_auth_session_get","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"additionalProperties":true,"type":"object","title":"Response Agent Session Api V1 Agent Auth Session Get"}}}}}}},"/v1/users/{user_id}/role":{"post":{"summary":"Assign User Role","description":"Assign role to user","operationId":"assign_user_role_v1_users__user_id__role_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"user_id","in":"path","required":true,"schema":{"type":"string","title":"User Id"}},{"name":"role","in":"query","required":true,"schema":{"type":"string","title":"Role"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","additionalProperties":true,"title":"Response Assign User Role V1 Users  User Id  Role Post"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"get":{"summary":"Get User Role","description":"Get user's role","operationId":"get_user_role_v1_users__user_id__role_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"user_id","in":"path","required":true,"schema":{"type":"string","title":"User Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","additionalProperties":true,"title":"Response Get User Role V1 Users  User Id  Role Get"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/users/{user_id}/permissions":{"get":{"summary":"Get User Permissions","description":"Get user's permissions","operationId":"get_user_permissions_v1_users__user_id__permissions_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"user_id","in":"path","required":true,"schema":{"type":"string","title":"User Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","additionalProperties":true,"title":"Response Get User Permissions V1 Users  User Id  Permissions Get"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/users/{user_id}/permissions/grant":{"post":{"summary":"Grant User Permission","description":"Grant custom permission to user","operationId":"grant_user_permission_v1_users__user_id__permissions_grant_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"user_id","in":"path","required":true,"schema":{"type":"string","title":"User Id"}},{"name":"permission","in":"query","required":true,"schema":{"type":"string","title":"Permission"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","additionalProperties":true,"title":"Response Grant User Permission V1 Users  User Id  Permissions Grant Post"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/users/{user_id}/permissions/{permission}":{"delete":{"summary":"Revoke User Permission","description":"Revoke custom permission from user","operationId":"revoke_user_permission_v1_users__user_id__permissions__permission__delete","security":[{"HTTPBearer":[]}],"parameters":[{"name":"user_id","in":"path","required":true,"schema":{"type":"string","title":"User Id"}},{"name":"permission","in":"path","required":true,"schema":{"type":"string","title":"Permission"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","additionalProperties":true,"title":"Response Revoke User Permission V1 Users  User Id  Permissions  Permission  Delete"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/roles":{"get":{"summary":"List All Roles","description":"List all available roles and their permissions","operationId":"list_all_roles_v1_roles_get","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"additionalProperties":true,"type":"object","title":"Response List All Roles V1 Roles Get"}}}}},"security":[{"HTTPBearer":[]}]}},"/v1/roles/{role}":{"get":{"summary":"Get Role Permissions","description":"Get all permissions for a specific role","operationId":"get_role_permissions_v1_roles__role__get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"role","in":"path","required":true,"schema":{"type":"string","title":"Role"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","additionalProperties":true,"title":"Response Get Role Permissions V1 Roles  Role  Get"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/auth/stats":{"get":{"summary":"Get Permission Stats","description":"Get statistics about permissions and users","operationId":"get_permission_stats_v1_auth_stats_get","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"additionalProperties":true,"type":"object","title":"Response Get Permission Stats V1 Auth Stats Get"}}}}},"security":[{"HTTPBearer":[]}]}},"/v1/protected/admin":{"get":{"summary":"Admin Only Endpoint","description":"Admin-only endpoint example","operationId":"admin_only_endpoint_v1_protected_admin_get","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"additionalProperties":true,"type":"object","title":"Response Admin Only Endpoint V1 Protected Admin Get"}}}}},"security":[{"HTTPBearer":[]}]}},"/v1/protected/operator":{"get":{"summary":"Operator Endpoint","description":"Operator and admin endpoint example","operationId":"operator_endpoint_v1_protected_operator_get","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"additionalProperties":true,"type":"object","title":"Response Operator Endpoint V1 Protected Operator Get"}}}}},"security":[{"HTTPBearer":[]}]}},"/v1/metrics":{"get":{"summary":"Get Prometheus Metrics","description":"Get metrics in Prometheus format","operationId":"get_prometheus_metrics_v1_metrics_get","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}}}}},"/v1/metrics/summary":{"get":{"summary":"Get Metrics Summary","description":"Get metrics summary for dashboard","operationId":"get_metrics_summary_v1_metrics_summary_get","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"additionalProperties":true,"type":"object","title":"Response Get Metrics Summary V1 Metrics Summary Get"}}}}}}},"/v1/metrics/health":{"get":{"summary":"Get Health Metrics","description":"Get health metrics for monitoring","operationId":"get_health_metrics_v1_metrics_health_get","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"additionalProperties":true,"type":"object","title":"Response Get Health Metrics V1 Metrics Health Get"}}}}}}},"/v1/system/status":{"get":{"summary":"Get System Status","description":"Get system status (protected endpoint)","operationId":"get_system_status_v1_system_status_get","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"additionalProperties":true,"type":"object","title":"Response Get System Status V1 System Status Get"}}}}},"security":[{"HTTPBearer":[]}]}},"/v1/alerts":{"get":{"summary":"Get Alerts","description":"Get alerts with optional status filter","operationId":"get_alerts_v1_alerts_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"status","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Status"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","additionalProperties":true,"title":"Response Get Alerts V1 Alerts Get"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/alerts/{alert_id}/resolve":{"post":{"summary":"Resolve Alert","description":"Resolve an alert","operationId":"resolve_alert_v1_alerts__alert_id__resolve_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"alert_id","in":"path","required":true,"schema":{"type":"string","title":"Alert Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","additionalProperties":true,"title":"Response Resolve Alert V1 Alerts  Alert Id  Resolve Post"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/alerts/stats":{"get":{"summary":"Get Alert Stats","description":"Get alert statistics","operationId":"get_alert_stats_v1_alerts_stats_get","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"additionalProperties":true,"type":"object","title":"Response Get Alert Stats V1 Alerts Stats Get"}}}}},"security":[{"HTTPBearer":[]}]}},"/v1/alerts/rules":{"get":{"summary":"Get Alert Rules","description":"Get alert rules","operationId":"get_alert_rules_v1_alerts_rules_get","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"additionalProperties":true,"type":"object","title":"Response Get Alert Rules V1 Alerts Rules Get"}}}}},"security":[{"HTTPBearer":[]}]}},"/v1/sla":{"get":{"summary":"Get Sla Status","description":"Get SLA status","operationId":"get_sla_status_v1_sla_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"sla_id","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Sla Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","additionalProperties":true,"title":"Response Get Sla Status V1 Sla Get"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/sla/{sla_id}/record":{"post":{"summary":"Record Sla Metric","description":"Record SLA metric","operationId":"record_sla_metric_v1_sla__sla_id__record_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"sla_id","in":"path","required":true,"schema":{"type":"string","title":"Sla Id"}},{"name":"value","in":"query","required":true,"schema":{"type":"number","title":"Value"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","additionalProperties":true,"title":"Response Record Sla Metric V1 Sla  Sla Id  Record Post"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/system/health":{"get":{"summary":"Get System Health","description":"Get comprehensive system status","operationId":"get_system_health_v1_system_health_get","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"additionalProperties":true,"type":"object","title":"Response Get System Health V1 System Health Get"}}}}},"security":[{"HTTPBearer":[]}]}},"/api/v1/agent/workflows":{"get":{"tags":["workflows"],"summary":"List workflows","description":"List all workflow definitions","operationId":"list_workflows_api_v1_agent_workflows_get","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"additionalProperties":true,"type":"object","title":"Response List Workflows Api V1 Agent Workflows Get"}}}}}},"post":{"tags":["workflows"],"summary":"Create workflow","description":"Create a new workflow definition","operationId":"create_workflow_api_v1_agent_workflows_post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/CreateWorkflowRequest"}}},"required":true},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/WorkflowResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/agent/workflows/{workflow_id}/execute":{"post":{"tags":["workflows"],"summary":"Execute workflow","description":"Execute a workflow","operationId":"execute_workflow_api_v1_agent_workflows__workflow_id__execute_post","parameters":[{"name":"workflow_id","in":"path","required":true,"schema":{"type":"string","title":"Workflow Id"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ExecuteWorkflowRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ExecutionResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/agent/workflows/{workflow_id}/status":{"get":{"tags":["workflows"],"summary":"Get workflow status","description":"Get workflow execution status","operationId":"get_workflow_status_api_v1_agent_workflows__workflow_id__status_get","parameters":[{"name":"workflow_id","in":"path","required":true,"schema":{"type":"string","title":"Workflow Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","additionalProperties":true,"title":"Response Get Workflow Status Api V1 Agent Workflows  Workflow Id  Status Get"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/agent/workflows/executions":{"get":{"tags":["workflows"],"summary":"List executions","description":"List workflow executions","operationId":"list_executions_api_v1_agent_workflows_executions_get","parameters":[{"name":"workflow_id","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Workflow Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","additionalProperties":true,"title":"Response List Executions Api V1 Agent Workflows Executions Get"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/agent/workflows/executions/{execution_id}/cancel":{"post":{"tags":["workflows"],"summary":"Cancel execution","description":"Cancel a workflow execution","operationId":"cancel_execution_api_v1_agent_workflows_executions__execution_id__cancel_post","parameters":[{"name":"execution_id","in":"path","required":true,"schema":{"type":"string","title":"Execution Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","additionalProperties":true,"title":"Response Cancel Execution Api V1 Agent Workflows Executions  Execution Id  Cancel Post"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/agent/ws/status":{"get":{"tags":["websocket"],"summary":"Websocket Status","description":"Get WebSocket listener status.\n\nv2.0 B1: requires any valid principal — agent JWT, signed ``X-Agent-*``\nheaders, the shared operator key (``X-Api-Key``/``?token=``/Bearer), or an\nadmin/operator JWT — in every signature mode.","operationId":"websocket_status_api_v1_agent_ws_status_get","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"additionalProperties":true,"type":"object","title":"Response Websocket Status Api V1 Agent Ws Status Get"}}}}}}},"/api/v1/agent/coin-requests/register":{"post":{"tags":["coin-requests"],"summary":"Register Coin Request","description":"Record a follower's coin request here so it can later be executed.\n\nThe hub decides the status; the caller only supplies the facts. Registering is\nidempotent on `request_id` so a retry after a lost response is safe, and a second\nregistration that contradicts the first is refused rather than allowed to overwrite\nan amount the hub has already ruled on.","operationId":"register_coin_request_api_v1_agent_coin_requests_register_post","parameters":[{"name":"x-api-key","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"X-Api-Key"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/RegisterRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","additionalProperties":true,"title":"Response Register Coin Request Api V1 Agent Coin Requests Register Post"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/agent/coin-requests/execute":{"post":{"tags":["coin-requests"],"summary":"Remote Execute Coin Request","description":"Execute an approved coin request forwarded from a follower node.\nHub-only endpoint — requires COORDINATOR_API_KEY authentication.\nSigns and submits the transaction using the genesis wallet.","operationId":"remote_execute_coin_request_api_v1_agent_coin_requests_execute_post","parameters":[{"name":"x-api-key","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"X-Api-Key"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/RemoteExecuteRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","additionalProperties":true,"title":"Response Remote Execute Coin Request Api V1 Agent Coin Requests Execute Post"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/health":{"get":{"summary":"Health Check","description":"Health check endpoint.\n\nAnonymous callers get ``{status, service, timestamp}`` only — version,\nmemory and disk detail go only to a resolved principal (any mode:\nthe credential merely has to resolve, not satisfy a scope).","operationId":"health_check_health_get","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"additionalProperties":true,"type":"object","title":"Response Health Check Health Get"}}}}}}},"/":{"get":{"summary":"Root","description":"Root endpoint with service information","operationId":"root__get","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"additionalProperties":true,"type":"object","title":"Response Root  Get"}}}}}}}},"components":{"schemas":{"AgentLoginRequest":{"properties":{"agent_id":{"type":"string","title":"Agent Id","description":"Registered, identity-bound agent ID"},"wallet_address":{"type":"string","title":"Wallet Address","description":"Wallet the signature must recover to"},"nonce":{"type":"string","title":"Nonce","description":"One-time nonce from POST /api/v1/agent/auth/nonce"},"signature":{"type":"string","title":"Signature","description":"0x-prefixed secp256k1 signature over the login claim"},"chain_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Chain Id","description":"Chain ID covered by the claim (default: coordinator's)"}},"type":"object","required":["agent_id","wallet_address","nonce","signature"],"title":"AgentLoginRequest","description":"Wallet-login body: the signature covers the canonical login claim."},"AgentRegistrationRequest":{"properties":{"agent_id":{"type":"string","title":"Agent Id","description":"Unique agent identifier"},"agent_type":{"type":"string","title":"Agent Type","description":"Type of agent"},"capabilities":{"items":{"type":"string"},"type":"array","title":"Capabilities","description":"Agent capabilities"},"services":{"items":{"type":"string"},"type":"array","title":"Services","description":"Available services"},"endpoints":{"additionalProperties":{"type":"string"},"type":"object","title":"Endpoints","description":"Service endpoints"},"metadata":{"additionalProperties":true,"type":"object","title":"Metadata","description":"Additional metadata"},"chain_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Chain Id","description":"Chain ID this agent operates on"},"island_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Island Id","description":"Island ID this agent is on"},"identity_address":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Identity Address","description":"secp256k1 identity/payout address to bind to agent_id"},"identity_proof":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Identity Proof","description":"Signature by identity_address over the registration claim"},"identity_nonce":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Identity Nonce","description":"One-time nonce from GET /v1/agents/nonce"},"registered_at":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Registered At","description":"Client ISO timestamp covered by identity_proof"}},"type":"object","required":["agent_id","agent_type"],"title":"AgentRegistrationRequest"},"AgentStatusUpdate":{"properties":{"status":{"type":"string","title":"Status","description":"Agent status"},"load_metrics":{"additionalProperties":{"type":"number"},"type":"object","title":"Load Metrics","description":"Load metrics"}},"type":"object","required":["status"],"title":"AgentStatusUpdate"},"Body_recommend_action_v1_ai_learning_recommend_post":{"properties":{"context":{"additionalProperties":true,"type":"object","title":"Context"},"available_actions":{"items":{"type":"string"},"type":"array","title":"Available Actions"}},"type":"object","required":["context","available_actions"],"title":"Body_recommend_action_v1_ai_learning_recommend_post"},"BroadcastRequest":{"properties":{"message_type":{"type":"string","title":"Message Type","description":"Message type"},"payload":{"additionalProperties":true,"type":"object","title":"Payload","description":"Message payload"},"priority":{"type":"string","title":"Priority","description":"Message priority","default":"normal"},"agent_type":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Agent Type","description":"Filter by agent type"},"capabilities":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Capabilities","description":"Filter by capabilities"}},"type":"object","required":["message_type","payload"],"title":"BroadcastRequest"},"CreateWorkflowRequest":{"properties":{"name":{"type":"string","title":"Name","description":"Workflow name"},"description":{"type":"string","title":"Description","description":"Workflow description","default":""},"steps":{"items":{"additionalProperties":true,"type":"object"},"type":"array","title":"Steps","description":"Workflow steps"},"created_by":{"type":"string","title":"Created By","description":"Creator identifier","default":""},"chain_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Chain Id","description":"Chain ID for workflow execution"}},"type":"object","required":["name","steps"],"title":"CreateWorkflowRequest","description":"Request to create a workflow"},"ExecuteWorkflowRequest":{"properties":{"input_parameters":{"additionalProperties":true,"type":"object","title":"Input Parameters","description":"Input parameters for workflow"},"chain_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Chain Id","description":"Chain ID to execute on"}},"type":"object","title":"ExecuteWorkflowRequest","description":"Request to execute a workflow"},"ExecutionResponse":{"properties":{"execution_id":{"type":"string","title":"Execution Id"},"workflow_id":{"type":"string","title":"Workflow Id"},"status":{"type":"string","title":"Status"},"current_step_index":{"type":"integer","title":"Current Step Index"},"results":{"additionalProperties":true,"type":"object","title":"Results"},"error":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Error"},"started_at":{"type":"string","title":"Started At"},"completed_at":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Completed At"},"steps":{"items":{"additionalProperties":true,"type":"object"},"type":"array","title":"Steps"}},"type":"object","required":["execution_id","workflow_id","status","current_step_index","results","error","started_at","completed_at","steps"],"title":"ExecutionResponse","description":"Workflow execution response"},"HTTPValidationError":{"properties":{"detail":{"items":{"$ref":"#/components/schemas/ValidationError"},"type":"array","title":"Detail"}},"type":"object","title":"HTTPValidationError"},"IdentityRotationRequest":{"properties":{"new_address":{"type":"string","title":"New Address","description":"New secp256k1 identity/payout address"},"new_proof":{"type":"string","title":"New Proof","description":"Signature by new_address over the registration claim"},"rotation_proof":{"type":"string","title":"Rotation Proof","description":"Signature by the currently bound key over the rotation claim"},"identity_nonce":{"type":"string","title":"Identity Nonce","description":"One-time nonce from GET /v1/agents/nonce covered by new_proof"},"registered_at":{"type":"string","title":"Registered At","description":"Client ISO timestamp covered by new_proof"},"rotation_timestamp":{"type":"string","title":"Rotation Timestamp","description":"Client ISO timestamp covered by rotation_proof"},"chain_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Chain Id","description":"Chain ID covered by new_proof"}},"type":"object","required":["new_address","new_proof","rotation_proof","identity_nonce","registered_at","rotation_timestamp"],"title":"IdentityRotationRequest","description":"Dual-proof identity rotation for ``PUT /v1/agents/{agent_id}/identity`` (doc §7).\n\n``new_proof`` is the new key's signature over the same registration claim\nshape used at registration (fresh one-time ``identity_nonce`` included).\n``rotation_proof`` is the *currently bound* key's signature over\n``{\"agent_id\",\"old_address\",\"new_address\",\"timestamp\"}``."},"KeyResponse":{"properties":{"agent_id":{"type":"string","title":"Agent Id"},"public_key":{"type":"string","title":"Public Key"},"key_id":{"type":"string","title":"Key Id"},"created_at":{"type":"string","title":"Created At"}},"type":"object","required":["agent_id","public_key","key_id","created_at"],"title":"KeyResponse","description":"Response containing a public key."},"RegisterKeyRequest":{"properties":{"agent_id":{"type":"string","title":"Agent Id","description":"Agent ID that owns the key"},"public_key":{"type":"string","title":"Public Key","description":"PEM-encoded public key (base64)"},"key_id":{"type":"string","title":"Key Id","description":"Optional key identifier","default":""}},"type":"object","required":["agent_id","public_key"],"title":"RegisterKeyRequest","description":"Request to register a public key for an agent."},"RegisterRequest":{"properties":{"request_id":{"type":"string","title":"Request Id"},"sender":{"type":"string","title":"Sender"},"amount":{"type":"integer","title":"Amount"},"wallet_address":{"type":"string","title":"Wallet Address"},"recipient":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Recipient"}},"type":"object","required":["request_id","sender","amount","wallet_address"],"title":"RegisterRequest","description":"A coin request raised on a follower island, presented to the hub for a decision."},"RemoteExecuteRequest":{"properties":{"request_id":{"type":"string","title":"Request Id"},"sender":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Sender"},"amount":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Amount"},"wallet_address":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Wallet Address"},"approved_by":{"type":"string","title":"Approved By","default":"cli"}},"type":"object","required":["request_id"],"title":"RemoteExecuteRequest","description":"Request to execute an approved coin request forwarded from a follower node.\n\nOnly ``request_id`` is used. The other fields are accepted for wire compatibility\nwith deployed CLIs and logged when they disagree with the stored request, but they\ndo not influence the payment — see the module docstring."},"SendMessageRequest":{"properties":{"sender":{"type":"string","title":"Sender","description":"Sender agent ID"},"recipient":{"type":"string","title":"Recipient","description":"Recipient agent ID"},"content":{"additionalProperties":true,"type":"object","title":"Content","description":"Message content"},"message_type":{"type":"string","title":"Message Type","description":"Message type","default":"direct"},"encrypt":{"type":"boolean","title":"Encrypt","description":"Whether to encrypt message","default":true},"priority":{"type":"string","title":"Priority","description":"Message priority","default":"normal"},"ttl":{"type":"integer","title":"Ttl","description":"Time to live in seconds","default":300},"message_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Message Id","description":"Client-provided message ID for idempotency"},"signer":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Signer","description":"secp256k1 address that signed the envelope"},"signature":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Signature","description":"0x-prefixed signature over signing_payload()"},"signature_version":{"type":"string","title":"Signature Version","description":"Envelope signature scheme","default":"aitbc-agent-msg-v1"},"timestamp":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Timestamp","description":"Client ISO-8601 timestamp covered by the signature"},"nonce":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Nonce","description":"Client nonce for (sender, nonce) replay dedup"}},"type":"object","required":["sender","recipient","content"],"title":"SendMessageRequest","description":"Request to send encrypted message"},"SubscribeRequest":{"properties":{"agent_id":{"type":"string","title":"Agent Id","description":"Agent ID"},"topic":{"type":"string","title":"Topic","description":"Topic to subscribe to"},"filter":{"additionalProperties":true,"type":"object","title":"Filter","description":"Filter criteria"}},"type":"object","required":["agent_id","topic"],"title":"SubscribeRequest","description":"Request to subscribe to topic"},"TaskPayment":{"properties":{"amount":{"type":"integer","title":"Amount","description":"Payment amount in smallest units"},"fee":{"type":"integer","title":"Fee","description":"Transaction fee","default":0},"requester":{"type":"string","title":"Requester","description":"Requester address (pays for task)"},"agent":{"type":"string","title":"Agent","description":"Agent address (receives payment)"},"timeout_seconds":{"type":"number","title":"Timeout Seconds","description":"Escrow timeout","default":3600.0},"lock_tx":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Lock Tx","description":"Buyer-signed ESCROW_LOCK transaction"},"lock_signature":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Lock Signature","description":"Signature over lock_tx"},"auto_reinvest_pct":{"anyOf":[{"type":"number","maximum":100.0,"minimum":0.0},{"type":"null"}],"title":"Auto Reinvest Pct","description":"Percentage of released payment to auto-stake as reinvestment"}},"type":"object","required":["amount","requester","agent"],"title":"TaskPayment","description":"Payment details for task execution escrow (v0.6.5).\n\n``lock_tx``/``lock_signature`` carry the buyer-signed ESCROW_LOCK\ntransaction (same shape ``market escrow`` submits to /rpc/escrow/create).\nWhen present, the coordinator locks the escrow on-chain; when absent the\nescrow is bookkeeping-only (no chain transaction)."},"TaskSubmission":{"properties":{"task_data":{"additionalProperties":true,"type":"object","title":"Task Data","description":"Task data"},"priority":{"type":"string","title":"Priority","description":"Task priority","default":"normal"},"requirements":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Requirements","description":"Task requirements"},"chain_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Chain Id","description":"Chain ID to execute task on"},"payment":{"anyOf":[{"$ref":"#/components/schemas/TaskPayment"},{"type":"null"}],"description":"Payment for task execution escrow"}},"type":"object","required":["task_data"],"title":"TaskSubmission"},"ValidationError":{"properties":{"loc":{"items":{"anyOf":[{"type":"string"},{"type":"integer"}]},"type":"array","title":"Location"},"msg":{"type":"string","title":"Message"},"type":{"type":"string","title":"Error Type"},"input":{"title":"Input"},"ctx":{"type":"object","title":"Context"}},"type":"object","required":["loc","msg","type"],"title":"ValidationError"},"WorkflowResponse":{"properties":{"workflow_id":{"type":"string","title":"Workflow Id"},"name":{"type":"string","title":"Name"},"description":{"type":"string","title":"Description"},"steps":{"items":{"additionalProperties":true,"type":"object"},"type":"array","title":"Steps"},"created_at":{"type":"string","title":"Created At"},"created_by":{"type":"string","title":"Created By"}},"type":"object","required":["workflow_id","name","description","steps","created_at","created_by"],"title":"WorkflowResponse","description":"Workflow response"}},"securitySchemes":{"HTTPBearer":{"type":"http","scheme":"bearer"}}}}