Send a diagnostic ping to a registered agent
POST /api/agent-communication/test/ping-agent/{agent_id}
Send a diagnostic ping to an agent and measure queue-append latency.
Uses :meth:AgentCommunicationHub.ping_agent, which bypasses permission
checks (diagnostic traffic is infrastructure, not an authorized
agent-to-agent conversation) and routes through the hub-owned
"hub_diagnostic" sender identity so agent processing loops filter it
out of get_messages before spending LLM cycles on it.
Path Parameters:
agent_id: Target agent identifier. Must be registered with the hub.
Query Parameters:
test_message: Optional custom ping content.
Returns:
- :class:
PingAgentResponsewithping_successfulTrue and non-zeroresponse_time_mson success.
Raises:
HTTPException 404: Target agent is not registered with the hub.HTTPException 503: Communication hub unavailable.HTTPException 500: Unexpected hub error during the ping.
Parameters
Section titled “ Parameters ”Path Parameters
Section titled “Path Parameters ”Query Parameters
Section titled “Query Parameters ”Responses
Section titled “ Responses ”Successful Response
Ping agent response model.
Provides connectivity and health check response for agent ping operations including response time and success status. Used for agent connectivity testing and health monitoring endpoints.
Fields:
status: Operation status (success/error)ping_successful: Boolean indicating successful ping responseagent_id: Identifier of the pinged agentresponse_time_ms: Response time in milliseconds (non-negative float)message: Response message providing additional context
Usage: POST /api/agent-communication/ping-agent returns this response model.
JSON Example:
{
"status": "success",
"pingSuccessful": true,
"agentId": "hawken",
"responseTimeMs": 45.2,
"message": "Agent is responsive"
}object
Operation status
Ping success status
Pinged agent ID
Response time in ms
Response message
Validation Error