Fetches execution logs for a session via the workspace Orchestration Engine. The project scope is carried by the route id path parameter and the org is derived from that project.
Query parameters
-
Session ID
-
RFC3339 timestamp filter
-
Opaque cursor returned as next_cursor by the previous response
-
Workspace ID for workspace resolution
Responses
-
Unsupported or malformed API version, an operation unavailable in the selected published contract, or an unacceptable representation (including unsupported media-type parameters or excluded SSE). Existing authentication, authorization, and rate-limit failures take precedence.
-
OK
-
Bad Request
-
Unauthorized
-
Workspace orchestration engine is not ready
-
Internal Server Error
-
Bad Gateway
GET
/api/v1/projects/{id}/execution-logs
curl \
--request GET 'https://agentengine.mongodb.com/api/v1/projects/{id}/execution-logs?session_id=string' \
--header "Authorization: $API_KEY"
Response examples (406)
Operation unavailable
{
"detail": "This operation is not available in API version 2026-09-20-preview.",
"error": 406,
"errorCode": "OPERATION_NOT_IN_API_VERSION",
"parameters": [
"Accept"
],
"reason": "Not Acceptable"
}
{
"detail": "This operation supports text/event-stream, which the Accept header excludes. Remove unsupported media-type parameters or accept this type with a positive q value.",
"error": 406,
"errorCode": "UNACCEPTABLE_MEDIA_TYPE",
"parameters": [
"Accept"
],
"reason": "Not Acceptable"
}
{
"detail": "The requested API version is not supported. Supported versions: 2026-09-20-preview.",
"error": 406,
"errorCode": "UNSUPPORTED_API_VERSION",
"parameters": [
"Accept"
],
"reason": "Not Acceptable"
}
Response examples (406)
{
"detail": "This operation is not available in API version 2026-09-20-preview.",
"error": 406,
"errorCode": "OPERATION_NOT_IN_API_VERSION",
"parameters": [
"Accept"
],
"reason": "Not Acceptable"
}
Response examples (200)
{
"count": 42,
"has_more": true,
"logs": [
{
"a2a_caller_workspace_id": "string",
"a2a_parent_execution_id": "string",
"a2a_target_agent_id": "string",
"a2a_target_agent_name": "string",
"completion_tokens": 42,
"cost_usd": 42.0,
"decision": "string",
"duration_ms": 42.0,
"error": "string",
"execution_id": "string",
"guardrail_action": "string",
"guardrail_name": "string",
"guardrail_type": "string",
"id": "string",
"inputs": {},
"kind": "llm",
"log_source": "string",
"metadata": {},
"model": "string",
"org_id": "string",
"pod_name": "string",
"project_id": "string",
"prompt_tokens": 42,
"root_execution_id": "string",
"root_session_id": "string",
"session_id": "string",
"span_id": "string",
"status": "string",
"step_number": 42,
"timestamp": "2026-05-04T09:42:00Z",
"tool": "string",
"tool_api_error": {
"classification": "string",
"error_code": "string",
"http_status": 42,
"provider_type": "string",
"reason": "string",
"retryable": true
},
"tool_call_id": "string",
"total_tokens": 42,
"trace_id": "string",
"triggered_policy_ids": [
"string"
],
"user_id": "string",
"workspace_id": "string"
}
],
"next_cursor": "string",
"success": true
}
Response examples (200)
{
"count": 42,
"has_more": true,
"logs": [
{
"a2a_caller_workspace_id": "string",
"a2a_parent_execution_id": "string",
"a2a_target_agent_id": "string",
"a2a_target_agent_name": "string",
"completion_tokens": 42,
"cost_usd": 42.0,
"decision": "string",
"duration_ms": 42.0,
"error": "string",
"execution_id": "string",
"guardrail_action": "string",
"guardrail_name": "string",
"guardrail_type": "string",
"id": "string",
"inputs": {},
"kind": "llm",
"log_source": "string",
"metadata": {},
"model": "string",
"org_id": "string",
"pod_name": "string",
"project_id": "string",
"prompt_tokens": 42,
"root_execution_id": "string",
"root_session_id": "string",
"session_id": "string",
"span_id": "string",
"status": "string",
"step_number": 42,
"timestamp": "2026-05-04T09:42:00Z",
"tool": "string",
"tool_api_error": {
"classification": "string",
"error_code": "string",
"http_status": 42,
"provider_type": "string",
"reason": "string",
"retryable": true
},
"tool_call_id": "string",
"total_tokens": 42,
"trace_id": "string",
"triggered_policy_ids": [
"string"
],
"user_id": "string",
"workspace_id": "string"
}
],
"next_cursor": "string",
"success": true
}
Response examples (400)
{
"code": "string",
"error": "string",
"success": true
}
Response examples (400)
{
"code": "string",
"error": "string",
"success": true
}
Response examples (401)
{
"code": "string",
"error": "string",
"success": true
}
Response examples (401)
{
"code": "string",
"error": "string",
"success": true
}
Response examples (425)
{
"code": "string",
"error": "string",
"success": true
}
Response examples (425)
{
"code": "string",
"error": "string",
"success": true
}
Response examples (500)
{
"code": "string",
"error": "string",
"success": true
}
Response examples (500)
{
"code": "string",
"error": "string",
"success": true
}
Response examples (502)
{
"code": "string",
"error": "string",
"success": true
}
Response examples (502)
{
"code": "string",
"error": "string",
"success": true
}