Skip to main content

respawn_agent

Function respawn_agent 

Source
pub async fn respawn_agent(
    __arg0: State<AppState>,
    __arg1: Path<String>,
) -> Result<Json<RespawnedResponse>, ApiError>
Expand description

POST /api/agents/{id}/respawn — replace an agent with a fresh one.

Returns the new agent id. The old id is retired from caliban’s registry, so once the next poll reconciles it disappears from both GET /api/fleet and GET /api/agents/{id} (they share the live snapshot). Its history is not destroyed: GET /api/agents/{old_id}/events still replays the retired agent’s immutable event stream from the durable store (#124).