API reference for user management, log viewing, master data management, and shared memory search. For end-user-facing APIs (Chat / Conversations / Files / Search / public master data), see the User API Reference. For MCP / A2A connection methods, see the Connection Methods Guide.
SaaS Edition Only
All endpoints documented in this reference are available only in the SaaS edition. On the Marketplace edition, administrative operations are performed exclusively through the Admin Console; no Admin APIs are exposed.
All API requests require a Bearer token in the Authorization header.
Authorization: Bearer <access_token>
If the token is invalid or missing, 401 Unauthorized is returned. Some endpoints require additional scopes. If the required scope is missing, 403 Forbidden is returned.
Endpoints supporting page-based pagination: users list, audit logs list, LLM logs list, LLM Gateway logs list, access logs list, and guardrail alerts list. Organization and job type lists do not support pagination and always return all records.
{ "memories":[ { "text":"Sales reports can be created from the 'Monthly Reports' tab in the dashboard", "type":"knowledge", "scope":"organization", "createdAt":"2026-03-15T10:30:00.000Z", "score":0.85 } ] }
Communication error with an upstream service (error.type: upstream_error)
504
Upstream service response timeout (error.type: upstream_error, error.code: upstream_timeout)
When the search succeeds with no matches, 200 is returned with an empty memories array. Upstream failures return 502 / 504 instead of an empty array, so an empty array in a 200 response does not indicate a failure.
Number of tool calls — not a list of tool names, and not a count of distinct tools (calling the same tool 5 times gives 5). null means not measured; 0 means the run was measured and made no tool call. The two are distinct — do not treat 0 as null.
llmLogs[].success
boolean | null
Success/failure
llmLogs[].agentType
string | null
Agent type
llmLogs[].agentLevel
string | null
Agent level
llmLogs[].taskComplexity
string | null
Task complexity
llmLogs[].currentMessage
string | null
Current message
llmLogs[].contextSummary
string | null
Context summary
llmLogs[].suggestedApproach
string | null
Suggested approach
llmLogs[].conversationGoal
string | null
Conversation goal
llmLogs[].finalContent
string | null
Final output content
llmLogs[].metadata
object | null
Supplementary metadata that varies by operation (keys vary)
{ "llmLogs":[ { "llmLogId":"33098", "timestamp":"2026-04-19T04:12:51.102Z", "service":"agent-executor", "operation":"agent.intent.completed", "durationMs":5574.6, "conversationId":"3b72544d-d6b5-4577-b5f3-c39293124a57", "intentType":"complex_task", "confidenceScore":0.95, "toolsUsed":null, "success":null, "agentType":"intent", "agentLevel":"default", "taskComplexity":null, "currentMessage":"Tell me about this URL https://example.com/path", "contextSummary":"User is asking about a URL.", "suggestedApproach":"execute_single_tool", "conversationGoal":"Information about the contents or purpose of the specified URL", "finalContent":null, "metadata":{ "message.id":"02038f42-154b-4363-9beb-d31512934ec5", "task.complexity":"moderate", "detected_language":"en", "requires_planning":true }, "createdAt":"2026-04-18T19:16:16.964Z" }, { "llmLogId":"33097", "timestamp":"2026-04-19T04:12:48.730Z", "service":"agent-executor", "operation":"agent.guardrail.completed", "durationMs":3170.34, "conversationId":"3b72544d-d6b5-4577-b5f3-c39293124a57", "intentType":null, "confidenceScore":null, "toolsUsed":null, "success":null, "agentType":"intent.guardrails", "agentLevel":null, "taskComplexity":null, "currentMessage":null, "contextSummary":null, "suggestedApproach":null, "conversationGoal":null, "finalContent":null, "metadata":{"guardrail_detected":false}, "createdAt":"2026-04-18T19:16:14.619Z" }, { "llmLogId":"33096", "timestamp":"2026-04-19T04:12:33.662Z", "service":"agent-executor", "operation":"agent.intent.completed", "durationMs":4213.47, "conversationId":"4d7c798d-2e3e-4d40-86ab-cbb6c685a3fb", "intentType":"conversation", "confidenceScore":1, "toolsUsed":null, "success":null, "agentType":"intent", "agentLevel":"default", "taskComplexity":null, "currentMessage":"Hello", "contextSummary":"New conversation. User is greeting.", "suggestedApproach":"conversational_response", "conversationGoal":"Greeting exchange with the AI assistant", "finalContent":null, "metadata":{ "message.id":"cea9dbcc-4723-452a-bdcd-aa5f3a0e9ca6", "task.complexity":"simple", "detected_language":"en", "requires_planning":false }, "createdAt":"2026-04-18T19:15:59.681Z" } ], "total":33098, "limit":3, "page":1, "hasMore":true }
GET/v1/admin/llm-gateway-logs
List LLM Gateway logs. Returned in descending order of creation time. One request = one row, recording usage such as model, provider, tokens, cost, and latency.
{ "accessLogs":[ { "timestamp":"2026-04-19T05:17:36.735896", "sourceNamespace":"autonomous-agent", "sourceIp":"127.0.0.1", "method":"CONNECT", "host":"optimizationguide-pa.googleapis.com:443", "path":"", "userAgent":"Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/147.0.0.0 Safari/537.36", "statusCode":200, "durationMs":1, "authzResult":"allowed", "authzReason":"allowed: All allow" }, { "timestamp":"2026-04-19T03:50:36.766451", "sourceNamespace":"autonomous-agent", "sourceIp":"127.0.0.1", "method":"CONNECT", "host":"update.googleapis.com:443", "path":"", "userAgent":"Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/147.0.0.0 Safari/537.36", "statusCode":200, "durationMs":6, "authzResult":"allowed", "authzReason":"allowed: All allow" }, { "timestamp":"2026-04-19T03:45:48.481023", "sourceNamespace":"autonomous-agent", "sourceIp":"127.0.0.1", "method":"CONNECT", "host":"optimizationguide-pa.googleapis.com:443", "path":"", "userAgent":"Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/147.0.0.0 Safari/537.36", "statusCode":200, "durationMs":0, "authzResult":"allowed", "authzReason":"allowed: All allow" } ], "total":57806, "limit":3, "page":1, "hasMore":true }
GET/v1/admin/guardrail-alerts
Lists guardrail alerts. Results are returned in descending order of detection time.
These are records where Prompt Shield (prompt injection and jailbreak attempts) or Text Moderation (harmful content) detected a violation and execution was stopped. The detection surface (sourceSurface) is either AI agent execution (agent_executor) or the LLM Gateway (llm_gateway).
Where Prompt Shield detected the attack. Contains user_prompt (the user input) and document_indexes (positions in attached documents). Document contents are not included
guardrailAlerts[].moderationCategories
object | null
Severity per category. Hate / Sexual / SelfHarm / Violence on a four-level scale of 0, 2, 4, and 6
guardrailAlerts[].moderationThreshold
integer | null
Threshold used for the decision
guardrailAlerts[].policyOutcome
string
Policy outcome. Currently only blocked (execution stopped)
guardrailAlerts[].responseTemplateCode
string | null
Code of the canned response returned to the user
guardrailAlerts[].status
string
Triage status (open: not yet handled / escalated: escalated / closed: resolved / false_positive: false detection)
guardrailAlerts[].resolutionCode
string | null
Resolution code
guardrailAlerts[].resolvedAt
string | null
Resolution time (ISO 8601 format)
guardrailAlerts[].resolvedBy
string | null
User ID of the administrator who resolved the alert
guardrailAlerts[].createdAt
string
Creation time (ISO 8601 format)
guardrailAlerts[].updatedAt
string
Update time (ISO 8601 format)
total
integer
Total number of records
limit
integer
Number of items fetched
page
integer
Page number
hasMore
boolean
Whether a next page exists
About the users who triggered detections
This API does not return information that identifies the user who triggered a detection (user ID, conversation ID, or message ID). It is intended for reviewing guardrail quality and tracking the status of safety responses, and cannot be used to trace the behavior of individual users.
In addition, detections of SelfHarm alone are not recorded as alerts.
CRUD operations for organizations and job types. Unlike the read-only master data endpoints (/v1/organizations, /v1/job-types), creation, updates, and deletion require master:manage scope.
List job types. Fetches all records (no pagination). Response fields have the same structure as the organizations list (organizations → jobTypes, organization code → job type code).
All error responses are returned with the following common structure.
Field
Type
Description
error.type
string
Error category. One of "invalid_request_error", "authentication_error", "insufficient_scope_error", "forbidden_error", "not_found_error", "conflict_error", "rate_limit_error", "server_error", or "upstream_error"
The parameter name that caused the error. Included only for validation errors
error.suggested_action
string
Recommended action to resolve the error. Included only for some errors
JSON
{ "error":{ "type":"invalid_request_error", "message":"Invalid parameter: limit", "code":"invalid_parameter", "param":"limit", "suggested_action":"limit must be between 1 and 100" } }
Automatically Recorded Management Operations SaaS
The following management operations automatically generate an audit log entry.