Skip to main content

API Reference

This reference documents all 426 HTTP endpoints exposed by the Open ACE backend, grouped by path family. Paths are the full externally visible routes, with blueprint URL prefixes already folded in. Route parameters use Flask syntax (<int:user_id>, <path:filename>, ...).

Base URL and authentication​

Base URL. The server listens on port 19888 by default, so the API root is http://<host>:19888/api. All business routes live under the /api prefix; health probes and SPA routes live at the application root.

Session token (primary authentication). Most endpoints authenticate the current user via the session token, provided either as:

  • the session_token cookie (set by POST /api/auth/login), or
  • the Authorization: Bearer <token> header.

API keys and service tokens. A few route groups use dedicated credentials instead of (or on top of) the session token:

  • POST /api/upload/* requires the X-Upload-Auth header carrying the UPLOAD_AUTH_KEY value; the endpoints return 503 when the key is not configured and 401 when it does not match.
  • Remote agents authenticate with machine registration/agent tokens (/api/remote/agent/*, /api/remote/usage-report); see ../guide/REMOTE_AGENT.md.
  • GET /api/quota/webui-check accepts the webui token used by the webui backend middleware.
  • The /api/api-keys family manages provider API keys stored encrypted in the database and consumed by the LLM proxy endpoints — they are not Open ACE login credentials.

Roles. Elevated endpoints require admin-level roles (admin, platform_admin, tenant_admin). The authoritative per-endpoint listing is API_PERMISSION_MATRIX.md; the role model is described in PERMISSION_MODEL.md.

Auth column legend. The Auth column reproduces the route's permission decorators verbatim from the source; - means no permission decorator:

DecoratorMeaning
public_endpointExplicitly public; no authentication required.
require_upload_authUpload collector endpoints guarded by the X-Auth-Key header instead of a session.
-No permission decorator declared; the handler may still resolve the session or use dedicated credentials (upload key, agent token).
auth_requiredValid session required.
admin_requiredAdmin role required (legacy platform-level admin).
platform_admin_requiredPlatform admin role required.
api_key_admin_requiredTenant/platform admin authorized for API-key management.
any_admin_requiredAny admin role (platform, tenant or legacy admin).
tenant_member_requiredTenant member required.
same_tenant_user_requiredTarget user must belong to the caller's tenant (stacked with admin_required).
same_tenant_or_platform_adminSame-tenant admin or platform admin.
machine_access_requiredSystem admin or user assigned to the machine.
machine_admin_requiredSystem admin or machine admin.

Global conventions​

  • Content type. Requests and responses are JSON (application/json) except for file upload/download, script downloads, SSE/WebSocket streams and the XML/HTML SSO metadata/ACS endpoints.
  • Errors. Failures return a JSON body of the form {"error": "<message>"} with the usual status codes: 400 bad input, 401 unauthenticated, 403 insufficient role, 404 not found, 500 internal error.
  • Pagination. List endpoints paginate with limit/offset query parameters (typical defaults 50–100). GET /api/workspace/sessions/<session_id>/messages instead uses composite-key keyset pagination.
  • Realtime. SSE and WebSocket endpoints are flagged inline in the Description column (e.g. the alert stream, autonomous workflow event stream, remote session stream, and the terminal/VS Code/agent WebSocket routes).
  • Row granularity. One row per registered route; a few multi-method aliases share a row, so the row count can differ from a method-level count.
  • Paths. Paths are written as registered. Most have no trailing slash; a few catch-all proxy routes keep a trailing-slash base form (Flask's strict-slashes behavior).

Endpoint families​

FamilyPrefixEndpoints
Remote machines and sessions/api/remote56
Workspace/api/workspace46
Autonomous development/api/autonomous25
Single sign-on/api/sso20
Integration and notification management/api/management18
User and organization administration/api/admin18
Tenants/api/tenants19
Compliance/api/compliance17
Tool accounts/api/tool-accounts14
Analysis/api/analysis16
Alerts/api/alerts14
Projects/api/projects12
Quota/api/quota9
Mapping rules/api/mapping-rules8
Local file system/api/fs8
Encryption keys/api/api/encryption-keys8
Return on investment/api/roi7
Request statistics/api/request6
Authentication and account/api/auth6
External identity integration/api/integrations/external2
Other endpoints—87
Operational endpoints—10
Total426

Remote machines and sessions (/api/remote)​

Register and manage remote machines, drive remote AI sessions, web terminals and VS Code (code-server) instances, and speak the remote-agent protocol (registration, messaging, LLM proxy, usage reporting).

MethodPathAuthDescription
GET/api/remote/agent/files/<path:filename>-Serve agent source files for download during installation.
GET/api/remote/agent/install.ps1-Serve the agent installation PowerShell script (Windows).
GET/api/remote/agent/install.sh-Serve the agent installation shell script (Linux/macOS).
POST/api/remote/agent/message-HTTP fallback for agent communication when WebSocket is not available.
POST/api/remote/agent/register-Register a remote agent using a registration token.
GET/api/remote/agent/uninstall.ps1-Serve the agent uninstallation PowerShell script (Windows).
GET/api/remote/agent/uninstall.sh-Serve the agent uninstallation shell script (Linux/macOS).
GET/api/remote/agent/ws-Deprecated WebSocket channel for agent communication (WebSocket); use HTTP polling via /api/remote/agent/message instead.
GET/api/remote/heartbeat-statusadmin_requiredGet heartbeat monitor status for diagnostics.
POST/HEAD/api/remote/llm-proxy-Transparent LLM API proxy for remote workspaces (empty path); forwards provider requests using stored encrypted API keys.
GET/POST/PUT/DELETE/HEAD/api/remote/llm-proxy/<path:path>-Transparent LLM API proxy — catch-all path form.
GET/api/remote/machines-List machines with tenant isolation.
DELETE/api/remote/machines/<machine_id>admin_requiredDeregister a remote machine. Admin only.
GET/api/remote/machines/<machine_id>machine_access_requiredGet details and status of a specific machine.
POST/api/remote/machines/<machine_id>/assignmachine_admin_requiredAssign a user to a machine. System admin or machine admin.
DELETE/api/remote/machines/<machine_id>/assign/<int:user_id>machine_admin_requiredRevoke a user's access to a machine. System admin or machine admin.
GET/api/remote/machines/<machine_id>/browsemachine_access_requiredBrowse the file system on a remote machine.
GET/api/remote/machines/<machine_id>/commandsmachine_access_requiredGet operational commands for a specific machine.
POST/api/remote/machines/<machine_id>/create-directory-Create a directory on a remote machine.
GET/api/remote/machines/<machine_id>/git/diff-Get git diff for a specific file on a remote machine.
GET/api/remote/machines/<machine_id>/git/file-Read a file from a remote machine.
GET/api/remote/machines/<machine_id>/git/status-Get git status on a remote machine.
GET/api/remote/machines/<machine_id>/sessionsmachine_admin_requiredGet list of active sessions on a machine. System admin or machine admin.
POST/api/remote/machines/<machine_id>/token/revokeadmin_requiredRevoke all agent tokens for a machine. System admin only.
POST/api/remote/machines/<machine_id>/token/rotateadmin_requiredRotate the agent token for a machine. System admin only.
GET/api/remote/machines/<machine_id>/usersmachine_admin_requiredGet list of users assigned to a machine. System admin or machine admin.
GET/api/remote/machines/available-Get machines available to the current user.
POST/api/remote/machines/registeradmin_requiredGenerate a registration token for a new machine.
POST/api/remote/sessionsmachine_access_requiredCreate a new remote session on a selected machine.
GET/api/remote/sessions/<session_id>-Get remote session status and output.
POST/api/remote/sessions/<session_id>/abort-Abort the current in-progress request without stopping the session.
GET/api/remote/sessions/<session_id>/approvals-Return the durable approval records for a remote session.
POST/api/remote/sessions/<session_id>/chat-Send a message to a remote session.
GET/api/remote/sessions/<session_id>/events-Return the persisted run timeline for a remote session.
POST/api/remote/sessions/<session_id>/interaction-Send an interaction response from the frontend to the remote agent.
PUT/api/remote/sessions/<session_id>/model-Switch the model of an active remote session.
POST/api/remote/sessions/<session_id>/pause-Pause a remote session.
POST/api/remote/sessions/<session_id>/permission-Send a permission response (approve/deny) from the frontend to the remote agent.
POST/api/remote/sessions/<session_id>/resume-Resume a paused remote session.
POST/api/remote/sessions/<session_id>/stop-Stop a remote session.
GET/api/remote/sessions/<session_id>/stream-SSE: real-time stream of remote session output, formatted as claude_json.
POST/api/remote/terminal/<terminal_id>/attach-Attach to existing terminal session (after browser refresh).
GET/api/remote/terminal/<terminal_id>/status-Get terminal status.
GET/api/remote/terminal/<terminal_id>/ws-Fallback for non-WebSocket requests to the terminal WebSocket endpoint (WebSocket).
POST/api/remote/terminal/cli/startmachine_access_requiredStart an SSH/local CLI-backed terminal session.
POST/api/remote/terminal/startmachine_access_requiredStart a web terminal on a remote machine.
POST/api/remote/terminal/stopmachine_access_requiredStop a web terminal on a remote machine.
POST/api/remote/token_info-Get token version information for an agent.
POST/api/remote/usage-report-Receive an authenticated, bound, idempotent Agent usage report.
POST/api/remote/vscode/<vscode_id>/attach-Re-attach to an existing code-server instance.
GET/api/remote/vscode/<vscode_id>/status-Get the status of a code-server instance.
GET/api/remote/vscode/<vscode_id>/ws-Fallback for non-WebSocket requests to the VS Code WebSocket endpoint (WebSocket).
GET/POST/PUT/DELETE/PATCH/OPTIONS/HEAD/api/remote/vscode/<vscode_id>/proxy/<path:path>-HTTP reverse proxy to the remote code-server.
GET/POST/PUT/DELETE/PATCH/OPTIONS/HEAD/api/remote/vscode/<vscode_id>/proxy/-Proxy base path (path empty).
POST/api/remote/vscode/startmachine_access_requiredStart a code-server instance on a remote machine.
POST/api/remote/vscode/stopmachine_access_requiredStop a code-server instance on a remote machine.

Workspace (/api/workspace)​

The built-in multi-user AI workspace: agent sessions, prompt templates, knowledge base, shares and annotations, teams, webui instances and the local LLM proxy.

MethodPathAuthDescription
GET/api/workspace/annotations-Get annotations for a session.
POST/api/workspace/annotations-Create an annotation.
GET/api/workspace/config-Get workspace configuration.
GET/api/workspace/instances-List all active webui instances (admin only).
POST/api/workspace/instances/<int:user_id>/stop-Stop a specific user's webui instance (admin only).
POST/api/workspace/instances/stop-all-Stop all webui instances (admin only).
GET/api/workspace/isolation-capabilitiesauth_requiredGet the workspace isolation capability contract.
GET/api/workspace/knowledge-List knowledge base entries.
POST/api/workspace/knowledge-Create a knowledge base entry.
GET/api/workspace/knowledge/<entry_id>-Fetch one knowledge base entry (ownership-checked).
POST/HEAD/api/workspace/llm-proxy-Transparent LLM proxy for local multi-user qwen-code-webui sessions (empty path).
GET/POST/PUT/DELETE/HEAD/api/workspace/llm-proxy/<path:path>-Local LLM proxy — catch-all path form.
GET/api/workspace/prompts-List prompt templates.
POST/api/workspace/prompts-Create a new prompt template.
DELETE/api/workspace/prompts/<int:template_id>-Delete a prompt template.
GET/api/workspace/prompts/<int:template_id>-Get a prompt template.
PUT/api/workspace/prompts/<int:template_id>-Update a prompt template.
POST/api/workspace/prompts/<int:template_id>/copy-Record a prompt copy action (increments use count).
POST/api/workspace/prompts/<int:template_id>/render-Render a prompt template with variables.
GET/api/workspace/prompts/categories-Get prompt categories with counts.
GET/api/workspace/prompts/featured-Get featured prompt templates.
GET/api/workspace/remote-projects-Get user's remote workspace projects list.
GET/api/workspace/session-models-Return integrated-mode qwen-code model options for the current scope context.
GET/api/workspace/sessions-List agent sessions.
POST/api/workspace/sessions-Create a new agent session.
DELETE/api/workspace/sessions/<session_id>-Delete a session.
GET/api/workspace/sessions/<session_id>-Get a session by ID.
POST/api/workspace/sessions/<session_id>/complete-Mark a session as completed.
GET/api/workspace/sessions/<session_id>/messages-Page through a session's messages with composite-key keyset pagination.
POST/api/workspace/sessions/<session_id>/rename-Rename a session.
POST/api/workspace/sessions/<session_id>/restore-Restore a historical session from agent_sessions to workspace.
GET/api/workspace/sessions/stats-Get session statistics.
GET/api/workspace/shares-List sessions shared with user.
POST/api/workspace/shares-Share a session.
DELETE/api/workspace/shares/<share_id>-Revoke a share.
GET/api/workspace/status-Get workspace status including today's token and request usage for current user.
GET/api/workspace/sync/events-Get sync events.
GET/api/workspace/sync/stats-Get sync statistics.
GET/api/workspace/teams-List user's teams.
POST/api/workspace/teams-Create a new team.
GET/api/workspace/terminal-models-Get all available models for terminal mode across all CLI tools.
GET/api/workspace/tools-List available AI tools.
GET/api/workspace/tools/<tool_name>-Get tool information.
GET/api/workspace/tools/<tool_name>/models-Get available models for a tool.
GET/api/workspace/tools/health-Check health of all tools.
GET/api/workspace/user-url-Get the user-specific webui URL with authentication token.

Autonomous development (/api/autonomous)​

Create and supervise autonomous development workflows: milestones, forks, retries, pause/resume, human verification overrides and a live event stream.

MethodPathAuthDescription
DELETE/api/autonomous/batches/<batch_id>auth_requiredDelete an entire batch of workflows.
POST/api/autonomous/internal/events/ingestpublic_endpointCross-process SSE ingest: scheduler process → this web process.
GET/api/autonomous/modelsauth_requiredGet available models for a given tool and workspace type.
GET/api/autonomous/toolsauth_requiredGet the list of available agent tools.
GET/api/autonomous/workflowsauth_requiredList autonomous development workflows.
POST/api/autonomous/workflowsauth_requiredCreate a new autonomous development workflow.
DELETE/api/autonomous/workflows/<workflow_id>auth_requiredCancel and delete a workflow.
GET/api/autonomous/workflows/<workflow_id>auth_requiredGet a workflow by ID.
POST/api/autonomous/workflows/<workflow_id>/doneauth_requiredMark workflow as complete, triggering merge phase.
GET/api/autonomous/workflows/<workflow_id>/events/streamauth_requiredSSE stream for real-time workflow events.
POST/api/autonomous/workflows/<workflow_id>/extend-planning-timeoutauth_requiredExtend the planning phase timeout for a timed-out workflow.
GET/api/autonomous/workflows/<workflow_id>/forksauth_requiredList all child workflows forked from this one.
POST/api/autonomous/workflows/<workflow_id>/milestones/<milestone_id>/cancelauth_requiredCancel a milestone and all subsequent milestones with user feedback.
GET/api/autonomous/workflows/<workflow_id>/milestones/<milestone_id>/diffauth_requiredGet the code diff for a milestone's commits.
POST/api/autonomous/workflows/<workflow_id>/milestones/<milestone_id>/forkauth_requiredFork from a milestone, creating a new independent workflow.
GET/api/autonomous/workflows/<workflow_id>/milestones/<milestone_id>/sessionauth_requiredGet the agent session associated with a milestone.
POST/api/autonomous/workflows/<workflow_id>/pauseauth_requiredPause a running workflow.
GET/api/autonomous/workflows/<workflow_id>/pr-diffauth_requiredGet the cumulative PR diff (head vs base) for a workflow.
GET/api/autonomous/workflows/<workflow_id>/pr-statsauth_requiredGet lightweight cumulative PR stats for a workflow.
POST/api/autonomous/workflows/<workflow_id>/resumeauth_requiredResume a paused workflow.
POST/api/autonomous/workflows/<workflow_id>/resume-with-feedbackauth_requiredResume a waiting workflow with updated user feedback.
POST/api/autonomous/workflows/<workflow_id>/retryauth_requiredRetry a failed workflow from its current phase.
POST/api/autonomous/workflows/<workflow_id>/stopauth_requiredGracefully stop a workflow.
GET/api/autonomous/workflows/<workflow_id>/timelineauth_requiredGet all milestones for a workflow (timeline).
POST/api/autonomous/workflows/<workflow_id>/verification_overrideauth_requiredHuman override: confirm an acceptance-paused workflow (#2335 S6, #2658).

Single sign-on (/api/sso)​

SSO provider registry (OAuth2/OIDC/SAML), login flows, SAML metadata/ACS/SLO endpoints, session info and identity linking.

MethodPathAuthDescription
POST/api/sso/acs/<provider_name>public_endpointHandle SAML HTTP-POST Assertion Consumer Service callbacks.
GET/api/sso/callback/<provider_name>public_endpointHandle SSO callback.
GET/api/sso/identities/<int:user_id>auth_requiredGet SSO identities for a user.
DELETE/api/sso/identities/<int:user_id>/<provider_name>auth_requiredUnlink an SSO identity from a user.
GET/api/sso/login/<provider_name>public_endpointStart SSO login flow.
GET/api/sso/providerspublic_endpointList available SSO providers.
POST/api/sso/providersadmin_requiredRegister a new SSO provider (admin only).
DELETE/api/sso/providers/<provider_name>admin_requiredDisable an SSO provider (DELETE method, deprecated - use PATCH /disable instead).
GET/api/sso/providers/<provider_name>admin_requiredGet detailed information about a specific SSO provider.
PUT/api/sso/providers/<provider_name>admin_requiredUpdate an existing SSO provider configuration.
PATCH/api/sso/providers/<provider_name>/disableadmin_requiredDisable an SSO provider (PATCH method, recommended).
PATCH/api/sso/providers/<provider_name>/enableadmin_requiredEnable an SSO provider.
GET/api/sso/providers/<provider_name>/metadatapublic_endpointReturn SAML Service Provider metadata for an enabled SAML provider.
POST/api/sso/providers/<provider_name>/resetadmin_requiredReset a predefined provider to its default configuration.
POST/api/sso/providers/<provider_name>/testadmin_requiredTest SSO provider connection (basic validation).
GET/api/sso/providers/exportadmin_requiredExport SSO provider configurations.
DELETE/api/sso/sessionpublic_endpointLogout from SSO session.
GET/api/sso/session-Get current SSO session info.
GET/api/sso/slo-redirect/<provider_name>public_endpointHandle SAML HTTP-Redirect Single Logout Service.
POST/api/sso/slo/<provider_name>public_endpointHandle SAML HTTP-POST Single Logout Service.

Integration and notification management (/api/management)​

Administrative configuration for outbound integrations: Feishu, DingTalk, SMTP, generic webhook, model gateway and notification channel status.

MethodPathAuthDescription
GET/PUT/DELETE/api/management/dingtalk-config-Get, update, or delete the DingTalk integration configuration.
POST/api/management/dingtalk-config/test-Test DingTalk credentials and organisation-sync permissions.
DELETE/api/management/feishu-config-Delete Feishu configuration.
GET/api/management/feishu-config-Get Feishu configuration.
PUT/api/management/feishu-config-Update Feishu configuration.
POST/api/management/feishu-config/test-Test Feishu connection and persist verification status.
DELETE/api/management/model-gateway-config-Delete the model gateway configuration.
GET/api/management/model-gateway-config-Get the model gateway configuration (API key masked) with enabled status.
PUT/api/management/model-gateway-config-Save (replace) the model gateway configuration.
POST/api/management/model-gateway-config/test-Test the gateway connection with supplied (or stored) credentials.
GET/api/management/notification-channels/status-Get the aggregated configuration status of all notification channels.
DELETE/api/management/smtp-config-Delete SMTP configuration.
GET/api/management/smtp-config-Get SMTP configuration.
PUT/api/management/smtp-config-Update SMTP configuration.
POST/api/management/smtp-config/send-test-Send a test email notification.
GET/api/management/smtp-config/statistics-Get email sending statistics.
POST/api/management/smtp-config/test-Test SMTP connection.
GET/PUT/DELETE/api/management/webhook-config-Get, update, or delete the generic webhook configuration (secret, private-URL policy, enabled flag).

User and organization administration (/api/admin)​

Platform administration: user lifecycle and quotas, Feishu/DingTalk organization sync and tenant quota tooling.

MethodPathAuthDescription
POST/api/admin/dingtalk/syncadmin_requiredManually trigger a DingTalk organization sync.
GET/api/admin/dingtalk/sync/lock-stateadmin_requiredInspect the DingTalk org-sync advisory lock (holder pid + hold time).
POST/api/admin/dingtalk/sync/release-lockadmin_requiredForcefully release a stuck DingTalk org-sync advisory lock.
POST/api/admin/feishu/syncadmin_requiredManually trigger a Feishu organization sync.
GET/api/admin/feishu/sync/lock-stateadmin_requiredInspect the Feishu org-sync advisory lock (holder pid + hold time).
POST/api/admin/feishu/sync/release-lockadmin_requiredForcefully release a stuck Feishu org-sync advisory lock.
POST/api/admin/quota/health-checkadmin_requiredCheck tenant quota health status.
GET/api/admin/quota/statsadmin_requiredGet quota allocation statistics for reference.
GET/api/admin/quota/usageadmin_requiredGet quota usage for all users the caller may see.
POST/api/admin/quota/validate-allocationadmin_requiredValidate if a quota allocation would exceed tenant limits.
GET/api/admin/usersadmin_requiredGet all users, optionally filtered by tenant.
POST/api/admin/usersadmin_requiredCreate a new user.
DELETE/api/admin/users/<int:user_id>admin_required,same_tenant_user_requiredDelete a user.
PUT/api/admin/users/<int:user_id>admin_required,same_tenant_user_requiredUpdate a user.
PUT/api/admin/users/<int:user_id>/passwordadmin_required,same_tenant_user_requiredUpdate a user's password.
PUT/api/admin/users/<int:user_id>/quotaadmin_required,same_tenant_user_requiredUpdate a user's quota.
POST/api/admin/users/<int:user_id>/reset-passwordadmin_required,same_tenant_user_requiredReset user password and generate a temporary password.
POST/api/admin/users/<int:user_id>/restoreadmin_required,same_tenant_user_requiredRestore a soft-deleted user.

Tenants (/api/tenants)​

Multi-tenant lifecycle and settings: create/update/suspend tenants, quotas, billing periods, usage, stats and tenant sensitive keywords.

MethodPathAuthDescription
GET/api/tenantsplatform_admin_requiredList all tenants (platform admin only).
POST/api/tenantsplatform_admin_requiredCreate a new tenant (platform admin only). Optionally create an admin user.
DELETE/api/tenants/<int:tenant_id>platform_admin_requiredDelete a tenant (platform admin only).
GET/api/tenants/<int:tenant_id>platform_admin_requiredGet tenant by ID (platform admin only).
PUT/api/tenants/<int:tenant_id>platform_admin_requiredUpdate tenant (platform admin only).
POST/api/tenants/<int:tenant_id>/activateplatform_admin_requiredActivate a suspended tenant (platform admin only).
POST/api/tenants/<int:tenant_id>/check-quotasame_tenant_or_platform_adminCheck if tenant has quota available (same tenant or platform admin).
PUT/api/tenants/<int:tenant_id>/quotaplatform_admin_requiredUpdate tenant quota (platform admin only).
POST/api/tenants/<int:tenant_id>/reset-periodplatform_admin_requiredReset billing period for a tenant (platform admin only).
GET/api/tenants/<int:tenant_id>/sensitive-keywordssame_tenant_or_platform_adminGet tenant sensitive keywords with pagination.
POST/api/tenants/<int:tenant_id>/sensitive-keywordssame_tenant_or_platform_adminCreate a tenant sensitive keyword.
PUT/api/tenants/<int:tenant_id>/sensitive-keywords/<int:keyword_id>same_tenant_or_platform_adminUpdate one tenant sensitive keyword.
DELETE/api/tenants/<int:tenant_id>/sensitive-keywords/<int:keyword_id>same_tenant_or_platform_adminDelete one tenant sensitive keyword.
PUT/api/tenants/<int:tenant_id>/settingssame_tenant_or_platform_adminUpdate tenant settings (same tenant or platform admin).
GET/api/tenants/<int:tenant_id>/statssame_tenant_or_platform_adminGet tenant statistics (same tenant or platform admin).
POST/api/tenants/<int:tenant_id>/suspendplatform_admin_requiredSuspend a tenant (platform admin only).
GET/api/tenants/<int:tenant_id>/usagesame_tenant_or_platform_adminGet tenant usage history (same tenant or platform admin).
GET/api/tenants/plansauth_requiredGet quota configurations for all plans (authenticated users).
GET/api/tenants/slug/<slug>platform_admin_requiredGet tenant by slug (platform admin only).

Compliance (/api/compliance)​

Compliance reporting, audit analytics (patterns, anomalies, security score) and data-retention rules, status and cleanup.

MethodPathAuthDescription
GET/api/compliance/audit/anomaliesadmin_requiredDetect audit anomalies (admin only).
POST/api/compliance/audit/anomalies/statusadmin_requiredUpdate anomaly status (admin only).
GET/api/compliance/audit/patternsadmin_requiredAnalyze audit patterns (admin only).
GET/api/compliance/audit/security-scoreadmin_requiredGet security score (admin only).
GET/api/compliance/audit/thresholdsadmin_requiredGet audit anomaly detection thresholds (admin only).
PUT/api/compliance/audit/thresholdsadmin_requiredUpdate audit anomaly detection thresholds (admin only).
GET/api/compliance/audit/user/<int:user_id>/profileadmin_required,same_tenant_user_requiredGet user behavior profile (admin only).
GET/api/compliance/reportsadmin_requiredList available report types.
POST/api/compliance/reportsadmin_requiredGenerate a compliance report (admin only).
GET/api/compliance/reports/<report_id>admin_requiredGet a saved report (admin only).
GET/api/compliance/reports/savedadmin_requiredList saved reports the caller may see.
POST/api/compliance/retention/cleanupadmin_requiredRun data retention cleanup (admin only).
GET/api/compliance/retention/historyadmin_requiredGet retention cleanup history (admin only).
GET/api/compliance/retention/rulesadmin_requiredGet data retention rules (admin only).
PUT/api/compliance/retention/rulesadmin_requiredSet a data retention rule (admin only).
GET/api/compliance/retention/statusadmin_requiredGet data retention compliance status (admin only).
GET/api/compliance/retention/storageadmin_requiredEstimate storage usage (admin only).

Tool accounts (/api/tool-accounts)​

Mappings between tool sender accounts and platform users, including pending, conflicting, stale and unmapped states.

MethodPathAuthDescription
GET/api/tool-accounts-Get all tool account mappings.
POST/api/tool-accounts-Create a new tool account mapping.
DELETE/api/tool-accounts/<int:id>-Delete a tool account mapping.
PUT/api/tool-accounts/<int:id>-Update a tool account mapping.
POST/api/tool-accounts/<int:id>/resolve-conflict-Resolve a conflict mapping.
POST/api/tool-accounts/<int:id>/touch-activity-Update last_activity_at timestamp.
POST/api/tool-accounts/<int:id>/verify-Verify a single tool account mapping.
GET/api/tool-accounts/conflicts-Get all unresolved conflict mappings.
GET/api/tool-accounts/pending-Get all pending (predeclared) mappings.
GET/api/tool-accounts/stale-Get all stale mappings.
GET/api/tool-accounts/status-summary-Get summary counts by mapping status.
GET/api/tool-accounts/unmapped-Get sender_names that are not mapped to any user.
GET/api/tool-accounts/user/<int:user_id>-Get tool accounts for a specific user.
POST/api/tool-accounts/user/<int:user_id>/batch-Batch create tool account mappings for a user.

Analysis (/api/analysis)​

Dashboard analytics over collected usage: key metrics, hourly/peak patterns, rankings, segmentation, anomalies and recommendations.

MethodPathAuthDescription
GET/api/analytics/forecastany_admin_requiredGet usage forecast.
GET/api/analysis/forecastany_admin_requiredAlias route for the usage forecast.
GET/api/analysis/anomaly-detection-Get anomaly detection results.
GET/api/analysis/anomaly-trend-Get anomaly trend over time.
GET/api/analysis/batch-Get all analysis data in a single request for better performance.
GET/api/analysis/conversation-stats-Get conversation statistics.
GET/api/analysis/daily-hourly-usage-Get daily and hourly usage patterns.
GET/api/analysis/data-range-Get the global data range (min and max dates) for the "All" quick-range.
GET/api/analysis/hourly-usage-Get hourly usage breakdown.
GET/api/analysis/key-metrics-Get key metrics for the dashboard.
GET/api/analysis/peak-usage-Get peak usage periods.
GET/api/analysis/recommendations-Get usage optimization recommendations.
GET/api/analysis/tool-comparison-Get tool comparison data.
GET/api/analysis/user-ranking-Get user ranking by token usage.
GET/api/analysis/user-role-distribution-Get user role distribution data.
GET/api/analysis/user-segmentation-Get user segmentation data.

Alerts (/api/alerts)​

The user-facing alert center: listing, read state, preferences, tenant alerts, failure queue and the SSE stream.

MethodPathAuthDescription
GET/api/alerts-Get alerts with filters.
DELETE/api/alerts/<alert_id>-Delete an alert and sync to quota_alerts.
POST/api/alerts/<alert_id>/read-Mark an alert as read and sync to quota_alerts.
GET/api/alerts/consistency-check-Check consistency between quota_alerts and alerts tables.
GET/api/alerts/failure-queue-Get alert creation failure queue status.
POST/api/alerts/failure-queue/retry-Manually trigger processing of the failure queue.
GET/api/alerts/preferences-Get notification preferences for current user.
PUT/api/alerts/preferences-Update notification preferences for current user.
POST/api/alerts/read-all-Mark all alerts as read.
GET/api/alerts/stream-Server-Sent Events stream for real-time alerts.
POST/api/alerts/sync-cleanup-Trigger synchronized cleanup of old alerts.
GET/api/alerts/tenanttenant_member_requiredGet tenant-scoped alerts.
POST/api/alerts/test-Create a test alert (for testing purposes).
GET/api/alerts/unread-count-Get count of unread alerts.

Projects (/api/projects)​

Shared projects: CRUD, daily statistics and collaborator management.

MethodPathAuthDescription
GET/api/projects-Get projects accessible by current user.
POST/api/projects-Create a new project.
DELETE/api/projects/<int:project_id>-Delete a project (soft delete).
GET/api/projects/<int:project_id>-Get project details.
PUT/api/projects/<int:project_id>-Update project information.
GET/api/projects/<int:project_id>/daily-Get daily statistics for a project.
POST/api/projects/<int:project_id>/fix-permissions-Fix shared project directory permissions.
GET/api/projects/<int:project_id>/users-Get users collaborating on a project.
POST/api/projects/<int:project_id>/users-Add a user to a shared project.
PUT/api/projects/<int:project_id>/users-Batch update visible users for a shared project.
DELETE/api/projects/<int:project_id>/users/<int:target_user_id>-Remove a user from a shared project.
GET/api/projects/stats-Get statistics for all projects (admin only).

Quota (/api/quota)​

Per-user and admin quota views and checks, quota alerts and the webui-token quota check.

MethodPathAuthDescription
GET/api/quota/alertsadmin_requiredGet quota alerts.
POST/api/quota/alerts/<int:alert_id>/acknowledgeadmin_requiredAcknowledge a quota alert.
GET/api/quota/checkauth_requiredCheck if the current user has quota available.
POST/api/quota/checkauth_requiredCheck if user has quota available.
POST/api/quota/check-all-Manually trigger quota check for all users.
GET/api/quota/statusauth_requiredGet detailed quota status for the current user.
GET/api/quota/status/alladmin_requiredGet quota status for all users (admin only).
GET/api/quota/usage/meauth_requiredGet detailed usage data for the current user.
GET/api/quota/webui-checkpublic_endpointCheck quota using webui token (called by webui backend middleware).

Mapping rules (/api/mapping-rules)​

The rule engine that auto-maps tool accounts to users: rule CRUD, match testing and per-user default generation.

MethodPathAuthDescription
GET/api/mapping-rulesadmin_requiredGet all mapping rules.
POST/api/mapping-rulesadmin_requiredCreate a new mapping rule.
DELETE/api/mapping-rules/<int:id>admin_requiredDelete a mapping rule.
PUT/api/mapping-rules/<int:id>admin_requiredUpdate a mapping rule.
POST/api/mapping-rules/auto-mapadmin_requiredRun auto-mapping for all unmapped accounts.
POST/api/mapping-rules/test-matchadmin_requiredTest if a tool_account matches any rules.
GET/api/mapping-rules/user/<int:user_id>admin_requiredGet mapping rules for a specific user.
POST/api/mapping-rules/user/<int:user_id>/generate-defaultadmin_requiredGenerate default mapping rules for a user.

Local file system (/api/fs)​

Bounded file access inside the user's home subtree: browse, search, upload, download and delete.

MethodPathAuthDescription
GET/api/fs/browse-Browse a directory and list subdirectories (and optionally files).
POST/api/fs/check-path-Check if a path is valid and can be used for a project.
POST/api/fs/create-directory-Create a directory on the local file system.
POST/api/fs/delete-file-Delete a file from the user's home subtree.
GET/api/fs/download-Stream a file from the user's home subtree as an attachment.
GET/api/fs/home-Get user's home directory.
GET/api/fs/search-Recursively search directory/file names under a home-subtree path.
POST/api/fs/upload-Upload a file into the user's home subtree (personal files page).

Encryption keys (/api/api/encryption-keys)​

Database encryption key management: rotation, validation, re-encryption, multi-replica sync status and the audit log.

MethodPathAuthDescription
GET/api/api/encryption-keysplatform_admin_requiredGet metadata for all encryption keys.
GET/api/api/encryption-keys/audit-logplatform_admin_requiredQuery the key-operation audit log.
POST/api/api/encryption-keys/generate-env-configplatform_admin_requiredGenerate environment-variable configuration for external systems.
POST/api/api/encryption-keys/re-encryptplatform_admin_requiredRe-encrypt all existing ciphertext with the current key.
POST/api/api/encryption-keys/re-encrypt/pre-checkplatform_admin_requiredPre-check existing ciphertext formats before a re-encryption run.
POST/api/api/encryption-keys/rotateplatform_admin_requiredRotate the encryption key.
GET/api/api/encryption-keys/sync-statusplatform_admin_requiredGet multi-replica key synchronization status.
POST/api/api/encryption-keys/validateplatform_admin_requiredValidate key format.

Return on investment (/api/roi)​

ROI views built on configurable planning assumptions: totals, trends, per-tool/per-user breakdowns and cost detail.

MethodPathAuthDescription
GET/api/roi-Get ROI metrics for a period.
GET/api/roi/by-tool-Get ROI breakdown by tool.
GET/api/roi/by-user-Get ROI breakdown by user.
GET/api/roi/cost-breakdown-Get detailed cost breakdown.
GET/api/roi/daily-costs-Get daily cost data for charting.
GET/api/roi/summary-Get ROI summary statistics.
GET/api/roi/trend-Get ROI trend over months.

Request statistics (/api/request)​

AI request counts (assistant responses): today, trend, per-tool, per-user and monthly aggregates.

MethodPathAuthDescription
GET/api/request/by-tool-Get request trend data aggregated by date and tool for charts.
GET/api/request/by-user-Get request statistics grouped by user (sender_name) for today.
GET/api/request/monthly-Get monthly request statistics grouped by user.
GET/api/request/today-Get today's request statistics with total and by-tool breakdown.
GET/api/request/trend-Get request trend data aggregated by date for charts.
GET/api/request/user/<user_name>/trend-Get request trend data for a specific user.

Authentication and account (/api/auth)​

Session login/logout, password change and current-user profile.

MethodPathAuthDescription
POST/api/auth/change-passwordauth_requiredChange password endpoint.
GET/api/auth/check-Check if user is authenticated and extend session if needed.
POST/api/auth/login-Login endpoint.
POST/api/auth/logoutpublic_endpointLogout endpoint.
GET/api/auth/meauth_requiredGet current user info (alias for /auth/profile).
GET/api/auth/profileauth_requiredGet current user profile.

External identity integration (/api/integrations/external)​

Default-off bridge for trusted external identity issuers. Both endpoints authenticate each request by its HMAC-SHA256 signature (X-ACE-Issuer/X-ACE-Time/X-ACE-Nonce/X-ACE-Signature headers, database-backed replay protection) — no cookie, bearer token, browser origin or query identity is ever accepted, hence the - Auth column. The policy file (OPENACE_EXTERNAL_IDENTITY_POLICY_FILE) gates the whole family: without it both endpoints return 404.

MethodPathAuthDescription
POST/api/integrations/external/capabilities-Read-only probe: verifies the signed request and reports the mapped issuer identity plus whether the token exchange is available (providers and models configured and OPENACE_EXTERNAL_TOKEN_ENABLED=1); consumes nothing.
POST/api/integrations/external/token-Exchange a signed request for a short-lived scoped proxy token for the mapped user (openace-external-v1); idempotent per external identity, audited, returns the token, expiry and the fixed LLM proxy path. Returns 404 unless the policy file and OPENACE_EXTERNAL_TOKEN_ENABLED=1 are set.

Other endpoints​

Smaller families without a dedicated section: analytics and insights, audit trails, content governance and policy, data fetch/upload pipelines, project categories, permission tasks, settings and schedulers, unmapped accounts, usage dashboards, API keys, user avatars and branding.

MethodPathAuthDescription
GET/api/ai-agent/settingsadmin_requiredGet AI agent settings (token masked).
PUT/api/ai-agent/settingsadmin_requiredUpdate AI agent settings.
POST/api/ai-agent/settings/validate-github-tokenadmin_requiredValidate a GitHub PAT by calling the GitHub API.
GET/api/analytics/efficiencyany_admin_requiredGet efficiency metrics.
GET/api/analytics/exportany_admin_requiredExport analytics data.
GET/api/analytics/reportany_admin_requiredGenerate a comprehensive usage report.
GET/api/api-keysapi_key_admin_requiredList all encrypted API keys (without revealing actual keys). Admin only.
POST/api/api-keysapi_key_admin_requiredStore a new encrypted API key. Admin only.
DELETE/api/api-keys/<int:key_id>api_key_admin_requiredDelete an API key by ID. Admin only.
PUT/api/api-keys/<int:key_id>api_key_admin_requiredUpdate an API key by ID. Admin only.
GET/api/audit-actionsadmin_requiredGet all audit action types with categories.
GET/api/audit-logsadmin_requiredGet audit logs with filters (alias for /audit/logs).
GET/api/audit/logsadmin_requiredGet audit logs with filters.
GET/api/audit/logs/exportadmin_requiredExport audit logs.
GET/api/audit/user/<int:user_id>/activityadmin_required,same_tenant_user_requiredGet activity summary for a user.
POST/api/content/checkauth_requiredCheck content for sensitive information.
POST/api/content/filter/keywordsplatform_admin_requiredAdd a custom sensitive keyword.
POST/api/content/filter/patternsplatform_admin_requiredAdd a custom content filter pattern.
GET/api/content/filter/statsadmin_requiredGet content filter statistics.
GET/api/conversation-details/<path:session_id>-Get details of a conversation.
GET/api/conversation-history-Get conversation history.
GET/api/conversation-timeline/<path:session_id>-Get timeline of messages for a conversation.
GET/api/data-statusauth_requiredGet data status information.
GET/api/date/<date_str>-Get usage for a specific date.
GET/api/feature-flagsauth_requiredGet current state of all feature flags.
GET/api/fetchadmin_requiredFetch data from local sources.
POST/api/fetch/dataauth_requiredTrigger data collection from all sources.
GET/api/fetch/remoteadmin_requiredFetch data from remote sources.
GET/api/fetch/statusauth_requiredGet data fetch status.
GET/api/filter-rulesadmin_requiredGet content filter rules with pagination and filtering.
POST/api/filter-rulesplatform_admin_requiredCreate a new content filter rule (idempotent).
DELETE/api/filter-rules/<int:rule_id>platform_admin_requiredDelete a content filter rule.
PUT/api/filter-rules/<int:rule_id>platform_admin_requiredUpdate a content filter rule.
POST/api/frontend-errorspublic_endpointReceive frontend error reports (public endpoint, no auth required).
GET/api/governance/audit-logsadmin_requiredGet audit logs with filters (full path alias for /audit/logs).
GET/api/hosts-Get list of all hosts from pre-aggregated summary table and remote machines.
DELETE/api/insights/<int:report_id>auth_requiredDelete an insights report.
POST/api/insights/generateauth_requiredGenerate or retrieve a cached insights report.
GET/api/insights/historyauth_requiredGet user's insights report history.
GET/api/mapping-statsadmin_requiredGet mapping statistics.
GET/api/messages-Get messages with pagination and filters.
GET/api/messages/count-Get count of messages with filters.
POST/api/migrate-quota-alerts-Migrate quota_alerts to alerts table.
GET/api/migration-progress-Get progress of quota_alerts to alerts migration.
GET/api/optimization/cost-trend-Get cost trend for optimization analysis.
GET/api/optimization/efficiency-Get efficiency analysis report.
GET/api/optimization/suggestions-Get cost optimization suggestions.
GET/api/password-policyauth_requiredGet password policy settings.
DELETE/api/permission-tasks/<task_id>-Cancel a permission task.
GET/api/permission-tasks/<task_id>-Get permission task status.
GET/api/policy/decisionsadmin_requiredList policy decisions, filtered by session_id (and optionally request_id).
GET/api/policy/rulesadmin_requiredList current (latest version) policy rules.
POST/api/policy/rulesadmin_requiredCreate a new policy rule (first version of a rule_key).
PATCH/api/policy/rules/<int:rule_id>/enabledadmin_requiredToggle enabled on the current version of a rule.
PUT/api/policy/rules/<rule_key>admin_requiredVersioned edit: supersede the current version and insert a new one.
GET/api/project-categories-List all project categories.
POST/api/project-categories-Create a new category (admin only).
DELETE/api/project-categories/<int:category_id>-Delete a category (admin only).
PUT/api/project-categories/<int:category_id>-Update a category (admin only).
GET/api/public/branding-Get branding configuration for login page.
GET/api/range-Get usage for a date range.
GET/api/report/my-usageauth_requiredGet current user's usage report.
GET/api/schedulers-Get status of all background schedulers.
GET/api/schedulers/data-fetch-Get data fetch scheduler status.
GET/api/schedulers/quota-enforcement-Get quota enforcement scheduler status.
GET/api/security-settingsadmin_requiredGet security settings.
PUT/api/security-settingsplatform_admin_requiredUpdate security settings.
GET/api/security-settings/upload-auth-statusadmin_requiredGet upload authentication status.
GET/api/senders-Get list of all senders (cached for 5 minutes).
GET/api/settings-Get all system settings.
PUT/api/settings-Update system settings.
GET/api/settings/sso-enabled-Get SSO enabled status.
GET/api/summary-Get summary statistics for all tools from pre-aggregated summary table.
POST/api/summary/refresh-Refresh summary data from daily_messages table.
GET/api/today-Get today's usage for all tools, merged by tool_name.
GET/api/tool-types-Get available tool types.
GET/api/tool/<tool_name>/<int:days>-Get usage for a specific tool over N days.
GET/api/tools-Get list of all tools.
GET/api/trend-Get usage trend data aggregated by date for charts.
GET/api/unmapped-accountsadmin_requiredGet list of unmapped tool accounts.
POST/api/unmapped-accounts/<sender_name>/mapadmin_requiredManually map an unmapped account to a user.
GET/api/unmapped-accounts/<sender_name>/suggest-mappingadmin_requiredGet suggested mapping for an unmapped account.
POST/api/upload/batchrequire_upload_authUpload batch data (usage and messages).
POST/api/upload/messagesrequire_upload_authUpload message data.
POST/api/upload/usagerequire_upload_authUpload usage data.
DELETE/api/user/avatarauth_requiredDelete user avatar.
POST/api/user/avatarauth_requiredUpload user avatar.

Operational endpoints​

Application-level health and readiness probes, Prometheus metrics, security baseline status, plus the React SPA page and static routes.

MethodPathAuthDescription
GET/public_endpointServe the React SPA for the main page.
GET/<path:path>public_endpointServe React SPA for all other routes.
GET/health-Health check endpoint for Docker and load balancers.
GET/livez-Liveness probe for Kubernetes.
GET/loginpublic_endpointServe the React SPA for the login page.
GET/logoutpublic_endpointLogout and serve React SPA.
GET/metrics-Prometheus metrics (fallback endpoint when prometheus_flask_exporter is not available).
GET/readyz-Readiness check endpoint for Kubernetes and load balancers.
GET/security-status-Security baseline status endpoint for monitoring and health checks.
GET/static/claude-code-webui/<path:filename>public_endpointServe static files.