Download OpenAPI specification:Download
REST API for the AxonFlow Orchestrator service - Dynamic Policy Enforcement, LLM Routing, and Multi-Agent Planning.
The Orchestrator handles:
Client → Agent → Orchestrator → LLM Providers
↘ MCP Connectors
The Orchestrator receives pre-authenticated requests from the Agent and handles complex processing including LLM calls and dynamic policy evaluation.
These endpoints are typically called by the Agent service, not directly by clients. For client-facing APIs, see the Agent API specification.
Returns service health status including component health:
{- "status": "healthy",
- "service": "axonflow-orchestrator",
- "version": "9.8.0",
- "timestamp": "2025-01-15T10:30:00Z",
- "components": {
- "policy_engine": true,
- "llm_router": true,
- "response_processor": true,
- "audit_logger": true,
- "workflow_engine": true,
- "planning_engine": true,
- "result_aggregator": true
}, - "features": {
- "multi_agent_planning": true
}
}Main processing endpoint. Handles:
Note: This endpoint is typically called by the Agent, not directly by clients.
For MCP queries (request_type: mcp-query), routes to the Agent MCP handler.
| request_id | string Unique request identifier |
| query required | string Query to process |
| request_type | string Type of request |
| skip_llm | boolean Default: false Skip LLM calls (for testing) |
required | object (UserContext) |
required | object (ClientContext) |
object Free-form request metadata. Routing controls:
| |
| timestamp | string <date-time> |
Array of objects (MediaContentRequest) <= 10 items Optional media content (images) for multimodal governance analysis |
{- "request_id": "req_12345",
- "query": "Summarize the quarterly report",
- "request_type": "llm_chat",
- "user": {
- "id": 123,
- "role": "analyst",
- "permissions": [
- "query",
- "llm_chat"
], - "tenant_id": "tenant-abc"
}, - "client": {
- "id": "analytics-app",
- "name": "Analytics Dashboard",
- "org_id": "org-123",
- "tenant_id": "tenant-abc"
}, - "context": {
- "provider": "openai",
- "strict_provider": false,
- "model_preference": "gpt-4"
}, - "timestamp": "2025-01-15T10:30:00Z"
}{- "request_id": "req_12345",
- "success": true,
- "data": "Here is the quarterly report summary...",
- "redacted": false,
- "policy_info": {
- "allowed": true,
- "applied_policies": [
- "rate-limit",
- "content-filter"
], - "risk_score": 0.15,
- "processing_time_ms": 5
}, - "provider_info": {
- "provider": "openai",
- "model": "gpt-4",
- "response_time_ms": 1250,
- "tokens_used": 350,
- "cost": 0.021
}, - "processing_time": "1.3s"
}Multi-Agent Planning (MAP) endpoint for complex, multi-step tasks.
auto: Automatically determines parallel/sequential (recommended)parallel: Force parallel execution of all independent stepssequential: Force sequential step-by-step executionbalanced: I/O-bound connector steps parallel, LLM steps sequentialconfirm: Every step requires explicit approval (Enterprise only)step: First step auto-executes, subsequent require approval (Enterprise only)travel: Flights, hotels, itinerarieshealthcare: Medical queriesfinance: Financial analysisgeneric: General-purpose tasksPlan steps are automatically routed to matching connectors based on capabilities. Community: Subject to connector limits (2 connectors). Enterprise: Unlimited connectors with multi-connector fallback support.
Requires authentication: Requests must come through the Agent.
| query required | string Natural language task description |
| domain | string Default: "generic" Enum: "travel" "healthcare" "finance" "generic" Task domain for specialized handling |
| execution_mode | string Default: "auto" Enum: "auto" "parallel" "sequential" "balanced" "confirm" "step" How to execute sub-tasks.
|
required | object (UserContext) |
object | |
object |
{- "query": "Find flights from NYC to LAX next week and suggest hotels",
- "domain": "travel",
- "execution_mode": "auto",
- "user": {
- "id": 123,
- "role": "employee",
- "permissions": [
- "query",
- "mcp_query"
], - "tenant_id": "tenant-abc"
}, - "client": {
- "id": "travel-planner",
- "name": "Travel Planning App"
}, - "context": {
- "departure_date": "2025-01-20",
- "return_date": "2025-01-25",
- "budget": 1500
}
}{- "success": true,
- "plan_id": "plan_1705312200_abc123",
- "workflow_execution_id": "exec_xyz789",
- "result": {
- "flights": [
- {
- "flight_number": "UA123",
- "price": 299,
- "departure": "2025-01-20T08:00:00Z"
}
], - "hotels": [
- {
- "name": "Hilton LAX",
- "price_per_night": 189,
- "rating": 4.5
}
], - "summary": "Found 5 flights and 3 hotels within budget"
}, - "metadata": {
- "tasks_executed": 3,
- "execution_mode": "parallel",
- "execution_time_ms": 3500,
- "tasks": [
- {
- "name": "search_flights",
- "status": "completed",
- "time_ms": 1200
}, - {
- "name": "search_hotels",
- "status": "completed",
- "time_ms": 1100
}, - {
- "name": "synthesize_results",
- "status": "completed",
- "time_ms": 800
}
]
}
}Executes a plan previously generated and stored via POST /api/v1/plan.
The plan to execute is identified by context.plan_id in the request body.
The execution mode is taken from the stored plan (not this request):
auto, parallel, sequential, balanced, or the Enterprise-only
HITL modes confirm / step.
Requires authentication: requests must be routed through the AxonFlow
Agent (user.id must be set). The X-Tenant-ID / X-Org-ID headers set
by the Agent auth chain override any identity fields in the body.
A plan can be executed once: re-executing returns 409, a cancelled plan returns 409, and an expired plan returns 410.
| query required | string Natural language task description |
| domain | string Default: "generic" Enum: "travel" "healthcare" "finance" "generic" Task domain for specialized handling |
| execution_mode | string Default: "auto" Enum: "auto" "parallel" "sequential" "balanced" "confirm" "step" How to execute sub-tasks.
|
required | object (UserContext) |
object | |
object |
{- "query": "Find flights from NYC to LAX next week",
- "domain": "travel",
- "user": {
- "id": 123,
- "role": "employee",
- "permissions": [
- "query",
- "mcp_query"
], - "tenant_id": "tenant-abc"
}, - "context": {
- "plan_id": "plan_1705312200_abc123"
}
}{- "success": true,
- "plan_id": "string",
- "version": 1,
- "steps": [
- {
- "name": "string",
- "type": "string",
- "description": "string"
}
], - "workflow_execution_id": "string",
- "result": null,
- "metadata": {
- "tasks_executed": 0,
- "execution_mode": "string",
- "execution_time_ms": 0,
- "tasks": [
- {
- "name": "string",
- "status": "string",
- "time_ms": 0
}
]
}, - "error": "string",
- "policy_info": {
- "allowed": true,
- "applied_policies": [
- "string"
], - "risk_score": 1,
- "required_actions": [
- "string"
], - "processing_time_ms": 0,
- "database_accessed": true
}, - "complexity": "medium",
- "domain": "travel",
- "parallel": true,
- "status": "string"
}Retrieve the status of a plan by ID.
Returns detailed execution status including:
New in #1075: Response now includes unified execution tracking with:
steps array with individual step statusprogress_percent for real-time progressduration for elapsed timeestimated_cost_usd and actual_cost_usd for cost tracking| id required | string Plan ID (e.g., plan_1705312200_abc123) |
{- "plan_id": "plan_1705312200_abc123",
- "execution_id": "plan_xyz789",
- "status": "pending",
- "query": "Find flights from NYC to LAX",
- "domain": "travel",
- "total_steps": 3,
- "completed_steps": 0,
- "progress_percent": 0,
- "created_at": "2025-01-15T10:00:00Z",
- "expires_at": "2025-01-15T12:00:00Z"
}Update a plan that has not yet been executed.
Uses optimistic locking via the version field — the request must include
the expected current version. If the version doesn't match, returns 409.
Only plans with status pending can be updated.
| id required | string Plan ID to update |
| version required | integer Expected current version (for optimistic locking) |
| execution_mode | string Enum: "auto" "parallel" "sequential" "balanced" "confirm" "step" New execution mode |
| domain | string New domain |
object Additional metadata to set |
{- "version": 1,
- "execution_mode": "parallel"
}{- "success": true,
- "plan_id": "plan_1705312200_abc123",
- "version": 2,
- "status": "pending"
}Cancel a plan that has not yet completed execution.
Only plans with status pending or executing can be cancelled.
Returns 409 if the plan is already completed or cancelled.
| id required | string Plan ID to cancel |
| reason | string Optional cancellation reason |
{- "reason": "User requested cancellation"
}{- "success": true,
- "plan_id": "plan_1705312200_abc123",
- "status": "cancelled"
}Retrieve the version history for a plan, showing all changes made. Each version entry includes the change type, who made it, and when.
Community: Max 10 versions per plan, max 25 plans with versioning. Enterprise: Unlimited.
| id required | string Plan ID |
{- "plan_id": "plan_1705312200_abc123",
- "versions": [
- {
- "version": 1,
- "changed_at": "2026-01-15T10:00:00Z",
- "change_type": "created",
- "change_summary": "Plan created"
}, - {
- "version": 2,
- "changed_at": "2026-01-15T10:05:00Z",
- "changed_by": "user-123",
- "change_type": "updated",
- "change_summary": "Changed execution_mode to parallel"
}
]
}Resume execution of a plan that is paused at an approval gate.
Used with confirm and step execution modes.
confirm mode: Every step requires explicit approvalstep mode: First step auto-executes, subsequent steps require approvalSet approved: true to approve and execute the next step,
or approved: false to reject and abort the plan.
Requires: Enterprise license.
| id required | string Plan ID to resume |
| approved | boolean Default: true Whether to approve the pending step |
{- "approved": true
}{- "plan_id": "plan_1705312200_abc123",
- "status": "awaiting_approval",
- "result": null
}Rollback a plan to a previously saved version. This creates a new version that restores the plan state from the specified historical version.
Uses the plan's version history to retrieve the target version and applies it as the current state. Returns 409 if a concurrent modification occurred.
Requires: Enterprise license.
| id required | string Example: plan_1705312200_abc123 Plan ID to rollback |
| version required | integer Example: 2 Target version number to rollback to |
{ }{- "plan_id": "plan_1705312200_abc123",
- "version": 4,
- "previous_version": 2,
- "status": "pending"
}Plan-scoped approval endpoint. Returns the same ApprovalResponse
shape as the WCP endpoint (/api/v1/workflows/{id}/steps/{step_id}/approve)
plus a plan_id field — see ADR-046 (HITL response parity).
Two underlying flows, identical response:
retry_context, approver metadata, and policies_matched.retry_context zero-valued and approval_id from the execution
record.| planId required | string Example: plan-abc123 MAP plan ID |
| stepId required | string Example: step_0_analyze Step ID awaiting approval |
| approved_by | string Identity approving the step (overrides X-User-ID header) |
| comment | string Audit justification. Required on WCP-backed plans (min 10 chars); if shorter, the handler auto-fills a generated audit message. |
{- "comment": "Approved after full audit review of the payment intent"
}{- "workflow_id": "wf_abc123",
- "plan_id": "plan-abc123",
- "step_id": "step_0_analyze",
- "status": "approved",
- "decision": "allow",
- "reason": "Approved: High-value transfer requires oversight",
- "approval_status": "approved",
- "approval_id": "318a270f-7b42-5c56-a191-8dbd1bf2e1e4",
- "approved_at": "2026-04-22T10:05:00Z",
- "policies_matched": [
- {
- "policy_id": "high-value-wire-oversight",
- "policy_name": "High-Value Wire Transfer Oversight",
- "action": "require_approval"
}
], - "retry_context": {
- "gate_count": 1,
- "completion_count": 0,
- "prior_completion_status": "none",
- "prior_output_available": false,
- "prior_output": null,
- "prior_completion_at": null,
- "idempotency_key": "payment-intent-123",
- "last_decision": "require_approval",
- "first_attempt_at": "2026-04-22T10:00:00Z",
- "last_attempt_at": "2026-04-22T10:00:00Z"
}, - "message": "Step approved"
}Plan-scoped rejection endpoint. Symmetric with the WCP endpoint
(/api/v1/workflows/{id}/steps/{step_id}/reject) — same response
shape (ApprovalResponse) plus plan_id. See ADR-046.
Rejection aborts the workflow / plan. On WCP-backed plans the WCP
service's RejectStep handles the abort; on the legacy in-memory
flow, the HITL workflow engine's AbortExecution handles it.
| planId required | string |
| stepId required | string |
| rejected_by | string |
| reason | string Audit justification. Required on WCP-backed plans (min 10 chars); auto-filled otherwise. |
{- "reason": "Output contains PII that was not redacted"
}{- "workflow_id": "wf_abc123",
- "plan_id": "plan-42",
- "step_id": "step-2",
- "status": "approved",
- "decision": "allow",
- "reason": "Approved: High-value transfer requires oversight",
- "approval_status": "approved",
- "approval_id": "318a270f-7b42-5c56-a191-8dbd1bf2e1e4",
- "approved_at": "2019-08-24T14:15:22Z",
- "rejected_at": "2019-08-24T14:15:22Z",
- "policies_matched": [
- {
- "policy_id": "string",
- "policy_name": "string",
- "action": "allow",
- "reason": "string"
}
], - "retry_context": {
- "gate_count": 2,
- "completion_count": 1,
- "prior_completion_status": "completed",
- "prior_output_available": true,
- "prior_output": { },
- "prior_completion_at": "2019-08-24T14:15:22Z",
- "first_attempt_at": "2019-08-24T14:15:22Z",
- "last_attempt_at": "2019-08-24T14:15:22Z",
- "last_decision": "allow",
- "idempotency_key": "payment:wire:invoice-7721"
}, - "message": "Step approved"
}Agent configuration management (MAP 0.8). Enterprise only — the
/api/v1/agents route family is registered only in Enterprise builds
with a database connection; Community returns 404.
Returns a paginated list of all agents from the registry. In hybrid mode, includes both file-based and database-backed agents. Database agents take priority over file agents with the same name.
Enterprise only. The entire /api/v1/agents route family is
registered only in Enterprise builds with a database connection;
Community deployments return 404 for every /api/v1/agents path.
| page | integer >= 1 Default: 1 Page number (1-based) |
| page_size | integer [ 1 .. 100 ] Default: 20 Number of agents per page |
| domain | string Filter by domain |
{- "agents": [
- {
- "id": "travel/flight-booking",
- "name": "flight-booking",
- "domain": "travel",
- "description": "Flight search and booking agent",
- "version": 1,
- "is_active": true
}, - {
- "id": "healthcare/patient-assistant",
- "name": "patient-assistant",
- "domain": "healthcare",
- "description": "Patient query assistant",
- "version": 2,
- "is_active": true
}
], - "pagination": {
- "page": 1,
- "page_size": 20,
- "total": 2,
- "total_pages": 1
}
}Create a new agent configuration in the database. Enterprise only - requires database-backed storage.
The agent is created with version 1 and marked as active by default. A version history entry is automatically created.
| name required | string Agent name (lowercase, alphanumeric, hyphens, underscores) |
| domain | string Agent domain |
| description | string |
| is_active | boolean Default: true |
required | object (AgentConfigSpec) Agent configuration specification |
{- "name": "travel-planner",
- "domain": "travel",
- "description": "Travel planning and booking assistant",
- "is_active": true,
- "config": {
- "execution": {
- "default_mode": "auto",
- "max_parallel_tasks": 5,
- "timeout_seconds": 300
}, - "agents": [
- {
- "name": "flight-search",
- "type": "llm-call",
- "llm": {
- "provider": "anthropic",
- "model": "claude-sonnet-4"
}
}
], - "routing": [
- {
- "pattern": "flight|fly",
- "agent": "flight-search",
- "priority": 10
}
]
}
}{- "agent": {
- "id": "travel/flight-booking",
- "name": "flight-booking",
- "domain": "travel",
- "description": "string",
- "version": 0,
- "is_active": true,
- "config": {
- "execution": {
- "default_mode": "auto",
- "max_parallel_tasks": 0,
- "timeout_seconds": 0
}, - "agents": [
- {
- "name": "string",
- "type": "llm-call",
- "llm": {
- "provider": "string",
- "model": "string"
}, - "connector": {
- "name": "string",
- "operation": "string"
}
}
], - "routing": [
- {
- "pattern": "string",
- "agent": "string",
- "priority": 0
}
]
}, - "created_at": "2019-08-24T14:15:22Z",
- "updated_at": "2019-08-24T14:15:22Z"
}
}Returns detailed information about a specific agent.
The ID format is domain/name (e.g., travel/flight-booking).
Enterprise only - the /api/v1/agents family is not registered in Community.
| id required | string Example: travel/flight-booking Agent ID in format domain/name |
{- "id": "travel/flight-booking",
- "name": "flight-booking",
- "domain": "travel",
- "description": "string",
- "version": 0,
- "is_active": true,
- "config": {
- "execution": {
- "default_mode": "auto",
- "max_parallel_tasks": 0,
- "timeout_seconds": 0
}, - "agents": [
- {
- "name": "string",
- "type": "llm-call",
- "llm": {
- "provider": "string",
- "model": "string"
}, - "connector": {
- "name": "string",
- "operation": "string"
}
}
], - "routing": [
- {
- "pattern": "string",
- "agent": "string",
- "priority": 0
}
]
}, - "created_at": "2019-08-24T14:15:22Z",
- "updated_at": "2019-08-24T14:15:22Z"
}Update an existing agent configuration. Enterprise only - requires database-backed storage.
Updates increment the version number automatically. A version history entry is created for the change.
| id required | string <uuid> Agent ID (UUID) |
| name | string |
| domain | string |
| description | string |
| is_active | boolean |
object (AgentConfigSpec) Agent configuration specification |
{- "name": "string",
- "domain": "string",
- "description": "string",
- "is_active": true,
- "config": {
- "execution": {
- "default_mode": "auto",
- "max_parallel_tasks": 0,
- "timeout_seconds": 0
}, - "agents": [
- {
- "name": "string",
- "type": "llm-call",
- "llm": {
- "provider": "string",
- "model": "string"
}, - "connector": {
- "name": "string",
- "operation": "string"
}
}
], - "routing": [
- {
- "pattern": "string",
- "agent": "string",
- "priority": 0
}
]
}
}{- "agent": {
- "id": "travel/flight-booking",
- "name": "flight-booking",
- "domain": "travel",
- "description": "string",
- "version": 0,
- "is_active": true,
- "config": {
- "execution": {
- "default_mode": "auto",
- "max_parallel_tasks": 0,
- "timeout_seconds": 0
}, - "agents": [
- {
- "name": "string",
- "type": "llm-call",
- "llm": {
- "provider": "string",
- "model": "string"
}, - "connector": {
- "name": "string",
- "operation": "string"
}
}
], - "routing": [
- {
- "pattern": "string",
- "agent": "string",
- "priority": 0
}
]
}, - "created_at": "2019-08-24T14:15:22Z",
- "updated_at": "2019-08-24T14:15:22Z"
}
}Delete an agent configuration. Enterprise only - requires database-backed storage.
The deletion is recorded in the version history before removal.
| id required | string <uuid> Agent ID (UUID) |
{- "success": false,
- "error": "string"
}Validates an agent configuration without creating it. Useful for dry-run validation before deployment.
Enterprise only - the /api/v1/agents family is not registered in Community.
Checks:
| name | string |
| domain | string |
required | object (AgentConfigSpec) Agent configuration specification |
{- "name": "string",
- "domain": "string",
- "config": {
- "execution": {
- "default_mode": "auto",
- "max_parallel_tasks": 0,
- "timeout_seconds": 0
}, - "agents": [
- {
- "name": "string",
- "type": "llm-call",
- "llm": {
- "provider": "string",
- "model": "string"
}, - "connector": {
- "name": "string",
- "operation": "string"
}
}
], - "routing": [
- {
- "pattern": "string",
- "agent": "string",
- "priority": 0
}
]
}
}{- "valid": true,
- "errors": [ ]
}Activate a deactivated agent. Enterprise only - requires database-backed storage.
| id required | string <uuid> Agent ID (UUID) |
{- "agent": {
- "id": "travel/flight-booking",
- "name": "flight-booking",
- "domain": "travel",
- "description": "string",
- "version": 0,
- "is_active": true,
- "config": {
- "execution": {
- "default_mode": "auto",
- "max_parallel_tasks": 0,
- "timeout_seconds": 0
}, - "agents": [
- {
- "name": "string",
- "type": "llm-call",
- "llm": {
- "provider": "string",
- "model": "string"
}, - "connector": {
- "name": "string",
- "operation": "string"
}
}
], - "routing": [
- {
- "pattern": "string",
- "agent": "string",
- "priority": 0
}
]
}, - "created_at": "2019-08-24T14:15:22Z",
- "updated_at": "2019-08-24T14:15:22Z"
}
}Deactivate an agent without deleting it. Enterprise only - requires database-backed storage.
| id required | string <uuid> Agent ID (UUID) |
{- "agent": {
- "id": "travel/flight-booking",
- "name": "flight-booking",
- "domain": "travel",
- "description": "string",
- "version": 0,
- "is_active": true,
- "config": {
- "execution": {
- "default_mode": "auto",
- "max_parallel_tasks": 0,
- "timeout_seconds": 0
}, - "agents": [
- {
- "name": "string",
- "type": "llm-call",
- "llm": {
- "provider": "string",
- "model": "string"
}, - "connector": {
- "name": "string",
- "operation": "string"
}
}
], - "routing": [
- {
- "pattern": "string",
- "agent": "string",
- "priority": 0
}
]
}, - "created_at": "2019-08-24T14:15:22Z",
- "updated_at": "2019-08-24T14:15:22Z"
}
}Test an agent configuration in a sandbox environment. Enterprise only - requires database-backed storage.
Executes a test query against the agent without affecting production.
| id required | string <uuid> Agent ID (UUID) |
| query required | string Test query to execute |
object Additional context for the query |
{- "query": "Search for flights from NYC to LAX",
- "context": {
- "departure_date": "2025-01-15"
}
}{- "success": true,
- "result": null,
- "execution_time_ms": 0,
- "tasks_executed": 0,
- "errors": [
- "string"
]
}Returns the version history for an agent. Enterprise only - requires database-backed storage.
Includes all changes: create, update, delete, activate, deactivate.
| id required | string <uuid> Agent ID (UUID) |
| limit | integer <= 100 Default: 50 Maximum number of versions to return |
{- "versions": [
- {
- "version": 2,
- "change_type": "update",
- "changed_at": "2025-12-07T12:00:00Z",
- "change_summary": "Updated routing rules"
}, - {
- "version": 1,
- "change_type": "create",
- "changed_at": "2025-12-06T10:00:00Z",
- "change_summary": "Initial creation"
}
]
}{- "providers": [
- {
- "name": "openai",
- "available": true,
- "models": [
- "gpt-4",
- "gpt-4o",
- "gpt-4o-mini"
], - "weight": 0.4,
- "avg_latency_ms": 1200
}, - {
- "name": "bedrock",
- "available": true,
- "models": [
- "anthropic.claude-v2",
- "amazon.titan-text"
], - "weight": 0.4,
- "avg_latency_ms": 900
}, - {
- "name": "ollama",
- "available": true,
- "models": [
- "llama3.2",
- "mistral"
], - "weight": 0.2,
- "avg_latency_ms": 500
}
]
}Update the routing weights for LLM providers. Weights determine the probability of routing to each provider. Weights must sum to 1.0.
| property name* additional property | number [ 0 .. 1 ] |
{- "openai": 0.5,
- "bedrock": 0.3,
- "ollama": 0.2
}{- "status": "success",
- "message": "Provider weights updated"
}Returns a list of available LLM provider types (factory info). This endpoint helps clients discover what provider types can be configured.
{- "provider_types": [
- {
- "type": "openai",
- "name": "OpenAI",
- "description": "OpenAI GPT models (gpt-4, gpt-4o-mini)",
- "supports_streaming": true,
- "requires_api_key": true
}, - {
- "type": "anthropic",
- "name": "Anthropic",
- "description": "Anthropic Claude models",
- "supports_streaming": true,
- "requires_api_key": true
}, - {
- "type": "bedrock",
- "name": "AWS Bedrock",
- "description": "AWS Bedrock models (Claude, Titan, Llama)",
- "supports_streaming": true,
- "requires_api_key": false
}, - {
- "type": "ollama",
- "name": "Ollama",
- "description": "Local Ollama models",
- "supports_streaming": true,
- "requires_api_key": false
}
]
}Returns a paginated list of configured LLM providers. Supports filtering by type and enabled status.
| type | string Enum: "openai" "azure-openai" "anthropic" "bedrock" "ollama" "gemini" "custom" Filter by provider type |
| enabled | boolean Filter by enabled status |
| page | integer Default: 1 Page number (1-indexed) |
| page_size | integer <= 100 Default: 20 Items per page |
{- "providers": [
- {
- "name": "string",
- "type": "openai",
- "endpoint": "string",
- "model": "string",
- "region": "string",
- "enabled": true,
- "priority": 0,
- "weight": 0,
- "rate_limit": 0,
- "timeout_seconds": 0,
- "has_api_key": true,
- "settings": { },
- "health": {
- "status": "healthy",
- "message": "string",
- "last_checked": "2019-08-24T14:15:22Z"
}
}
], - "pagination": {
- "page": 1,
- "page_size": 20,
- "total_items": 42,
- "total_pages": 3
}
}Register a new LLM provider. API keys can be provided directly or via AWS Secrets Manager ARN for secure credential storage.
| name required | string Unique provider name |
| type required | string Enum: "openai" "azure-openai" "anthropic" "bedrock" "ollama" "gemini" "custom" |
| api_key | string API key (mutually exclusive with api_key_secret_arn) |
| api_key_secret_arn | string AWS Secrets Manager ARN for API key |
| endpoint | string API endpoint URL |
| model | string Default model name |
| region | string AWS region (for Bedrock) |
| enabled | boolean Default: true |
| priority | integer Default: 100 |
| weight | integer Default: 100 |
| rate_limit | integer Max requests per second |
| timeout_seconds | integer Default: 30 |
object |
{- "name": "string",
- "type": "openai",
- "api_key": "string",
- "api_key_secret_arn": "string",
- "endpoint": "string",
- "model": "string",
- "region": "string",
- "enabled": true,
- "priority": 100,
- "weight": 100,
- "rate_limit": 0,
- "timeout_seconds": 30,
- "settings": { }
}{- "provider": {
- "name": "string",
- "type": "openai",
- "endpoint": "string",
- "model": "string",
- "region": "string",
- "enabled": true,
- "priority": 0,
- "weight": 0,
- "rate_limit": 0,
- "timeout_seconds": 0,
- "has_api_key": true,
- "settings": { },
- "health": {
- "status": "healthy",
- "message": "string",
- "last_checked": "2019-08-24T14:15:22Z"
}
}
}Returns details for a specific LLM provider
| name required | string Provider name |
{- "provider": {
- "name": "string",
- "type": "openai",
- "endpoint": "string",
- "model": "string",
- "region": "string",
- "enabled": true,
- "priority": 0,
- "weight": 0,
- "rate_limit": 0,
- "timeout_seconds": 0,
- "has_api_key": true,
- "settings": { },
- "health": {
- "status": "healthy",
- "message": "string",
- "last_checked": "2019-08-24T14:15:22Z"
}
}
}Update an existing LLM provider configuration. Only provided fields are updated (partial update).
| name required | string Provider name |
| api_key | string |
| api_key_secret_arn | string |
| endpoint | string |
| model | string |
| region | string |
| enabled | boolean |
| priority | integer |
| weight | integer |
| rate_limit | integer |
| timeout_seconds | integer |
object |
{- "api_key": "string",
- "api_key_secret_arn": "string",
- "endpoint": "string",
- "model": "string",
- "region": "string",
- "enabled": true,
- "priority": 0,
- "weight": 0,
- "rate_limit": 0,
- "timeout_seconds": 0,
- "settings": { }
}{- "provider": {
- "name": "string",
- "type": "openai",
- "endpoint": "string",
- "model": "string",
- "region": "string",
- "enabled": true,
- "priority": 0,
- "weight": 0,
- "rate_limit": 0,
- "timeout_seconds": 0,
- "has_api_key": true,
- "settings": { },
- "health": {
- "status": "healthy",
- "message": "string",
- "last_checked": "2019-08-24T14:15:22Z"
}
}
}Tests a provider connection by making a simple API call. Returns success status and latency information.
| name required | string Provider name |
| prompt | string Optional test prompt (default is simple greeting) |
| model | string Optional model to test with |
{- "prompt": "Say hello in one word.",
- "model": "string"
}{- "success": true,
- "provider": "openai",
- "latency_ms": 245,
- "response": "Hello!"
}Returns status information for all configured LLM providers. Includes enabled status, configuration summary, and last health check.
{- "providers": [
- {
- "name": "openai-primary",
- "type": "openai",
- "enabled": true,
- "healthy": true,
- "last_check": "2025-01-03T10:30:00Z",
- "models_count": 5
}, - {
- "name": "anthropic-backup",
- "type": "anthropic",
- "enabled": true,
- "healthy": true,
- "last_check": "2025-01-03T10:30:00Z",
- "models_count": 3
}
]
}Update LLM provider routing weights. Weights are integers representing relative priority.
required | object Provider name to weight mapping | ||
| |||
{- "weights": {
- "property1": 0,
- "property2": 0
}
}{- "weights": {
- "openai": 100,
- "anthropic": 80,
- "bedrock": 60
}
}Returns a paginated list of policies with filtering support. Use this for policy management in the Customer Portal.
| type | string Enum: "static" "dynamic" Filter by policy type |
| enabled | boolean Filter by enabled status |
| search | string Search in name and description |
| page | integer Default: 1 |
| page_size | integer <= 100 Default: 20 |
| sort_by | string Enum: "name" "created_at" "updated_at" "priority" |
| sort_dir | string Default: "asc" Enum: "asc" "desc" |
| X-Tenant-ID required | string |
{- "policies": [
- {
- "id": "497f6eca-6276-4993-bfeb-53cbbbba6f08",
- "policy_id": "string",
- "name": "string",
- "description": "string",
- "type": "static",
- "category": "string",
- "tier": "system",
- "pattern": "string",
- "action": "block",
- "severity": "critical",
- "priority": 0,
- "enabled": true,
- "conditions": [
- { }
], - "actions": [
- { }
], - "version": 0,
- "tenant_id": "string",
- "organization_id": "string",
- "created_by": "string",
- "created_at": "2019-08-24T14:15:22Z",
- "updated_by": "string",
- "updated_at": "2019-08-24T14:15:22Z"
}
], - "pagination": {
- "page": 0,
- "page_size": 0,
- "total_items": 0,
- "total_pages": 0
}
}Create a new policy
| X-Tenant-ID required | string |
| X-User-ID | string |
| name required | string |
| description | string |
| type required | string Enum: "static" "dynamic" |
| category | string |
| tier | string Default: "tenant" Enum: "organization" "tenant" |
| pattern | string Required for static policies |
| action | string Enum: "block" "require_approval" "redact" "warn" "log" |
| severity | string Enum: "critical" "high" "medium" "low" |
| priority | integer Default: 100 |
| enabled | boolean Default: true |
| conditions | Array of objects Required for dynamic policies |
| actions | Array of objects Required for dynamic policies |
{- "name": "string",
- "description": "string",
- "type": "static",
- "category": "string",
- "tier": "organization",
- "pattern": "string",
- "action": "block",
- "severity": "critical",
- "priority": 100,
- "enabled": true,
- "conditions": [
- { }
], - "actions": [
- { }
]
}{- "id": "497f6eca-6276-4993-bfeb-53cbbbba6f08",
- "policy_id": "string",
- "name": "string",
- "description": "string",
- "type": "static",
- "category": "string",
- "tier": "system",
- "pattern": "string",
- "action": "block",
- "severity": "critical",
- "priority": 0,
- "enabled": true,
- "conditions": [
- { }
], - "actions": [
- { }
], - "version": 0,
- "tenant_id": "string",
- "organization_id": "string",
- "created_by": "string",
- "created_at": "2019-08-24T14:15:22Z",
- "updated_by": "string",
- "updated_at": "2019-08-24T14:15:22Z"
}Bulk import policies from JSON or YAML format. Supports create or update semantics based on policy_id.
| X-Tenant-ID required | string |
| X-User-ID | string |
required | Array of objects (CreatePolicyRequest) |
| mode | string Default: "upsert" Enum: "create" "upsert" Import mode - create only or upsert (create or update) |
{- "policies": [
- {
- "name": "string",
- "description": "string",
- "type": "static",
- "category": "string",
- "tier": "organization",
- "pattern": "string",
- "action": "block",
- "severity": "critical",
- "priority": 100,
- "enabled": true,
- "conditions": [
- { }
], - "actions": [
- { }
]
}
], - "mode": "create"
}{- "created": 0,
- "updated": 0,
- "failed": 0,
- "errors": [
- "string"
]
}Export all policies in JSON or YAML format for backup or migration
| format | string Default: "json" Enum: "json" "yaml" Export format |
| type | string Default: "all" Enum: "static" "dynamic" "all" Filter by policy type |
| X-Tenant-ID required | string |
{- "version": "1.0",
- "exported_at": "2019-08-24T14:15:22Z",
- "policies": [
- {
- "id": "497f6eca-6276-4993-bfeb-53cbbbba6f08",
- "policy_id": "string",
- "name": "string",
- "description": "string",
- "type": "static",
- "category": "string",
- "tier": "system",
- "pattern": "string",
- "action": "block",
- "severity": "critical",
- "priority": 0,
- "enabled": true,
- "conditions": [
- { }
], - "actions": [
- { }
], - "version": 0,
- "tenant_id": "string",
- "organization_id": "string",
- "created_by": "string",
- "created_at": "2019-08-24T14:15:22Z",
- "updated_by": "string",
- "updated_at": "2019-08-24T14:15:22Z"
}
]
}| id required | string <uuid> |
| X-Tenant-ID required | string |
{- "id": "497f6eca-6276-4993-bfeb-53cbbbba6f08",
- "policy_id": "string",
- "name": "string",
- "description": "string",
- "type": "static",
- "category": "string",
- "tier": "system",
- "pattern": "string",
- "action": "block",
- "severity": "critical",
- "priority": 0,
- "enabled": true,
- "conditions": [
- { }
], - "actions": [
- { }
], - "version": 0,
- "tenant_id": "string",
- "organization_id": "string",
- "created_by": "string",
- "created_at": "2019-08-24T14:15:22Z",
- "updated_by": "string",
- "updated_at": "2019-08-24T14:15:22Z"
}| id required | string <uuid> |
| X-Tenant-ID required | string |
| X-User-ID | string |
| name | string |
| description | string |
| pattern | string |
| action | string Enum: "block" "require_approval" "redact" "warn" "log" |
| severity | string Enum: "critical" "high" "medium" "low" |
| priority | integer |
| enabled | boolean |
| conditions | Array of objects |
| actions | Array of objects |
{- "name": "string",
- "description": "string",
- "pattern": "string",
- "action": "block",
- "severity": "critical",
- "priority": 0,
- "enabled": true,
- "conditions": [
- { }
], - "actions": [
- { }
]
}{- "id": "497f6eca-6276-4993-bfeb-53cbbbba6f08",
- "policy_id": "string",
- "name": "string",
- "description": "string",
- "type": "static",
- "category": "string",
- "tier": "system",
- "pattern": "string",
- "action": "block",
- "severity": "critical",
- "priority": 0,
- "enabled": true,
- "conditions": [
- { }
], - "actions": [
- { }
], - "version": 0,
- "tenant_id": "string",
- "organization_id": "string",
- "created_by": "string",
- "created_at": "2019-08-24T14:15:22Z",
- "updated_by": "string",
- "updated_at": "2019-08-24T14:15:22Z"
}Test how a specific policy evaluates against sample input
| id required | string <uuid> |
| X-Tenant-ID required | string |
| query required | string Input to evaluate |
| context | object Additional context |
{- "query": "string",
- "context": { }
}{- "allowed": true,
- "applied_policies": [
- "string"
], - "risk_score": 1,
- "required_actions": [
- "string"
], - "processing_time_ms": 0,
- "database_accessed": true
}Returns version history for a policy. Community edition limited to 5 versions.
| id required | string <uuid> |
| X-Tenant-ID required | string |
{- "policy_id": "string",
- "versions": [
- {
- "version": 0,
- "snapshot": { },
- "change_type": "string",
- "changed_by": "string",
- "changed_at": "2019-08-24T14:15:22Z"
}
], - "count": 0
}Returns the active dynamic policies visible to the CALLING tenant: the tenant's own policies plus the shared global/default baseline. Policies owned by other tenants are never returned in the same response, and requests without a resolvable tenant are rejected with 401 (fail closed).
The tenant scope is read from the X-Tenant-ID header. When the
request arrives through the AxonFlow Agent, that header is set from
the validated credential and overwrites any client-supplied value,
so the caller cannot choose the scope. The orchestrator itself does
not authenticate this route, so a caller with direct network access
to the orchestrator can name a tenant — deploy the orchestrator on a
private network behind the Agent.
[- {
- "id": "pol_001",
- "name": "High Risk Content Filter",
- "description": "Block requests with high risk scores",
- "enabled": true,
- "conditions": [
- {
- "field": "risk_score",
- "operator": ">",
- "value": 0.8
}
], - "actions": [
- {
- "type": "block",
- "reason": "High risk content detected"
}
]
}, - {
- "id": "pol_002",
- "name": "Rate Limit Premium Users",
- "description": "Apply premium rate limits",
- "enabled": true,
- "conditions": [
- {
- "field": "user.role",
- "operator": "==",
- "value": "premium"
}
], - "actions": [
- {
- "type": "rate_limit",
- "limit": 10000
}
]
}
]Test how dynamic policies evaluate a sample request
| query required | string |
object (UserContext) | |
| request_type | string |
{- "query": "SELECT * FROM customers WHERE credit_score < 500",
- "request_type": "sql"
}{- "allowed": true,
- "applied_policies": [
- "sql-injection-filter",
- "pii-protection"
], - "risk_score": 0.25,
- "required_actions": [ ],
- "processing_time_ms": 3
}Execute a defined workflow with input parameters
required | object (Workflow) |
object | |
object (UserContext) |
{- "workflow": {
- "metadata": {
- "name": "data-analysis-workflow",
- "description": "Analyze sales data"
}, - "spec": {
- "steps": [
- {
- "name": "fetch_data",
- "type": "mcp_query",
- "connector": "postgres",
- "query": "SELECT * FROM sales"
}, - {
- "name": "analyze",
- "type": "llm",
- "prompt": "Analyze the sales data: {{fetch_data.result}}"
}
]
}
}, - "input": {
- "start_date": "2025-01-01",
- "end_date": "2025-01-15"
},
}{- "id": "string",
- "workflow_name": "string",
- "status": "pending",
- "started_at": "2019-08-24T14:15:22Z",
- "completed_at": "2019-08-24T14:15:22Z",
- "steps": [
- {
- "name": "string",
- "status": "string",
- "process_time": "string"
}
], - "output": { }
}Get details of a specific workflow execution
| id required | string Example: exec_abc123 Workflow execution ID |
{- "id": "string",
- "workflow_name": "string",
- "status": "pending",
- "started_at": "2019-08-24T14:15:22Z",
- "completed_at": "2019-08-24T14:15:22Z",
- "steps": [
- {
- "name": "string",
- "status": "string",
- "process_time": "string"
}
], - "output": { }
}List recent workflow executions
| limit | integer [ 1 .. 100 ] Default: 10 Maximum number of executions to return |
{- "executions": [
- {
- "id": "string",
- "workflow_name": "string",
- "status": "pending",
- "started_at": "2019-08-24T14:15:22Z",
- "completed_at": "2019-08-24T14:15:22Z",
- "steps": [
- {
- "name": "string",
- "status": "string",
- "process_time": "string"
}
], - "output": { }
}
], - "count": 0
}Get workflow executions for a specific tenant
| tenant_id required | string Tenant identifier |
{- "tenant_id": "string",
- "count": 0,
- "executions": [
- {
- "id": "string",
- "workflow_name": "string",
- "status": "pending",
- "started_at": "2019-08-24T14:15:22Z",
- "completed_at": "2019-08-24T14:15:22Z",
- "steps": [
- {
- "name": "string",
- "status": "string",
- "process_time": "string"
}
], - "output": { }
}
]
}Governance gates for external orchestrators (LangChain, LangGraph, CrewAI). "LangChain runs the workflow. AxonFlow decides when it's allowed to move forward."
Features:
Register a new workflow from an external orchestrator (LangChain, LangGraph, CrewAI). Returns a workflow_id to use for subsequent step gate checks.
| workflow_name required | string Human-readable name for the workflow |
| source | string Default: "external" Enum: "langgraph" "langchain" "crewai" "external" Source orchestrator |
| trace_id | string <= 255 characters External trace ID for correlation with Langsmith, Datadog, or OpenTelemetry |
object Additional workflow metadata |
{- "workflow_name": "code-review-pipeline",
- "source": "langgraph",
- "metadata": {
- "environment": "production",
- "team": "engineering"
}
}{- "workflow_id": "wf_abc123",
- "workflow_name": "code-review-pipeline",
- "status": "in_progress",
- "started_at": "2026-01-17T10:00:00Z"
}List workflows with optional filters
| status | string Enum: "in_progress" "completed" "aborted" "failed" Filter by status |
| source | string Enum: "langgraph" "langchain" "crewai" "external" Filter by source |
| limit | integer [ 1 .. 100 ] Default: 50 Maximum number of workflows to return |
| offset | integer Default: 0 Number of workflows to skip |
| trace_id | string Filter by external trace ID |
{- "workflows": [
- {
- "workflow_id": "string",
- "workflow_name": "string",
- "source": "langgraph",
- "status": "in_progress",
- "trace_id": "string",
- "current_step_index": 0,
- "total_steps": 0,
- "started_at": "2019-08-24T14:15:22Z",
- "completed_at": "2019-08-24T14:15:22Z",
- "metadata": { },
- "steps": [
- {
- "step_id": "string",
- "step_index": 0,
- "step_name": "string",
- "step_type": "llm_call",
- "decision": "allow",
- "approval_status": "pending",
- "gate_checked_at": "2019-08-24T14:15:22Z",
- "approved_by": "string",
- "completed_at": "2019-08-24T14:15:22Z",
- "decision_reason": "string"
}
]
}
], - "total": 0,
- "limit": 0,
- "offset": 0
}Get the current status of a workflow including all step decisions
| workflow_id required | string Example: wf_abc123 Workflow ID |
{- "workflow_id": "string",
- "workflow_name": "string",
- "source": "langgraph",
- "status": "in_progress",
- "trace_id": "string",
- "current_step_index": 0,
- "total_steps": 0,
- "started_at": "2019-08-24T14:15:22Z",
- "completed_at": "2019-08-24T14:15:22Z",
- "metadata": { },
- "steps": [
- {
- "step_id": "string",
- "step_index": 0,
- "step_name": "string",
- "step_type": "llm_call",
- "decision": "allow",
- "approval_status": "pending",
- "gate_checked_at": "2019-08-24T14:15:22Z",
- "approved_by": "string",
- "completed_at": "2019-08-24T14:15:22Z",
- "decision_reason": "string"
}
]
}Check if a workflow step is allowed to proceed. Returns a decision (allow/block/require_approval) based on policy evaluation.
Call this BEFORE executing each step in your external orchestrator.
The response always includes a retry_context block (Issue #1673 Phase 1)
carrying first-class retry state: gate count, prior completion status,
first/last attempt timestamps, last decision, and the idempotency_key.
Callers that need to unambiguously detect retries or uncertain-territory
scenarios should prefer retry_context over the deprecated cached
boolean.
| workflow_id required | string Example: wf_abc123 Workflow ID |
| step_id required | string Example: step-1 Step ID (unique within workflow) |
| include_prior_output | boolean Default: false Example: include_prior_output=true Opt-in (Issue #1673 Phase 1) — when |
| step_name | string Human-readable step name (optional) |
| step_type required | string Enum: "llm_call" "tool_call" "connector_call" "human_task" Type of step |
object Input data for the step (for policy evaluation) | |
| model | string LLM model being used |
| provider | string LLM provider being used |
| tokens_in | integer Estimated input tokens for the step (used at gate time) |
| tokens_out | integer Estimated output tokens for the step (used at gate time) |
| cost_usd | number <double> Estimated cost in USD for the step (used at gate time) |
object (ToolContext) Tool-level context for per-tool governance within tool_call steps. | |
| retry_policy | string Default: "idempotent" Enum: "idempotent" "reevaluate" Controls behavior on repeated calls for the same (workflow_id, step_id). Default ("idempotent"): return cached decision from prior evaluation. "reevaluate": force fresh policy evaluation regardless of prior decision. |
| idempotency_key | string <= 255 characters Optional caller-supplied opaque business-level key (Issue #1673 Phase 2).
Recorded on the first /gate call that sets it; immutable for the step's
lifetime. Subsequent /gate and /complete calls MUST pass the same key
or receive 409 IDEMPOTENCY_KEY_MISMATCH. Use business-meaningful values
like |
{- "step_name": "Generate Code",
- "step_type": "llm_call",
- "model": "gpt-4",
- "provider": "openai",
- "step_input": {
- "prompt": "Write a function to sort a list"
}
}{- "decision": "allow",
- "step_id": "step-1",
- "decision_id": "dec_xyz789"
}Mark a workflow step as completed after successful execution. Request body is optional.
| workflow_id required | string Workflow ID |
| step_id required | string Step ID |
object Output data from the step | |
| tokens_in | integer Actual input tokens consumed by the step (overrides gate-time estimate) |
| tokens_out | integer Actual output tokens produced by the step (overrides gate-time estimate) |
| cost_usd | number <double> Actual cost in USD for the step (overrides gate-time estimate) |
| idempotency_key | string <= 255 characters Optional caller-supplied key (Issue #1673 Phase 2). Must match the key recorded on the step's earlier /gate call. Mismatch returns 409 IDEMPOTENCY_KEY_MISMATCH. |
object Free-form metadata captured at step-completion time — useful for audit context the gate-time data didn't have (post-execution latency from a downstream service, retry attempt counters, etc.). Treat as opaque on the client. |
{- "output": {
- "code": "def sort_list(items): return sorted(items)"
}, - "tokens_in": 150,
- "tokens_out": 45,
- "cost_usd": 0.0023
}{- "success": false,
- "error": "Resource not found"
}Marks the workflow as failed with an optional reason (defaults to
Failed when the body is empty or omitted). Tenant/org scoping comes
from the X-Tenant-ID / X-Org-ID headers. Failing a workflow that
is already in a terminal state returns 409.
| workflow_id required | string Workflow ID |
| reason | string Reason for the failure (defaults to "Failed") |
{- "reason": "Downstream connector unrecoverable"
}{- "workflow_id": "string",
- "status": "failed",
- "message": "Workflow marked as failed",
- "reason": "string"
}Abort the workflow with an optional reason
| workflow_id required | string Workflow ID |
| reason | string Reason for aborting |
{- "reason": "Step blocked by policy"
}{- "success": false,
- "error": "Resource not found"
}Returns all checkpoints for a workflow, ordered by step_index. Checkpoints are created automatically at each step gate evaluation. Available in all tiers (Community, Evaluation, Enterprise).
| workflow_id required | string |
{- "checkpoints": [
- {
- "id": 0,
- "workflow_id": "string",
- "step_id": "string",
- "step_index": 0,
- "step_type": "string",
- "checkpoint_type": "step_gate",
- "gate_decision": "allow",
- "gate_reason": "string",
- "is_resumable": true,
- "resume_count": 0,
- "created_at": "2019-08-24T14:15:22Z"
}
], - "workflow_id": "string"
}Re-evaluates the step gate at the last resumable checkpoint with current policies. The step gate uses retry_policy=reevaluate internally.
| workflow_id required | string |
{- "workflow_id": "string",
- "resumed_from_checkpoint": "string",
- "resumed_from_index": 0,
- "new_decision": "allow",
- "decision_source": "string",
- "resume_count": 0,
- "message": "string"
}Re-evaluates the step gate at a specific checkpoint with current policies. Enterprise only.
| workflow_id required | string |
| checkpoint_id required | integer <int64> |
{- "workflow_id": "string",
- "resumed_from_checkpoint": "string",
- "resumed_from_index": 0,
- "new_decision": "allow",
- "decision_source": "string",
- "resume_count": 0,
- "message": "string"
}Approve a workflow step that is waiting for human approval. This allows the workflow to proceed past the approval gate.
| workflowId required | string Example: wf_abc123 Workflow ID |
| stepId required | string Example: step-2 Step ID awaiting approval |
| comment required | string >= 10 characters Audit justification for approving the step (minimum 10 characters after trimming) |
| approved_by | string User ID of the approver |
{- "comment": "Approved after reviewing output",
- "approved_by": "user-456"
}{- "workflow_id": "wf_abc123",
- "step_id": "step-2",
- "status": "approved",
- "decision": "allow",
- "reason": "Approved: High-value transfer requires oversight",
- "approval_status": "approved",
- "approval_id": "318a270f-7b42-5c56-a191-8dbd1bf2e1e4",
- "approved_at": "2026-04-22T10:05:00Z",
- "policies_matched": [
- {
- "policy_id": "high-value-wire-oversight",
- "policy_name": "High-Value Wire Transfer Oversight",
- "action": "require_approval"
}
], - "retry_context": {
- "gate_count": 1,
- "completion_count": 0,
- "prior_completion_status": "none",
- "prior_output_available": false,
- "prior_output": null,
- "prior_completion_at": null,
- "idempotency_key": "payment-intent-123",
- "last_decision": "require_approval",
- "first_attempt_at": "2026-04-22T10:00:00Z",
- "last_attempt_at": "2026-04-22T10:00:00Z"
}, - "message": "Step approved"
}Reject a workflow step that is waiting for human approval. This blocks the step and may abort the workflow depending on configuration.
| workflowId required | string Example: wf_abc123 Workflow ID |
| stepId required | string Example: step-2 Step ID awaiting approval |
| reason required | string >= 10 characters Audit justification for rejecting the step (minimum 10 characters after trimming) |
| rejected_by | string User ID of the rejector |
{- "reason": "Output contains PII that was not redacted",
- "rejected_by": "user-456"
}{- "workflow_id": "wf_abc123",
- "step_id": "step-2",
- "status": "rejected",
- "decision": "block",
- "reason": "Rejected: Output contains PII that was not redacted",
- "approval_status": "rejected",
- "approval_id": "318a270f-7b42-5c56-a191-8dbd1bf2e1e4",
- "rejected_at": "2026-04-22T10:05:00Z",
- "policies_matched": [
- {
- "policy_id": "pii-output-redaction",
- "policy_name": "PII Redaction Required",
- "action": "require_approval"
}
], - "retry_context": {
- "gate_count": 1,
- "completion_count": 0,
- "prior_completion_status": "none",
- "prior_output_available": false,
- "prior_output": null,
- "prior_completion_at": null,
- "idempotency_key": "",
- "last_decision": "require_approval",
- "first_attempt_at": "2026-04-22T10:00:00Z",
- "last_attempt_at": "2026-04-22T10:00:00Z"
}, - "message": "Step rejected, workflow aborted"
}List workflow steps currently awaiting human approval for the caller's
tenant (all planes). Cross-reference the MAP-plane equivalent at
/api/v1/plans/approvals/pending, which scopes to MAP-backed
workflows and populates plan_id on every entry.
Available on Evaluation+ licenses. Community without an Evaluation license has no approval queue to list.
| limit | integer [ 1 .. 100 ] Default: 20 Maximum number of results to return |
{- "pending_approvals": [
- {
- "workflow_id": "wf_abc123",
- "workflow_name": "code-review-pipeline",
- "step_id": "step-2",
- "step_index": 1,
- "step_name": "Deploy to Production",
- "step_type": "action",
- "decision": "require_approval",
- "decision_reason": "Human approval required for deployment steps",
- "approval_status": "pending",
- "created_at": "2026-04-22T10:00:00Z"
}
], - "count": 1
}List steps currently awaiting human approval for MAP-backed workflows —
workflows whose metadata carries a plan_id (MAP confirm / step mode).
Every returned entry has plan_id populated; this is the intentional
asymmetry with the WCP-plane listing at
/api/v1/workflows/approvals/pending, mirroring the approve/reject
asymmetry established in Issue #1677 / ADR-046.
Reviewer integrators that need to render plan context can read
plan_id directly without a second lookup; clients that want a
plane-neutral view can use /api/v1/hitl/queue instead.
Available on Evaluation+ licenses (same tier gate as the MAP
/steps/{step_id}/approve and /steps/{step_id}/reject endpoints).
| plan_id | string Filter to a single plan_id — returns only steps waiting on that plan. |
| limit | integer [ 1 .. 100 ] Default: 20 Maximum number of results to return |
{- "pending_approvals": [
- {
- "workflow_id": "wf_map_abc",
- "workflow_name": "map-confirm-plan-abc123",
- "plan_id": "plan-abc123",
- "step_id": "step_0_analyze",
- "step_index": 0,
- "step_name": "Analyze customer transaction",
- "step_type": "tool_call",
- "decision": "require_approval",
- "decision_reason": "High-value transaction requires review",
- "approval_status": "pending",
- "created_at": "2026-04-22T10:00:00Z"
}
], - "count": 1
}Get detailed information about a connector
| id required | string Connector identifier |
{- "id": "string",
- "name": "string",
- "type": "string",
- "description": "string",
- "version": "string",
- "capabilities": [
- "string"
], - "installed": true,
- "healthy": true
}Search audit logs by various criteria. The tenant scope is always forced
from the X-Tenant-ID header (the body cannot override it); requests
without the header are rejected with 401. user_email and client_id
are case-insensitive partial (ILIKE substring) matches. The search
start time is clamped to the tenant's tier-based retention window.
Role-scoped reads (#2922): the caller's read scope is resolved
server-side. admin/owner read the full tenant trail; every other
role — and any caller without a validated per-user identity — reads
only their own user_email rows (fail-closed). A non-admin's
user_email filter can only narrow the result to their own identity,
never widen it to another user's rows. Callers without any resolvable
identity receive an empty entries array. The role/scope is trusted
only over the internal agent→orchestrator proxy-auth channel, never a
client-forwarded header.
Single-operator deployments (#3060): DEPLOYMENT_MODE=community
reads tenant-wide unconditionally, and DEPLOYMENT_MODE=community-saas
reads tenant-wide for requests that arrived over the agent gateway
(proven by the internal proxy-auth token) — in that mode the
organization, tenant and credential are one cs_<uuid>, so tenant-wide
is that single evaluator's own data. A community-saas request that
reaches the orchestrator directly stays least-privilege. Read scope is
a separate axis from administrative authority: a community-saas caller
reads tenant-wide here and is still denied (403) the whole-tenant
compliance exports and the cost/usage/execution family.
Method: this endpoint is POST-only (its criteria are a JSON
body). A GET returns 405 with Allow: POST, OPTIONS.
| X-Tenant-ID required | string Example: travel-us Tenant identifier scoping the request. The AxonFlow Agent gateway sets this header after authentication; the orchestrator fails closed when it is absent (401 on audit/decision endpoints, 400 on others — see each operation). Clients cannot widen their scope through it: handlers force the tenant filter from this header, never from the request body. |
| user_email | string Case-insensitive partial (ILIKE substring) match |
| client_id | string Case-insensitive partial (ILIKE substring) match |
| start_time | string <date-time> Window lower bound; clamped to the tenant's tier-based retention cutoff when earlier (or when omitted) |
| end_time | string <date-time> |
| action | string Filter by policy decision. The value is normalized to its canonical verdict (allowed, blocked, redacted, needs_approval, error) and expanded to every historical DB spelling of that verdict, so it matches both current and legacy rows. |
| session_id | string Exact match on the first-class session_id column — used to drill into a session-summary bucket's raw events (#2857). |
| limit | integer Default: 100 |
| offset | integer >= 0 Default: 0 Pagination offset — number of audit-log rows to skip from
the start of the result set. Pair with |
| decision_id | string Filter audit reads to a specific governance decision id
(mints from MCPCheckInputResponse / MCPCheckOutputResponse
etc.). Matches |
| override_id | string Filter to audit entries that recorded an override-used
event for this override id (matches
|
| policy_name | string Filter to audit entries where this policy fired. Matches the
three shapes audit writers store in the policy_details JSONB:
the scalar |
{- "client_id": "analytics-app",
- "start_time": "2025-01-01T00:00:00Z",
- "end_time": "2025-01-15T23:59:59Z",
- "action": "blocked",
- "session_id": "sess-4f6a2c",
- "limit": 100
}{- "entries": [
- {
- "id": "a1b2c3d4",
- "request_id": "req_9f8e7d",
- "timestamp": "2025-01-14T10:30:00Z",
- "tenant_id": "tenant-abc",
- "request_type": "llm_chat",
- "policy_decision": "blocked",
- "session_id": "sess-4f6a2c"
}
], - "total": 235,
- "limit": 100,
- "offset": 0
}Returns aggregated compliance summary statistics for a given date range. Includes total event counts, breakdowns by severity and action type, top triggered policies, and an overall compliance score.
| X-Tenant-ID required | string Example: travel-us Tenant identifier for scoping results. Required to prevent cross-tenant data aggregation. There is no fallback header: the X-Org-ID fallback was removed in v6.2.0, and a request without X-Tenant-ID is rejected with 400. |
| start_time required | string <date-time> Start of date range (RFC3339) |
| end_time required | string <date-time> End of date range (RFC3339, must be after start_time) |
{- "start_time": "2026-01-01T00:00:00Z",
- "end_time": "2026-04-01T00:00:00Z"
}{- "total_events": 1523,
- "by_severity": {
- "info": 1400,
- "warning": 100,
- "critical": 23
}, - "by_action": {
- "llm_call": 1200,
- "tool_call": 300,
- "policy_check": 23
}, - "top_policies": [
- {
- "policy_name": "demo-block-bulk-email",
- "trigger_count": 15,
- "block_count": 15
}, - {
- "policy_name": "pii-detection",
- "trigger_count": 8,
- "block_count": 3
}
], - "compliance_score": 98.5
}Get recent audit logs for a specific tenant. The URL tenant must match
the session tenant carried in the X-Tenant-ID header: a missing header
is rejected with 401 (fail-closed), and a mismatch with 403. Results are
clamped to the tenant's tier-based retention window.
| tenant_id required | string Example: tenant-abc Tenant identifier (must equal the X-Tenant-ID header value) |
| limit | integer [ 1 .. 1000 ] Default: 50 Maximum number of rows to return (1-1000) |
| page_size | integer [ 1 .. 1000 ] Deprecated Deprecated alias for |
| X-Tenant-ID required | string Example: travel-us Tenant identifier scoping the request. The AxonFlow Agent gateway sets this header after authentication; the orchestrator fails closed when it is absent (401 on audit/decision endpoints, 400 on others — see each operation). Clients cannot widen their scope through it: handlers force the tenant filter from this header, never from the request body. |
[- {
- "id": "string",
- "request_id": "string",
- "timestamp": "2019-08-24T14:15:22Z",
- "user_id": 0,
- "user_email": "string",
- "user_role": "string",
- "client_id": "string",
- "tenant_id": "string",
- "org_id": "string",
- "request_type": "string",
- "query": "string",
- "query_hash": "string",
- "policy_decision": "string",
- "policy_details": { },
- "provider": "string",
- "model": "string",
- "response_time_ms": 0,
- "tokens_used": 0,
- "cost": 0.1,
- "redacted_fields": [
- "string"
], - "error_message": "string",
- "response_sample": "string",
- "compliance_flags": [
- "string"
], - "security_metrics": { },
- "decision_id": "string",
- "plane": "string",
- "correlation_id": "string",
- "transfer_basis": "string",
- "data_residency": "string",
- "session_id": "string"
}
]Records a non-LLM tool call (API calls, webhooks, MCP tool executions by external
orchestrators) in the AxonFlow audit trail. Only tool_name is required; all other
fields are optional.
| X-Tenant-ID required | string Tenant identifier (must match the client ID from Basic auth credentials) |
| X-Axonflow-Proxy-Auth required | string Internal-service HMAC token proving the request was routed through the
AxonFlow Agent gateway (derived from |
| Idempotency-Key | string [ 1 .. 256 ] characters ^[A-Za-z0-9_.:\-/]+$ Optional per-request dedup token. When supplied, the platform caches
the response for 24h and returns it byte-for-byte on subsequent
requests carrying the same key + same authenticated tenant. A cache
hit adds an |
| tool_name required | string Name of the tool that was called |
| caller_name | string Which client/integration made this call (e.g. claude_code, codex, cursor, openclaw). Replaces tool_type (#2912), which was misnamed for this purpose — every real caller used it to identify itself, not to describe a property of the tool. |
| tool_type | string Deprecated Deprecated — use caller_name instead. Accepted as a legacy input fallback when caller_name is not supplied. |
| input | object Input data sent to the tool |
| output | object Output data returned by the tool |
| workflow_id | string Associated workflow ID |
| step_id | string Associated workflow step ID |
| user_id | string User who triggered the tool call |
| duration_ms | integer <int64> Duration of the tool call in milliseconds |
| policies_applied | Array of strings List of policy names applied during the tool call |
| success | boolean Whether the tool call succeeded |
| error_message | string Error message if the tool call failed |
{- "tool_name": "getUserInfo",
- "caller_name": "claude_code",
- "input": { },
- "output": { },
- "workflow_id": "wf_abc123",
- "step_id": "step-3",
- "duration_ms": 45,
- "policies_applied": [
- "pii_check",
- "data_access"
], - "success": true,
- "error_message": ""
}{- "audit_id": "audit_1710432000_abcd1234",
- "status": "recorded",
- "timestamp": "2026-03-14T12:00:00Z"
}Exports audit logs as a downloadable file. Filters mirror
/api/v1/audit/search (same ILIKE user/client matching, canonical
action expansion, JSONB policy filters and date range), so an export
always reconciles with the on-screen search for the same filters.
Tenant scope is forced from the X-Tenant-ID header.
The export is capped at 50,000 rows; when the cap is hit the
response carries the X-Audit-Export-Truncated: true and
X-Audit-Export-Row-Cap headers so callers can warn that the file is
partial. Free-text CSV cells are formula-escaped (leading =, +,
-, @, tab or CR is prefixed with ') to neutralize spreadsheet
formula injection.
| format | string Default: "json" Enum: "csv" "json" Export format. Defaults to |
| X-Tenant-ID required | string Example: travel-us Tenant identifier scoping the request. The AxonFlow Agent gateway sets this header after authentication; the orchestrator fails closed when it is absent (401 on audit/decision endpoints, 400 on others — see each operation). Clients cannot widen their scope through it: handlers force the tenant filter from this header, never from the request body. |
Optional filters. An empty body exports the whole tenant window (within the tier retention floor). A present-but-malformed body is a 400.
| user_email | string Case-insensitive partial (ILIKE substring) match |
| client_id | string Case-insensitive partial (ILIKE substring) match |
| action | string Canonical verdict filter (allowed, blocked, redacted, needs_approval, error); expanded to all historical DB spellings of that verdict. |
| session_id | string Exact match on the first-class session_id column |
| decision_id | string Matches policy_details->>'decision_id' |
| policy_name | string Same three-shape policy_details match as /api/v1/audit/search |
| override_id | string Matches policy_details->>'override_id' |
| start_time | string <date-time> |
| end_time | string <date-time> |
{- "action": "blocked",
- "start_time": "2026-06-01T00:00:00Z",
- "end_time": "2026-06-30T23:59:59Z"
}{- "entries": [
- {
- "id": "string",
- "request_id": "string",
- "timestamp": "2019-08-24T14:15:22Z",
- "user_id": 0,
- "user_email": "string",
- "user_role": "string",
- "client_id": "string",
- "tenant_id": "string",
- "org_id": "string",
- "request_type": "string",
- "query": "string",
- "query_hash": "string",
- "policy_decision": "string",
- "policy_details": { },
- "provider": "string",
- "model": "string",
- "response_time_ms": 0,
- "tokens_used": 0,
- "cost": 0.1,
- "redacted_fields": [
- "string"
], - "error_message": "string",
- "response_sample": "string",
- "compliance_flags": [
- "string"
], - "security_metrics": { },
- "decision_id": "string",
- "plane": "string",
- "correlation_id": "string",
- "transfer_basis": "string",
- "data_residency": "string",
- "session_id": "string"
}
], - "count": 0,
- "truncated": true,
- "row_cap": 50000
}Aggregates audit logs for a window into per-action counts, average
latency, and top policies, tenant-scoped and optionally filtered by
user and a single canonical action. Counts reconcile with
/api/v1/audit/search for the same filters.
| X-Tenant-ID required | string Example: travel-us Tenant identifier scoping the request. The AxonFlow Agent gateway sets this header after authentication; the orchestrator fails closed when it is absent (401 on audit/decision endpoints, 400 on others — see each operation). Clients cannot widen their scope through it: handlers force the tenant filter from this header, never from the request body. |
| start_time required | string <date-time> Window start (RFC3339) |
| end_time required | string <date-time> Window end (RFC3339, must be after start_time; range at most 1 year) |
| user_email | string Optional case-insensitive partial match |
| action | string Optional single canonical action filter |
{- "start_time": "2026-06-01T00:00:00Z",
- "end_time": "2026-06-30T23:59:59Z"
}{- "tenant_id": "tenant-abc",
- "start_time": "2026-06-01T00:00:00Z",
- "end_time": "2026-06-30T23:59:59Z",
- "total": 1523,
- "by_action": {
- "allowed": 1400,
- "blocked": 100,
- "redacted": 20,
- "needs_approval": 3,
- "error": 0
}, - "avg_latency_ms": 245.7,
- "top_policies": [
- {
- "policy_name": "pii-detection",
- "trigger_count": 88,
- "block_count": 35
}
]
}Enterprise — session-level usage reporting (#2759). The Community build mounts the same route but returns 501 Not Implemented.
Buckets audit logs into per-session aggregates for the date window:
a bucket is per-session when session_id is present on its rows,
otherwise rows without a session id fall back to a per-user-day
bucket (the day field is set instead of session_id). Buckets are
capped at bucket_limit (most-recent activity first); truncated is
true when the window held more buckets than the cap — narrow the
window or raise limit. Drill into a bucket's raw events via
POST /api/v1/audit/search with its session_id (#2857).
The window start is clamped to the tenant's tier retention floor,
like /api/v1/audit/search and /api/v1/audit/export.
| start_date required | string <date> Example: start_date=2026-07-01 Window start, calendar day (YYYY-MM-DD) |
| end_date required | string <date> Example: end_date=2026-07-07 Window end, calendar day (YYYY-MM-DD), inclusive |
| user_email | string Case-insensitive partial (ILIKE substring) filter |
| limit | integer >= 1 Default: 200 Caps the number of returned buckets. Default 200. Values above the
server max (1000) are clamped; the effective bound is echoed back
as |
| X-Tenant-ID required | string Example: travel-us Tenant identifier scoping the request. The AxonFlow Agent gateway sets this header after authentication; the orchestrator fails closed when it is absent (401 on audit/decision endpoints, 400 on others — see each operation). Clients cannot widen their scope through it: handlers force the tenant filter from this header, never from the request body. |
{- "tenant_id": "string",
- "user_email": "string",
- "start_date": "2019-08-24",
- "end_date": "2019-08-24",
- "buckets": [
- {
- "session_id": "string",
- "day": "string",
- "user_email": "string",
- "tenant_id": "string",
- "start_time": "2019-08-24T14:15:22Z",
- "end_time": "2019-08-24T14:15:22Z",
- "total": 0,
- "by_action": {
- "property1": 0,
- "property2": 0
}, - "tools": [
- {
- "request_type": "string",
- "count": 0,
- "tokens_used": 0,
- "cost": 0.1,
- "avg_latency_ms": 0.1
}
], - "tokens_used": 0,
- "cost": 0.1,
- "avg_latency_ms": 0.1,
- "usage_metrics": {
- "lines_of_code": 0,
- "active_time_seconds": 0.1,
- "commits": 0,
- "pull_requests": 0,
- "tool_permission_decisions": {
- "accept": 0,
- "reject": 0
}, - "session_count": 0,
- "tokens_used": 0,
- "cache_tokens": 0,
- "cost_usd": 0.1
}
}
], - "bucket_limit": 0,
- "truncated": true
}Returns the full audit entry for the given id, tenant-scoped by the
X-Tenant-ID header. A record that exists but belongs to another
tenant returns 404 (not 403), so the endpoint cannot be used as a
cross-tenant existence oracle. Literal /api/v1/audit/* routes
(search, export, report, session-summary, tenant, tool-call) are
matched before this parameterized path — including GET /api/v1/audit/search, which answers 405 rather than being
swallowed here as an id of "search" (#3060).
Role-scoped reads (#2922): a non-tenant-wide caller may fetch only
their own rows; a record belonging to another user returns the same
404 as a missing one (non-oracle). See
POST /api/v1/audit/search for the deployment-mode carve-outs.
| id required | string Audit entry id |
| X-Tenant-ID required | string Example: travel-us Tenant identifier scoping the request. The AxonFlow Agent gateway sets this header after authentication; the orchestrator fails closed when it is absent (401 on audit/decision endpoints, 400 on others — see each operation). Clients cannot widen their scope through it: handlers force the tenant filter from this header, never from the request body. |
{- "id": "string",
- "request_id": "string",
- "timestamp": "2019-08-24T14:15:22Z",
- "user_id": 0,
- "user_email": "string",
- "user_role": "string",
- "client_id": "string",
- "tenant_id": "string",
- "org_id": "string",
- "request_type": "string",
- "query": "string",
- "query_hash": "string",
- "policy_decision": "string",
- "policy_details": { },
- "provider": "string",
- "model": "string",
- "response_time_ms": 0,
- "tokens_used": 0,
- "cost": 0.1,
- "redacted_fields": [
- "string"
], - "error_message": "string",
- "response_sample": "string",
- "compliance_flags": [
- "string"
], - "security_metrics": { },
- "decision_id": "string",
- "plane": "string",
- "correlation_id": "string",
- "transfer_basis": "string",
- "data_residency": "string",
- "session_id": "string"
}SEBI AI/ML Guidelines compliance and DPDP Act 2023 audit exports. Enterprise feature for Indian financial services compliance.
Returns a comprehensive SEBI compliance dashboard including:
Enterprise Feature: Available only for Indian financial services deployments.
{- "framework": "SEBI_DPDP_COMBINED",
- "overall_score": 85,
- "overall_status": "COMPLIANT",
- "last_audit_export": "2024-12-01T10:00:00Z",
- "retention_status": {
- "org_id": 123,
- "framework": "SEBI_AI_ML",
- "compliance_status": "COMPLIANT"
}, - "violations_summary": {
- "total": 142,
- "by_severity": {
- "critical": 2,
- "high": 15,
- "medium": 45,
- "low": 80
}, - "trend": "improving"
}, - "pii_summary": {
- "total_detections": 5420,
- "total_redactions": 5350,
- "redaction_rate_percent": 98.7
}, - "hitl_reviews_pending": 3
}Export audit data for SEBI regulatory submission. Supports:
Large exports are processed asynchronously. Poll the export status endpoint to check completion and get the download URL.
5-Year Retention: Per SEBI AI/ML Guidelines, all audit data is retained for minimum 5 years (1825 days).
| start_date required | string <date-time> Start of export period (inclusive) |
| end_date required | string <date-time> End of export period (inclusive) |
| data_types | Array of strings (SEBIAuditDataType) Items Enum: "policy_violations" "llm_calls" "decision_chain" "hitl_oversight" "pii_redactions" "all" Types of audit data to export (defaults to all) |
| format | string (SEBIExportFormat) Enum: "json" "csv" "xml" Export output format |
| framework | string (SEBIComplianceFramework) Enum: "SEBI_AI_ML" "DPDP_ACT_2023" "SEBI_DPDP_COMBINED" SEBI compliance framework identifier |
| include_archived | boolean Default: false Include records from cold storage |
| redact_pii | boolean Default: false Redact PII in export (for external auditors) |
object (SEBIAuditExportFilters) Optional filters for audit exports |
{- "start_date": "2024-01-01T00:00:00Z",
- "end_date": "2024-12-31T23:59:59Z",
- "data_types": [
- "policy_violations",
- "llm_calls",
- "pii_redactions"
], - "format": "json",
- "framework": "SEBI_DPDP_COMBINED",
- "redact_pii": false
}{- "export_id": "exp_abc123",
- "status": "processing",
- "framework": "SEBI_DPDP_COMBINED",
- "metadata": {
- "export_version": "1.0",
- "generated_by": "axonflow-orchestrator",
- "org_id": 123,
- "retention_days": 1825
}
}Get the status of an asynchronous SEBI audit export. When status is "completed", the download_url will be provided.
| export_id required | string Example: exp_abc123 Export ID from the export request |
{- "export_id": "exp_abc123",
- "status": "completed",
- "framework": "SEBI_DPDP_COMBINED",
- "download_url": "/api/v1/sebi/audit/export/exp_abc123/download",
- "expires_at": "2024-12-08T14:00:00Z",
- "summary": {
- "total_records": 15420,
- "compliance_score": 85.5
}
}Get the 5-year retention compliance status for all audit data types.
SEBI AI/ML Guidelines require:
This endpoint reports compliance status for each data type.
{- "org_id": 123,
- "framework": "SEBI_AI_ML",
- "compliance_status": "COMPLIANT",
- "status": [
- {
- "data_type": "policy_violations",
- "retention_days": 1825,
- "total_records": 15420,
- "oldest_record": "2020-01-15T10:30:00Z",
- "compliance_status": "COMPLIANT"
}, - {
- "data_type": "llm_calls",
- "retention_days": 1825,
- "total_records": 250000,
- "oldest_record": "2020-06-01T08:00:00Z",
- "compliance_status": "COMPLIANT"
}
]
}Validate organization readiness for SEBI regulatory audit.
Checks include:
Returns a score (0-100) and actionable recommendations.
{- "ready": true,
- "score": 85,
- "checks": [
- {
- "name": "Retention Configuration",
- "status": "pass"
}, - {
- "name": "PII Detection Policies",
- "status": "pass"
}, - {
- "name": "Human Oversight",
- "status": "pass"
}, - {
- "name": "Decision Chain Tracing",
- "status": "warning",
- "details": "Consider enabling for full audit trail"
}
], - "recommendations": [
- "Enable decision chain tracing to maintain full audit trail of AI decisions"
]
}RBI FREE-AI Framework compliance for Indian banking institutions. Enterprise feature providing AI System Registry, Model Validation, Incident Management, Kill Switch, Board Reporting, and Audit Export.
List all registered AI systems for the organization. Per RBI FREE-AI: All AI systems must be registered with board approval.
| risk_category | string Enum: "low" "medium" "high" |
| deployment_status | string Enum: "development" "sandbox" "canary" "production" "deprecated" |
[- {
- "id": "497f6eca-6276-4993-bfeb-53cbbbba6f08",
- "org_id": "string",
- "system_id": "string",
- "system_name": "string",
- "system_version": "string",
- "description": "string",
- "risk_category": "low",
- "deployment_status": "development",
- "model_type": "string",
- "model_provider": "string",
- "use_case": "string",
- "board_approval_required": true,
- "board_approval_status": "not_required",
- "last_validation_date": "2019-08-24",
- "next_validation_due": "2019-08-24",
- "created_at": "2019-08-24T14:15:22Z",
- "updated_at": "2019-08-24T14:15:22Z"
}
]Register a new AI system in the RBI compliance registry.
| system_id required | string |
| risk_mitigation | object |
| recommendations | Array of strings |
| created_by | string |
| created_at | string <date-time> |
| updated_at | string <date-time> |
| submitted_at | string <date-time> |
| submitted_by | string |
| approved_at | string <date-time> |
| approved_by | string |
| rejected_at | string <date-time> |
| rejected_by | string |
| rejection_reason | string |
{- "system_id": "string",
- "risk_mitigation": { },
- "recommendations": [
- "string"
], - "created_by": "string",
- "created_at": "2019-08-24T14:15:22Z",
- "updated_at": "2019-08-24T14:15:22Z",
- "submitted_at": "2019-08-24T14:15:22Z",
- "submitted_by": "string",
- "approved_at": "2019-08-24T14:15:22Z",
- "approved_by": "string",
- "rejected_at": "2019-08-24T14:15:22Z",
- "rejected_by": "string",
- "rejection_reason": "string"
}{- "id": "497f6eca-6276-4993-bfeb-53cbbbba6f08",
- "org_id": "string",
- "system_id": "string",
- "system_name": "string",
- "system_version": "string",
- "description": "string",
- "risk_category": "low",
- "deployment_status": "development",
- "model_type": "string",
- "model_provider": "string",
- "use_case": "string",
- "board_approval_required": true,
- "board_approval_status": "not_required",
- "last_validation_date": "2019-08-24",
- "next_validation_due": "2019-08-24",
- "created_at": "2019-08-24T14:15:22Z",
- "updated_at": "2019-08-24T14:15:22Z"
}{- "id": "497f6eca-6276-4993-bfeb-53cbbbba6f08",
- "org_id": "string",
- "system_id": "string",
- "system_name": "string",
- "system_version": "string",
- "description": "string",
- "risk_category": "low",
- "deployment_status": "development",
- "model_type": "string",
- "model_provider": "string",
- "use_case": "string",
- "board_approval_required": true,
- "board_approval_status": "not_required",
- "last_validation_date": "2019-08-24",
- "next_validation_due": "2019-08-24",
- "created_at": "2019-08-24T14:15:22Z",
- "updated_at": "2019-08-24T14:15:22Z"
}| id required | string |
| system_id required | string |
| risk_mitigation | object |
| recommendations | Array of strings |
| created_by | string |
| created_at | string <date-time> |
| updated_at | string <date-time> |
| submitted_at | string <date-time> |
| submitted_by | string |
| approved_at | string <date-time> |
| approved_by | string |
| rejected_at | string <date-time> |
| rejected_by | string |
| rejection_reason | string |
{- "system_id": "string",
- "risk_mitigation": { },
- "recommendations": [
- "string"
], - "created_by": "string",
- "created_at": "2019-08-24T14:15:22Z",
- "updated_at": "2019-08-24T14:15:22Z",
- "submitted_at": "2019-08-24T14:15:22Z",
- "submitted_by": "string",
- "approved_at": "2019-08-24T14:15:22Z",
- "approved_by": "string",
- "rejected_at": "2019-08-24T14:15:22Z",
- "rejected_by": "string",
- "rejection_reason": "string"
}List audit exports with retention per RBI FREE-AI requirements.
| limit | integer >= 1 Default: 100 Maximum number of records to return. Defaults vary by endpoint; see per-endpoint description for the cap. |
| offset | integer >= 0 Default: 0 Number of records to skip from the start of the result set.
Pair with |
| X-Org-ID required | string Example: travel-us Organization scope for this request. Stamped by the AxonFlow Agent gateway from the cryptographically validated client credential (Set, not Add, so any client-supplied value is overwritten), so it is not client-selectable and carries no cross-org override capability on this route. The orchestrator fails closed with 401 when it is absent or blank; there is no query-string equivalent. |
{- "exports": [
- {
- "id": "string",
- "org_id": "string",
- "status": "pending",
- "export_type": "full",
- "format": "json",
- "requested_by": "string",
- "purpose": "string",
- "created_at": "2019-08-24T14:15:22Z",
- "completed_at": "2019-08-24T14:15:22Z",
- "download_url": "string",
- "storage_type": "local",
- "storage_key": "string",
- "file_path": "string",
- "file_size_bytes": 0,
- "file_checksum": "string",
- "record_count": 0,
- "error_message": "string"
}
], - "total": 0,
- "limit": 0,
- "offset": 0
}Create a new RBI audit export. Supports full or incremental exports in JSON, CSV, or XML format. When cloud storage is configured, exports are uploaded to S3/GCS/Azure and a presigned download URL is generated.
| X-Org-ID required | string Example: travel-us Organization scope for this request. Stamped by the AxonFlow Agent gateway from the cryptographically validated client credential (Set, not Add, so any client-supplied value is overwritten), so it is not client-selectable and carries no cross-org override capability on this route. The orchestrator fails closed with 401 when it is absent or blank; there is no query-string equivalent. |
| export_type required | string Enum: "full" "incremental" Type of audit export |
| format required | string Enum: "json" "csv" "xml" Export file format |
| start_date | string <date-time> Start of date range (for incremental exports) |
| end_date | string <date-time> End of date range (for incremental exports) |
| requested_by | string User or service requesting the export |
| purpose | string Purpose of the export (for audit trail) |
{- "export_type": "full",
- "format": "json",
- "requested_by": "compliance-officer",
- "purpose": "Quarterly RBI audit"
}{- "export": {
- "id": "string",
- "org_id": "string",
- "status": "pending",
- "export_type": "full",
- "format": "json",
- "requested_by": "string",
- "purpose": "string",
- "created_at": "2019-08-24T14:15:22Z",
- "completed_at": "2019-08-24T14:15:22Z",
- "download_url": "string",
- "storage_type": "local",
- "storage_key": "string",
- "file_path": "string",
- "file_size_bytes": 0,
- "file_checksum": "string",
- "record_count": 0,
- "error_message": "string"
}
}Get the status and details of a specific audit export.
| export_id required | string |
| X-Org-ID required | string Example: travel-us Organization scope for this request. Stamped by the AxonFlow Agent gateway from the cryptographically validated client credential (Set, not Add, so any client-supplied value is overwritten), so it is not client-selectable and carries no cross-org override capability on this route. The orchestrator fails closed with 401 when it is absent or blank; there is no query-string equivalent. |
{- "export": {
- "id": "string",
- "org_id": "string",
- "status": "pending",
- "export_type": "full",
- "format": "json",
- "requested_by": "string",
- "purpose": "string",
- "created_at": "2019-08-24T14:15:22Z",
- "completed_at": "2019-08-24T14:15:22Z",
- "download_url": "string",
- "storage_type": "local",
- "storage_key": "string",
- "file_path": "string",
- "file_size_bytes": 0,
- "file_checksum": "string",
- "record_count": 0,
- "error_message": "string"
}
}Delete an audit export and its associated cloud storage object.
| export_id required | string |
| X-Org-ID required | string Example: travel-us Organization scope for this request. Stamped by the AxonFlow Agent gateway from the cryptographically validated client credential (Set, not Add, so any client-supplied value is overwritten), so it is not client-selectable and carries no cross-org override capability on this route. The orchestrator fails closed with 401 when it is absent or blank; there is no query-string equivalent. |
{- "error": {
- "code": "UNAUTHORIZED",
- "message": "missing tenant ID"
}
}Trigger processing of a pending audit export. Generates the export file, uploads to cloud storage (if configured), and generates a presigned download URL.
| export_id required | string |
| X-Org-ID required | string Example: travel-us Organization scope for this request. Stamped by the AxonFlow Agent gateway from the cryptographically validated client credential (Set, not Add, so any client-supplied value is overwritten), so it is not client-selectable and carries no cross-org override capability on this route. The orchestrator fails closed with 401 when it is absent or blank; there is no query-string equivalent. |
{- "export": {
- "id": "string",
- "org_id": "string",
- "status": "pending",
- "export_type": "full",
- "format": "json",
- "requested_by": "string",
- "purpose": "string",
- "created_at": "2019-08-24T14:15:22Z",
- "completed_at": "2019-08-24T14:15:22Z",
- "download_url": "string",
- "storage_type": "local",
- "storage_key": "string",
- "file_path": "string",
- "file_size_bytes": 0,
- "file_checksum": "string",
- "record_count": 0,
- "error_message": "string"
}
}EU AI Act compliance endpoints for technical documentation export, conformity assessments (Article 43), and accuracy/bias tracking (Article 15). Enterprise feature for EU regulatory compliance.
Creates a new EU AI Act compliance export job for technical documentation (Article 11).
Export types:
full_audit: Complete audit trail for regulatory reviewconformity_evidence: Evidence for conformity assessmentshitl_summary: Human-in-the-loop decision summarydecision_chain: Full decision chain tracingpolicy_violations: Policy violation recordsaccuracy_metrics: Model accuracy and bias metrics| X-Org-ID | string Example: travel-us Organization identifier. Falls back to authenticated org from the Basic auth client when omitted. Surface for callers that need to override (e.g. cross-org admin reads in Enterprise). |
| X-User-ID | string Caller identity. Defaults to the authenticated user resolved from the request token when omitted. Surface for service-mode callers that proxy on behalf of multiple users. |
| export_type required | string Enum: "full_audit" "conformity_evidence" "hitl_summary" "decision_chain" "policy_violations" "accuracy_metrics" Type of compliance export |
| format required | string Enum: "json" "xml" "csv" Export file format |
| date_from | string <date-time> Start of date range |
| date_to | string <date-time> End of date range |
| model_ids | Array of strings Filter by specific model IDs (optional) |
{- "export_type": "full_audit",
- "format": "json",
- "date_from": "2025-01-01T00:00:00Z",
- "date_to": "2025-12-31T23:59:59Z"
}{- "id": "string",
- "org_id": "string",
- "status": "pending",
- "export_type": "full_audit",
- "format": "json",
- "created_at": "2019-08-24T14:15:22Z",
- "started_at": "2019-08-24T14:15:22Z",
- "completed_at": "2019-08-24T14:15:22Z",
- "date_from": "2019-08-24T14:15:22Z",
- "date_to": "2019-08-24T14:15:22Z",
- "download_url": "string",
- "storage_type": "local",
- "storage_key": "string",
- "file_path": "string",
- "file_size": 0,
- "record_count": 0,
- "progress": 0.1,
- "error_message": "string",
- "created_by": "string"
}List EU AI Act compliance exports for the organization.
| limit | integer >= 1 Default: 100 Maximum number of records to return. Defaults vary by endpoint; see per-endpoint description for the cap. |
| offset | integer >= 0 Default: 0 Number of records to skip from the start of the result set.
Pair with |
| X-Org-ID | string Example: travel-us Organization identifier. Falls back to authenticated org from the Basic auth client when omitted. Surface for callers that need to override (e.g. cross-org admin reads in Enterprise). |
{- "exports": [
- {
- "id": "string",
- "org_id": "string",
- "status": "pending",
- "export_type": "full_audit",
- "format": "json",
- "created_at": "2019-08-24T14:15:22Z",
- "started_at": "2019-08-24T14:15:22Z",
- "completed_at": "2019-08-24T14:15:22Z",
- "date_from": "2019-08-24T14:15:22Z",
- "date_to": "2019-08-24T14:15:22Z",
- "download_url": "string",
- "storage_type": "local",
- "storage_key": "string",
- "file_path": "string",
- "file_size": 0,
- "record_count": 0,
- "progress": 0.1,
- "error_message": "string",
- "created_by": "string"
}
], - "total": 0,
- "limit": 0,
- "offset": 0
}Get the status of a specific export job.
| export_id required | string |
{- "id": "string",
- "org_id": "string",
- "status": "pending",
- "export_type": "full_audit",
- "format": "json",
- "created_at": "2019-08-24T14:15:22Z",
- "started_at": "2019-08-24T14:15:22Z",
- "completed_at": "2019-08-24T14:15:22Z",
- "date_from": "2019-08-24T14:15:22Z",
- "date_to": "2019-08-24T14:15:22Z",
- "download_url": "string",
- "storage_type": "local",
- "storage_key": "string",
- "file_path": "string",
- "file_size": 0,
- "record_count": 0,
- "progress": 0.1,
- "error_message": "string",
- "created_by": "string"
}Download a completed export file. When cloud storage is configured, returns a redirect (302) to a presigned URL. For local storage, streams the file.
| export_id required | string |
{- "id": "string",
- "file_path": "string",
- "file_size": 0,
- "format": "string",
- "download_url": "string",
- "storage_type": "local"
}Create a new EU AI Act conformity assessment (Article 43). Used to document compliance for high-risk AI systems.
| X-Org-ID | string Example: travel-us Organization identifier. Falls back to authenticated org from the Basic auth client when omitted. Surface for callers that need to override (e.g. cross-org admin reads in Enterprise). |
| X-User-ID | string Caller identity. Defaults to the authenticated user resolved from the request token when omitted. Surface for service-mode callers that proxy on behalf of multiple users. |
| system_id required | string |
| system_name required | string |
| risk_category required | string Enum: "minimal" "limited" "high-risk" "unacceptable" |
| assessors | Array of strings |
{- "system_id": "ai-system-001",
- "system_name": "Customer Risk Scoring Model",
- "risk_category": "high-risk",
}{- "id": "string",
- "org_id": "string",
- "system_id": "string",
- "system_name": "string",
- "risk_category": "minimal",
- "status": "draft",
- "version": 0,
- "assessment_date": "2019-08-24T14:15:22Z",
- "valid_until": "2019-08-24T14:15:22Z",
- "assessors": [
- "string"
], - "requirements": [
- {
- "requirement_id": "string",
- "article": "string",
- "description": "string",
- "status": "compliant",
- "notes": "string",
- "evidence_ids": [
- "string"
]
}
], - "evidence": [
- {
- "id": "string",
- "type": "document",
- "title": "string",
- "description": "string",
- "file_path": "string",
- "url": "string",
- "uploaded_at": "2019-08-24T14:15:22Z",
- "uploaded_by": "string"
}
], - "findings": [
- {
- "id": "string",
- "severity": "critical",
- "category": "string",
- "description": "string",
- "article": "string",
- "remediation": "string",
- "status": "open"
}
], - "risk_mitigation": { },
- "recommendations": [
- "string"
], - "created_by": "string",
- "created_at": "2019-08-24T14:15:22Z",
- "updated_at": "2019-08-24T14:15:22Z",
- "submitted_at": "2019-08-24T14:15:22Z",
- "submitted_by": "string",
- "approved_at": "2019-08-24T14:15:22Z",
- "approved_by": "string",
- "rejected_at": "2019-08-24T14:15:22Z",
- "rejected_by": "string",
- "rejection_reason": "string"
}List conformity assessments for the organization.
| status | string Enum: "draft" "in_progress" "submitted" "approved" "rejected" |
| limit | integer >= 1 Default: 100 Maximum number of records to return. Defaults vary by endpoint; see per-endpoint description for the cap. |
| offset | integer >= 0 Default: 0 Number of records to skip from the start of the result set.
Pair with |
| X-Org-ID | string Example: travel-us Organization identifier. Falls back to authenticated org from the Basic auth client when omitted. Surface for callers that need to override (e.g. cross-org admin reads in Enterprise). |
{- "assessments": [
- {
- "id": "string",
- "org_id": "string",
- "system_id": "string",
- "system_name": "string",
- "risk_category": "minimal",
- "status": "draft",
- "version": 0,
- "assessment_date": "2019-08-24T14:15:22Z",
- "valid_until": "2019-08-24T14:15:22Z",
- "assessors": [
- "string"
], - "requirements": [
- {
- "requirement_id": "string",
- "article": "string",
- "description": "string",
- "status": "compliant",
- "notes": "string",
- "evidence_ids": [
- "string"
]
}
], - "evidence": [
- {
- "id": "string",
- "type": "document",
- "title": "string",
- "description": "string",
- "file_path": "string",
- "url": "string",
- "uploaded_at": "2019-08-24T14:15:22Z",
- "uploaded_by": "string"
}
], - "findings": [
- {
- "id": "string",
- "severity": "critical",
- "category": "string",
- "description": "string",
- "article": "string",
- "remediation": "string",
- "status": "open"
}
], - "risk_mitigation": { },
- "recommendations": [
- "string"
], - "created_by": "string",
- "created_at": "2019-08-24T14:15:22Z",
- "updated_at": "2019-08-24T14:15:22Z",
- "submitted_at": "2019-08-24T14:15:22Z",
- "submitted_by": "string",
- "approved_at": "2019-08-24T14:15:22Z",
- "approved_by": "string",
- "rejected_at": "2019-08-24T14:15:22Z",
- "rejected_by": "string",
- "rejection_reason": "string"
}
], - "total": 0,
- "limit": 0,
- "offset": 0
}Get details of a specific conformity assessment.
| assessment_id required | string |
{- "id": "string",
- "org_id": "string",
- "system_id": "string",
- "system_name": "string",
- "risk_category": "minimal",
- "status": "draft",
- "version": 0,
- "assessment_date": "2019-08-24T14:15:22Z",
- "valid_until": "2019-08-24T14:15:22Z",
- "assessors": [
- "string"
], - "requirements": [
- {
- "requirement_id": "string",
- "article": "string",
- "description": "string",
- "status": "compliant",
- "notes": "string",
- "evidence_ids": [
- "string"
]
}
], - "evidence": [
- {
- "id": "string",
- "type": "document",
- "title": "string",
- "description": "string",
- "file_path": "string",
- "url": "string",
- "uploaded_at": "2019-08-24T14:15:22Z",
- "uploaded_by": "string"
}
], - "findings": [
- {
- "id": "string",
- "severity": "critical",
- "category": "string",
- "description": "string",
- "article": "string",
- "remediation": "string",
- "status": "open"
}
], - "risk_mitigation": { },
- "recommendations": [
- "string"
], - "created_by": "string",
- "created_at": "2019-08-24T14:15:22Z",
- "updated_at": "2019-08-24T14:15:22Z",
- "submitted_at": "2019-08-24T14:15:22Z",
- "submitted_by": "string",
- "approved_at": "2019-08-24T14:15:22Z",
- "approved_by": "string",
- "rejected_at": "2019-08-24T14:15:22Z",
- "rejected_by": "string",
- "rejection_reason": "string"
}Update a conformity assessment (only allowed for draft/in_progress status).
| assessment_id required | string |
| system_name | string |
| risk_category | string Enum: "minimal" "limited" "high-risk" "unacceptable" |
| assessors | Array of strings |
Array of objects (RequirementStatus) | |
Array of objects (EvidenceItem) | |
Array of objects (Finding) | |
object | |
| recommendations | Array of strings |
{- "system_name": "string",
- "risk_category": "minimal",
- "assessors": [
- "string"
], - "requirements": [
- {
- "requirement_id": "string",
- "article": "string",
- "description": "string",
- "status": "compliant",
- "notes": "string",
- "evidence_ids": [
- "string"
]
}
], - "evidence": [
- {
- "id": "string",
- "type": "document",
- "title": "string",
- "description": "string",
- "file_path": "string",
- "url": "string",
- "uploaded_at": "2019-08-24T14:15:22Z",
- "uploaded_by": "string"
}
], - "findings": [
- {
- "id": "string",
- "severity": "critical",
- "category": "string",
- "description": "string",
- "article": "string",
- "remediation": "string",
- "status": "open"
}
], - "risk_mitigation": { },
- "recommendations": [
- "string"
]
}{- "id": "string",
- "org_id": "string",
- "system_id": "string",
- "system_name": "string",
- "risk_category": "minimal",
- "status": "draft",
- "version": 0,
- "assessment_date": "2019-08-24T14:15:22Z",
- "valid_until": "2019-08-24T14:15:22Z",
- "assessors": [
- "string"
], - "requirements": [
- {
- "requirement_id": "string",
- "article": "string",
- "description": "string",
- "status": "compliant",
- "notes": "string",
- "evidence_ids": [
- "string"
]
}
], - "evidence": [
- {
- "id": "string",
- "type": "document",
- "title": "string",
- "description": "string",
- "file_path": "string",
- "url": "string",
- "uploaded_at": "2019-08-24T14:15:22Z",
- "uploaded_by": "string"
}
], - "findings": [
- {
- "id": "string",
- "severity": "critical",
- "category": "string",
- "description": "string",
- "article": "string",
- "remediation": "string",
- "status": "open"
}
], - "risk_mitigation": { },
- "recommendations": [
- "string"
], - "created_by": "string",
- "created_at": "2019-08-24T14:15:22Z",
- "updated_at": "2019-08-24T14:15:22Z",
- "submitted_at": "2019-08-24T14:15:22Z",
- "submitted_by": "string",
- "approved_at": "2019-08-24T14:15:22Z",
- "approved_by": "string",
- "rejected_at": "2019-08-24T14:15:22Z",
- "rejected_by": "string",
- "rejection_reason": "string"
}Submit a conformity assessment for approval review.
| assessment_id required | string |
| X-User-ID | string Caller identity. Defaults to the authenticated user resolved from the request token when omitted. Surface for service-mode callers that proxy on behalf of multiple users. |
{- "id": "string",
- "org_id": "string",
- "system_id": "string",
- "system_name": "string",
- "risk_category": "minimal",
- "status": "draft",
- "version": 0,
- "assessment_date": "2019-08-24T14:15:22Z",
- "valid_until": "2019-08-24T14:15:22Z",
- "assessors": [
- "string"
], - "requirements": [
- {
- "requirement_id": "string",
- "article": "string",
- "description": "string",
- "status": "compliant",
- "notes": "string",
- "evidence_ids": [
- "string"
]
}
], - "evidence": [
- {
- "id": "string",
- "type": "document",
- "title": "string",
- "description": "string",
- "file_path": "string",
- "url": "string",
- "uploaded_at": "2019-08-24T14:15:22Z",
- "uploaded_by": "string"
}
], - "findings": [
- {
- "id": "string",
- "severity": "critical",
- "category": "string",
- "description": "string",
- "article": "string",
- "remediation": "string",
- "status": "open"
}
], - "risk_mitigation": { },
- "recommendations": [
- "string"
], - "created_by": "string",
- "created_at": "2019-08-24T14:15:22Z",
- "updated_at": "2019-08-24T14:15:22Z",
- "submitted_at": "2019-08-24T14:15:22Z",
- "submitted_by": "string",
- "approved_at": "2019-08-24T14:15:22Z",
- "approved_by": "string",
- "rejected_at": "2019-08-24T14:15:22Z",
- "rejected_by": "string",
- "rejection_reason": "string"
}Approve a submitted conformity assessment.
| assessment_id required | string |
| X-User-ID | string Caller identity. Defaults to the authenticated user resolved from the request token when omitted. Surface for service-mode callers that proxy on behalf of multiple users. |
| validity_years | integer Default: 1 Number of years the approval is valid |
{- "validity_years": 1
}{- "id": "string",
- "org_id": "string",
- "system_id": "string",
- "system_name": "string",
- "risk_category": "minimal",
- "status": "draft",
- "version": 0,
- "assessment_date": "2019-08-24T14:15:22Z",
- "valid_until": "2019-08-24T14:15:22Z",
- "assessors": [
- "string"
], - "requirements": [
- {
- "requirement_id": "string",
- "article": "string",
- "description": "string",
- "status": "compliant",
- "notes": "string",
- "evidence_ids": [
- "string"
]
}
], - "evidence": [
- {
- "id": "string",
- "type": "document",
- "title": "string",
- "description": "string",
- "file_path": "string",
- "url": "string",
- "uploaded_at": "2019-08-24T14:15:22Z",
- "uploaded_by": "string"
}
], - "findings": [
- {
- "id": "string",
- "severity": "critical",
- "category": "string",
- "description": "string",
- "article": "string",
- "remediation": "string",
- "status": "open"
}
], - "risk_mitigation": { },
- "recommendations": [
- "string"
], - "created_by": "string",
- "created_at": "2019-08-24T14:15:22Z",
- "updated_at": "2019-08-24T14:15:22Z",
- "submitted_at": "2019-08-24T14:15:22Z",
- "submitted_by": "string",
- "approved_at": "2019-08-24T14:15:22Z",
- "approved_by": "string",
- "rejected_at": "2019-08-24T14:15:22Z",
- "rejected_by": "string",
- "rejection_reason": "string"
}Reject a submitted conformity assessment.
| assessment_id required | string |
| X-User-ID | string Caller identity. Defaults to the authenticated user resolved from the request token when omitted. Surface for service-mode callers that proxy on behalf of multiple users. |
| reason required | string Reason for rejection |
{- "reason": "string"
}{- "id": "string",
- "org_id": "string",
- "system_id": "string",
- "system_name": "string",
- "risk_category": "minimal",
- "status": "draft",
- "version": 0,
- "assessment_date": "2019-08-24T14:15:22Z",
- "valid_until": "2019-08-24T14:15:22Z",
- "assessors": [
- "string"
], - "requirements": [
- {
- "requirement_id": "string",
- "article": "string",
- "description": "string",
- "status": "compliant",
- "notes": "string",
- "evidence_ids": [
- "string"
]
}
], - "evidence": [
- {
- "id": "string",
- "type": "document",
- "title": "string",
- "description": "string",
- "file_path": "string",
- "url": "string",
- "uploaded_at": "2019-08-24T14:15:22Z",
- "uploaded_by": "string"
}
], - "findings": [
- {
- "id": "string",
- "severity": "critical",
- "category": "string",
- "description": "string",
- "article": "string",
- "remediation": "string",
- "status": "open"
}
], - "risk_mitigation": { },
- "recommendations": [
- "string"
], - "created_by": "string",
- "created_at": "2019-08-24T14:15:22Z",
- "updated_at": "2019-08-24T14:15:22Z",
- "submitted_at": "2019-08-24T14:15:22Z",
- "submitted_by": "string",
- "approved_at": "2019-08-24T14:15:22Z",
- "approved_by": "string",
- "rejected_at": "2019-08-24T14:15:22Z",
- "rejected_by": "string",
- "rejection_reason": "string"
}Get accuracy and bias tracking summary for the organization (Article 15). Provides overview of model performance and compliance status.
| X-Org-ID | string Example: travel-us Organization identifier. Falls back to authenticated org from the Basic auth client when omitted. Surface for callers that need to override (e.g. cross-org admin reads in Enterprise). |
{- "org_id": "string",
- "total_models": 0,
- "models_above_target": 0,
- "models_below_target": 0,
- "average_accuracy": 0.1,
- "active_alerts": 0,
- "last_updated": "2019-08-24T14:15:22Z",
- "metrics_by_model": { }
}Record an accuracy metric for a model.
| X-Org-ID | string Example: travel-us Organization identifier. Falls back to authenticated org from the Basic auth client when omitted. Surface for callers that need to override (e.g. cross-org admin reads in Enterprise). |
| model_id required | string |
| metric_type required | string Enum: "accuracy" "precision" "recall" "f1_score" "auc_roc" "auc_pr" "mse" "mae" "custom" |
| value required | number <double> |
| sample_size | integer |
| window_start | string <date-time> |
| window_end | string <date-time> |
object |
{- "model_id": "model-001",
- "metric_type": "accuracy",
- "value": 0.95,
- "sample_size": 10000
}{- "id": "string",
- "org_id": "string",
- "model_id": "string",
- "metric_type": "accuracy",
- "value": 0.1,
- "sample_size": 0,
- "timestamp": "2019-08-24T14:15:22Z",
- "window_start": "2019-08-24T14:15:22Z",
- "window_end": "2019-08-24T14:15:22Z",
- "metadata": { }
}Record a bias detection measurement for a model.
| X-Org-ID | string Example: travel-us Organization identifier. Falls back to authenticated org from the Basic auth client when omitted. Surface for callers that need to override (e.g. cross-org admin reads in Enterprise). |
| model_id required | string |
| category required | string Enum: "gender" "age" "ethnicity" "disability" "religion" "nationality" "socioeconomic" "custom" |
| group_a required | string Name of the first comparison group |
| group_b required | string Name of the second comparison group |
| group_a_rate required | number <double> Positive outcome rate for group A |
| group_b_rate required | number <double> Positive outcome rate for group B |
| sample_size | integer |
| window_start | string <date-time> |
| window_end | string <date-time> |
object |
{- "model_id": "model-001",
- "category": "gender",
- "group_a": "male",
- "group_b": "female",
- "group_a_rate": 0.82,
- "group_b_rate": 0.79,
- "sample_size": 5000
}{- "id": "string",
- "org_id": "string",
- "model_id": "string",
- "category": "gender",
- "score": 0.1,
- "threshold": 0.1,
- "is_violation": true,
- "sample_size": 0,
- "group_a": "string",
- "group_b": "string",
- "group_a_rate": 0.1,
- "group_b_rate": 0.1,
- "timestamp": "2019-08-24T14:15:22Z",
- "window_start": "2019-08-24T14:15:22Z",
- "window_end": "2019-08-24T14:15:22Z",
- "metadata": { }
}Get historical accuracy metrics for filtering and analysis.
| model_id | string |
| metric_type | string Enum: "accuracy" "precision" "recall" "f1_score" "auc_roc" "auc_pr" "mse" "mae" "custom" |
| from | string <date-time> |
| to | string <date-time> |
| limit | integer >= 1 Default: 100 Maximum number of records to return. Defaults vary by endpoint; see per-endpoint description for the cap. |
| offset | integer >= 0 Default: 0 Number of records to skip from the start of the result set.
Pair with |
| X-Org-ID | string Example: travel-us Organization identifier. Falls back to authenticated org from the Basic auth client when omitted. Surface for callers that need to override (e.g. cross-org admin reads in Enterprise). |
{- "metrics": [
- {
- "id": "string",
- "org_id": "string",
- "model_id": "string",
- "metric_type": "accuracy",
- "value": 0.1,
- "sample_size": 0,
- "timestamp": "2019-08-24T14:15:22Z",
- "window_start": "2019-08-24T14:15:22Z",
- "window_end": "2019-08-24T14:15:22Z",
- "metadata": { }
}
], - "total": 0,
- "limit": 0,
- "offset": 0
}Get active accuracy and bias alerts for the organization.
| X-Org-ID | string Example: travel-us Organization identifier. Falls back to authenticated org from the Basic auth client when omitted. Surface for callers that need to override (e.g. cross-org admin reads in Enterprise). |
{- "alerts": [
- {
- "id": "string",
- "org_id": "string",
- "model_id": "string",
- "alert_type": "accuracy_degradation",
- "severity": "info",
- "title": "string",
- "description": "string",
- "metric_type": "string",
- "bias_category": "string",
- "current_value": 0.1,
- "threshold": 0.1,
- "triggered_at": "2019-08-24T14:15:22Z",
- "acked_at": "2019-08-24T14:15:22Z",
- "acked_by": "string",
- "resolved_at": "2019-08-24T14:15:22Z",
- "resolved_by": "string"
}
], - "total": 0
}Acknowledge an accuracy or bias alert.
| alert_id required | string |
| X-User-ID | string Caller identity. Defaults to the authenticated user resolved from the request token when omitted. Surface for service-mode callers that proxy on behalf of multiple users. |
{- "status": "acknowledged"
}Resolve an accuracy or bias alert.
| alert_id required | string |
| X-User-ID | string Caller identity. Defaults to the authenticated user resolved from the request token when omitted. Surface for service-mode callers that proxy on behalf of multiple users. |
{- "status": "resolved"
}OJK AI Governance + UU PDP compliance for Indonesian financial services. Audit export, retention/readiness checks, UU PDP Art. 46 breach-notification lifecycle, and a compliance dashboard. Enterprise feature.
Export audit data for OJK/BI regulatory submission. Supports:
OJK_AI_GOVERNANCE, UU_PDP, BI_PJP,
OJK_BI_COMBINED (default)hitl_oversight and pii_redactions are accepted by request
validation but are not implemented by the export service —
requesting them (or expecting them under all) yields no rows
and no error (no queryHITLRecords/queryPIIRedactions exists
in ojk_audit_export_service.go).The date range may span at most 5 years, matching the OJK 5-year
(1825-day) retention requirement. The export runs synchronously and
returns status: completed with the data inline.
Enterprise Feature: Available only for Indonesian financial services deployments.
| X-Tenant-ID | string Tenant identifier. The OJK module falls back to X-Org-ID when
absent; a request carrying neither header is rejected with 400
(code |
| X-Org-ID | string Fallback tenant identifier when X-Tenant-ID is absent |
| start_date required | string <date> Window start (YYYY-MM-DD) |
| end_date required | string <date> Window end (YYYY-MM-DD, not before start_date; range at most 5 years) |
| format | string Default: "json" Enum: "json" "csv" "xml" |
| framework | string Default: "OJK_BI_COMBINED" Enum: "OJK_AI_GOVERNANCE" "UU_PDP" "BI_PJP" "OJK_BI_COMBINED" |
| data_types | Array of strings Items Enum: "policy_violations" "llm_calls" "decision_chain" "hitl_oversight" "pii_redactions" "cross_border_transfers" "breach_notifications" "all" Defaults to [all] |
object | |
| include_pii | boolean Default: false |
{- "start_date": "2025-01-01",
- "end_date": "2025-12-31",
- "format": "json",
- "framework": "OJK_BI_COMBINED",
- "data_types": [
- "policy_violations",
- "llm_calls",
- "cross_border_transfers"
]
}{- "export_id": "3f6d2f4e-8f2a-4a1b-9a51-1de1c1b2c3d4",
- "status": "completed",
- "framework": "OJK_BI_COMBINED",
- "format": "json",
- "summary": {
- "total_records": 15420,
- "records_by_type": {
- "policy_violations": 142,
- "llm_calls": 15278
}, - "date_range": {
- "start": "2025-01-01T00:00:00Z",
- "end": "2025-12-31T00:00:00Z"
}, - "compliance_score": 92.5
}, - "created_at": "2026-07-10T09:00:00Z",
- "metadata": {
- "export_version": "1.0.0",
- "generated_by": "axonflow-ojk-module",
- "tenant_id": "bank-indonesia-corp"
}
}Get the status of an OJK audit export by id.
Enterprise Feature.
| id required | string Export ID from the export request |
| X-Tenant-ID | string Tenant identifier. The OJK module falls back to X-Org-ID when
absent; a request carrying neither header is rejected with 400
(code |
| X-Org-ID | string Fallback tenant identifier when X-Tenant-ID is absent |
{- "export_id": "string",
- "status": "string",
- "framework": "OJK_AI_GOVERNANCE",
- "format": "json",
- "summary": {
- "total_records": 0,
- "records_by_type": {
- "property1": 0,
- "property2": 0
}, - "date_range": {
- "start": "2019-08-24T14:15:22Z",
- "end": "2019-08-24T14:15:22Z"
}, - "compliance_score": 0.1
}, - "data": {
- "policy_violations": [
- {
- "id": "string",
- "timestamp": "2019-08-24T14:15:22Z",
- "policy_id": "string",
- "policy_name": "string",
- "severity": "string",
- "action": "string",
- "description": "string",
- "tenant_id": "string"
}
], - "llm_calls": [
- {
- "id": "string",
- "timestamp": "2019-08-24T14:15:22Z",
- "model_id": "string",
- "provider": "string",
- "input_tokens": 0,
- "output_tokens": 0,
- "cost": 0.1,
- "latency_ms": 0,
- "policy_decision": "string"
}
], - "decision_chains": [
- {
- "id": "string",
- "timestamp": "2019-08-24T14:15:22Z",
- "decision_id": "string",
- "risk_level": "string",
- "model_id": "string",
- "requires_review": true
}
], - "hitl_records": [
- {
- "id": "string",
- "timestamp": "2019-08-24T14:15:22Z",
- "trigger_reason": "string",
- "reviewer_id": "string",
- "decision": "string",
- "review_time_ms": 0
}
], - "pii_redactions": [
- {
- "id": "string",
- "timestamp": "2019-08-24T14:15:22Z",
- "pii_type": "string",
- "redaction_method": "string",
- "confidence": 0.1
}
], - "cross_border_transfers": [
- {
- "id": "string",
- "timestamp": "2019-08-24T14:15:22Z",
- "data_residency": "string",
- "transfer_basis": "adequacy",
- "destination_country": "string",
- "data_categories": [
- "string"
], - "approval_status": "string"
}
], - "breach_notifications": [
- {
- "id": "string",
- "incident_timestamp": "2019-08-24T14:15:22Z",
- "discovery_time": "2019-08-24T14:15:22Z",
- "notification_deadline": "2019-08-24T14:15:22Z",
- "data_subjects_affected": 0,
- "data_types_involved": [
- "string"
], - "notified_authority": "string",
- "status": "string",
- "stored_status": "string",
- "submitted_at": "2019-08-24T14:15:22Z",
- "acknowledged_at": "2019-08-24T14:15:22Z",
- "within_deadline": true,
- "created_at": "2019-08-24T14:15:22Z"
}
]
}, - "download_url": "string",
- "created_at": "2019-08-24T14:15:22Z",
- "expires_at": "2019-08-24T14:15:22Z",
- "metadata": {
- "export_version": "1.0.0",
- "generated_by": "axonflow-ojk-module",
- "tenant_id": "string",
- "checksum": "string"
}
}Reports 5-year (1825-day) retention compliance for OJK audit data.
compliance_status is non_compliant when the configured retention
is below the 1825-day minimum.
Enterprise Feature.
| data_types | string Example: data_types=policy_violations,llm_calls Comma-separated list of data types to report on. ⚠️ Parsed but
ignored by the current implementation — |
| X-Tenant-ID | string Tenant identifier. The OJK module falls back to X-Org-ID when
absent; a request carrying neither header is rejected with 400
(code |
| X-Org-ID | string Fallback tenant identifier when X-Tenant-ID is absent |
{- "compliance_status": "compliant",
- "framework": "OJK_BI_COMBINED",
- "retention_days": 0,
- "min_retention_days": 1825,
- "data_types": [
- {
- "data_type": "string",
- "status": "string",
- "oldest_record": "2019-08-24T14:15:22Z",
- "newest_record": "2019-08-24T14:15:22Z",
- "total_records": 0
}
], - "next_cleanup": "2019-08-24T14:15:22Z"
}Validates readiness for an OJK regulatory audit across five checks:
Data Retention, PII Detection, Human Oversight, Audit Logging, and
Breach Notification. Returns a 0-100 score; ready is true at 80+.
Enterprise Feature.
| X-Tenant-ID | string Tenant identifier. The OJK module falls back to X-Org-ID when
absent; a request carrying neither header is rejected with 400
(code |
| X-Org-ID | string Fallback tenant identifier when X-Tenant-ID is absent |
{- "ready": true,
- "score": 100,
- "framework": "OJK_BI_COMBINED",
- "checks": [
- {
- "name": "Data Retention",
- "description": "5-year (1825-day) retention configured",
- "status": "pass"
}, - {
- "name": "PII Detection",
- "description": "Indonesian PII patterns active",
- "status": "pass"
}
]
}Submits a personal-data breach notification per UU PDP Art. 46. The
server assigns the id, sets notification_deadline to
discovery_time + 72h, defaults notified_authority to MOCDA, and
stamps submitted_at. The returned status is normally submitted,
or overdue when the 72-hour deadline had already lapsed at
submission.
Enterprise Feature.
| X-Tenant-ID | string Tenant identifier. The OJK module falls back to X-Org-ID when
absent; a request carrying neither header is rejected with 400
(code |
| X-Org-ID | string Fallback tenant identifier when X-Tenant-ID is absent |
| id | string Server-assigned |
| incident_timestamp required | string <date-time> |
| discovery_time required | string <date-time> |
| notification_deadline | string <date-time> Server-computed (discovery_time + 72h) |
| data_subjects_affected required | integer >= 1 |
| data_types_involved required | Array of strings non-empty |
| description required | string |
| remediation_steps required | Array of strings non-empty |
| notified_authority | string Defaults to MOCDA |
| status | string Enum: "draft" "submitted" "acknowledged" "overdue" "failed" |
| submitted_at | string <date-time> |
| acknowledged_at | string <date-time> |
| created_at | string <date-time> |
{- "incident_timestamp": "2026-07-08T14:00:00Z",
- "discovery_time": "2026-07-09T09:00:00Z",
- "data_subjects_affected": 1200,
- "data_types_involved": [
- "nik",
- "phone_number"
], - "description": "Misconfigured export bucket exposed customer records",
- "remediation_steps": [
- "Bucket policy corrected",
- "Access keys rotated"
]
}{- "id": "string",
- "incident_timestamp": "2019-08-24T14:15:22Z",
- "discovery_time": "2019-08-24T14:15:22Z",
- "notification_deadline": "2019-08-24T14:15:22Z",
- "data_subjects_affected": 1,
- "data_types_involved": [
- "string"
], - "description": "string",
- "remediation_steps": [
- "string"
], - "notified_authority": "string",
- "status": "draft",
- "submitted_at": "2019-08-24T14:15:22Z",
- "acknowledged_at": "2019-08-24T14:15:22Z",
- "created_at": "2019-08-24T14:15:22Z"
}Marks a submitted breach notification as acknowledged by the
authority. Only the submitted -> acknowledged transition is valid;
acknowledging a draft/overdue/failed/already-acknowledged record
returns 409.
Enterprise Feature.
| X-Tenant-ID | string Tenant identifier. The OJK module falls back to X-Org-ID when
absent; a request carrying neither header is rejected with 400
(code |
| X-Org-ID | string Fallback tenant identifier when X-Tenant-ID is absent |
| id required | string Breach notification id |
{- "id": "string"
}{- "id": "string",
- "incident_timestamp": "2019-08-24T14:15:22Z",
- "discovery_time": "2019-08-24T14:15:22Z",
- "notification_deadline": "2019-08-24T14:15:22Z",
- "data_subjects_affected": 1,
- "data_types_involved": [
- "string"
], - "description": "string",
- "remediation_steps": [
- "string"
], - "notified_authority": "string",
- "status": "draft",
- "submitted_at": "2019-08-24T14:15:22Z",
- "acknowledged_at": "2019-08-24T14:15:22Z",
- "created_at": "2019-08-24T14:15:22Z"
}Flips draft (unsubmitted) breach notifications whose 72-hour UU PDP
notification deadline has lapsed to overdue. Intended to be called
periodically (deadline sweep).
Enterprise Feature.
| X-Tenant-ID | string Tenant identifier. The OJK module falls back to X-Org-ID when
absent; a request carrying neither header is rejected with 400
(code |
| X-Org-ID | string Fallback tenant identifier when X-Tenant-ID is absent |
{- "flipped_overdue": 2
}Returns the OJK/UU PDP compliance dashboard: compliance score, retention status, breach-notification counts (total and overdue), active policies, and recent violations.
Enterprise Feature.
| X-Tenant-ID | string Tenant identifier. The OJK module falls back to X-Org-ID when
absent; a request carrying neither header is rejected with 400
(code |
| X-Org-ID | string Fallback tenant identifier when X-Tenant-ID is absent |
{- "framework": "OJK_BI_COMBINED",
- "compliance_score": 100,
- "total_audit_records": 0,
- "active_policies": 8,
- "recent_violations": 0,
- "retention_status": "compliant",
- "breach_notifications": 3,
- "overdue_breach_notifications": 0,
- "last_updated": "2026-07-10T09:00:00Z"
}Decision explainability (ADR-043) and session-scoped policy overrides (ADR-044). List recent governance decisions, explain a specific decision, and create/list/revoke time-boxed policy overrides.
Creates a time-boxed override for a static or dynamic policy
(ADR-044). A justification (override_reason, max 500 chars) is
mandatory. TTL is clamped server-side: default 3600s when omitted,
minimum 60s, hard cap 86400s (24h) — the response reports the
requested value and the clamp reason when clamping occurred.
Critical-risk policies and policies with allow_override=false
cannot be overridden (403).
| X-User-Email required | string Authenticated user identity (falls back to X-User-ID); missing identity is a 401 |
| X-Tenant-ID required | string Example: travel-us Tenant identifier scoping the request. The AxonFlow Agent gateway sets this header after authentication; the orchestrator fails closed when it is absent (401 on audit/decision endpoints, 400 on others — see each operation). Clients cannot widen their scope through it: handlers force the tenant filter from this header, never from the request body. |
| X-Org-ID | string Example: travel-us Organization identifier. Falls back to authenticated org from the Basic auth client when omitted. Surface for callers that need to override (e.g. cross-org admin reads in Enterprise). |
| policy_id required | string Policy UUID, or the human-readable slug (static) / name (dynamic) |
| policy_type required | string Enum: "static" "dynamic" |
| tool_signature | string Optional tool scope for the override |
| override_reason required | string <= 500 characters Mandatory justification (ADR-044) |
| ttl_seconds | integer <int64> Override lifetime in seconds. Omitted/0 defaults to 3600. Clamped server-side to [60, 86400]; the response reports any clamp. |
{- "policy_id": "pii-us-ssn-redact",
- "policy_type": "static",
- "tool_signature": "mcp:github/create_issue",
- "override_reason": "Approved incident-response exception INC-4432",
- "ttl_seconds": 1800
}{- "id": "string",
- "policy_id": "string",
- "policy_type": "string",
- "expires_at": "2019-08-24T14:15:22Z",
- "ttl_seconds": 0,
- "requested_ttl": 0,
- "clamped": true,
- "clamped_reason": "string",
- "created_at": "2019-08-24T14:15:22Z"
}Lists the tenant's policy overrides, newest first, capped at 100
rows. Revoked overrides are excluded unless include_revoked=true.
Role-scoped reads (#2922): admin/owner list every override in
the tenant; every other role lists only the overrides they created
(created_by). Revoking an override is scoped the same way. The
role/scope is trusted only over the internal proxy-auth channel.
| policy_id | string Filter by policy UUID or slug/name |
| include_revoked | boolean Default: false Include revoked overrides (only the literal |
| X-Tenant-ID required | string Example: travel-us Tenant identifier scoping the request. The AxonFlow Agent gateway sets this header after authentication; the orchestrator fails closed when it is absent (401 on audit/decision endpoints, 400 on others — see each operation). Clients cannot widen their scope through it: handlers force the tenant filter from this header, never from the request body. |
{- "overrides": [
- {
- "id": "string",
- "policy_id": "string",
- "policy_type": "string",
- "tenant_id": "string",
- "override_reason": "string",
- "expires_at": "2019-08-24T14:15:22Z",
- "revoked_at": "2019-08-24T14:15:22Z",
- "created_at": "2019-08-24T14:15:22Z"
}
], - "count": 0
}Returns one override by id, tenant-scoped. Another tenant's override returns 404.
| id required | string Override id |
| X-Tenant-ID required | string Example: travel-us Tenant identifier scoping the request. The AxonFlow Agent gateway sets this header after authentication; the orchestrator fails closed when it is absent (401 on audit/decision endpoints, 400 on others — see each operation). Clients cannot widen their scope through it: handlers force the tenant filter from this header, never from the request body. |
{- "id": "string",
- "policy_id": "string",
- "policy_type": "string",
- "tenant_id": "string",
- "organization_id": "string",
- "tool_signature": "string",
- "override_reason": "string",
- "expires_at": "2019-08-24T14:15:22Z",
- "created_by": "string",
- "created_at": "2019-08-24T14:15:22Z",
- "revoked_at": "2019-08-24T14:15:22Z",
- "revoked_by": "string"
}Revokes an active override (tenant-scoped). An already-revoked or cross-tenant override returns 404.
| id required | string Override id |
| X-User-Email required | string Authenticated user identity (falls back to X-User-ID); missing identity is a 401 |
| X-Tenant-ID required | string Example: travel-us Tenant identifier scoping the request. The AxonFlow Agent gateway sets this header after authentication; the orchestrator fails closed when it is absent (401 on audit/decision endpoints, 400 on others — see each operation). Clients cannot widen their scope through it: handlers force the tenant filter from this header, never from the request body. |
| X-Org-ID | string Example: travel-us Organization identifier. Falls back to authenticated org from the Basic auth client when omitted. Surface for callers that need to override (e.g. cross-org admin reads in Enterprise). |
{- "id": "string",
- "revoked_at": "2019-08-24T14:15:22Z"
}Lists recent decisions for the tenant, newest first. The lookback
window and maximum page size are tier-gated: Community/Free sees
the last 5 decisions in 24h; Evaluation 100 decisions in 14 days;
Enterprise up to 1000 with an unbounded window. Requesting a limit
above the tier cap returns 429 with the upgrade envelope
(error, limit_type: decision_list_size, tier, limit,
remaining, upgrade{tier, wording, compare_url, buy_url}) plus the
X-Axonflow-Tier-Limit and X-Axonflow-Upgrade-URL headers. A
since earlier than the tier window is silently clamped to the
window.
Role-scoped reads (#2922): admin/owner list every user's
decisions; every other role lists only their own (rows attributed to
their identity). A caller with no resolvable per-user identity gets an
empty list. The role/scope is trusted only over the internal
proxy-auth channel. DEPLOYMENT_MODE=community lists tenant-wide, and
community-saas lists tenant-wide over the agent gateway — see
POST /api/v1/audit/search for the single-operator rationale (#3060).
| limit | integer >= 1 Page size (positive integer). Defaults to the tier maximum. |
| since | string <date-time> RFC3339 lower bound; defaults to (and is clamped to) the tier lookback window |
| decision | string Enum: "allowed" "blocked" "redacted" "needs_approval" "error" Canonical verdict filter |
| policy_id | string Filter to decisions where this policy fired |
| tool_signature | string Filter by tool signature |
| X-Tenant-ID required | string Example: travel-us Tenant identifier scoping the request. The AxonFlow Agent gateway sets this header after authentication; the orchestrator fails closed when it is absent (401 on audit/decision endpoints, 400 on others — see each operation). Clients cannot widen their scope through it: handlers force the tenant filter from this header, never from the request body. |
{- "decisions": [
- {
- "decision_id": "string",
- "timestamp": "2019-08-24T14:15:22Z",
- "decision": "allowed",
- "policy_id": "string",
- "tool_signature": "string",
- "context": {
- "property1": "string",
- "property2": "string"
}, - "transfer_basis": "string",
- "data_residency": "string"
}
]
}Returns the explanation for a decision id (ADR-043): matched
policies, verdict and reason, risk level, override availability (and
any existing override id), the caller's 24h hit count for the first
matched policy, and policy version drift (version at decision time vs
latest). Tenant-scoped via X-Tenant-ID; a decision belonging to
another tenant returns 404 (not 403) so the endpoint is not an
existence oracle.
| id required | string Decision id |
| X-Tenant-ID required | string Example: travel-us Tenant identifier scoping the request. The AxonFlow Agent gateway sets this header after authentication; the orchestrator fails closed when it is absent (401 on audit/decision endpoints, 400 on others — see each operation). Clients cannot widen their scope through it: handlers force the tenant filter from this header, never from the request body. |
| X-User-Email | string Caller identity used for the per-user historical hit count (falls back to X-User-ID) |
{- "decision_id": "string",
- "timestamp": "2019-08-24T14:15:22Z",
- "policy_matches": [
- {
- "policy_id": "string",
- "policy_name": "string",
- "action": "string",
- "risk_level": "string",
- "allow_override": true,
- "policy_description": "string"
}
], - "matched_rules": [
- {
- "policy_id": "string",
- "rule_id": "string",
- "rule_text": "string",
- "matched_on": "string"
}
], - "decision": "string",
- "reason": "string",
- "risk_level": "string",
- "override_available": true,
- "override_existing_id": "string",
- "historical_hit_count_session": 0,
- "policy_source_link": "string",
- "tool_signature": "string",
- "policy_version_at_decision": 0,
- "latest_policy_version": 0,
- "context": {
- "property1": "string",
- "property2": "string"
}, - "context_truncated": true
}Returns comprehensive JSON metrics including:
{- "orchestrator_metrics": {
- "uptime_seconds": 3600,
- "total_requests": 5000,
- "success_requests": 4800,
- "failed_requests": 100,
- "blocked_requests": 100,
- "success_rate": 96,
- "rps": 1.38,
- "error_rate_per_sec": 0.027,
- "dynamic_policy_eval_p50_ms": 2.5,
- "dynamic_policy_eval_p95_ms": 8,
- "dynamic_policy_eval_p99_ms": 15,
- "llm_routing_p50_ms": 500,
- "llm_routing_p95_ms": 1500,
- "llm_routing_p99_ms": 3000
}, - "health": {
- "up": 1,
- "consecutive_errors": 0
}, - "providers": {
- "openai": {
- "total_calls": 3000,
- "success_calls": 2950,
- "failed_calls": 50,
- "total_tokens": 1500000,
- "total_cost": 45.5,
- "p99_ms": 2500
}, - "bedrock": {
- "total_calls": 2000,
- "success_calls": 1990,
- "failed_calls": 10,
- "total_tokens": 800000,
- "total_cost": 12,
- "p99_ms": 1800
}
}, - "timestamp": "2025-01-15T10:30:00Z"
}Decision & Execution Replay API for debugging, auditing, and compliance. Captures every step of workflow execution with full input/output snapshots and policy decisions.
List all workflow executions with optional filtering and pagination. Supports filtering by status, workflow, tenant, time range.
| limit | integer Default: 50 Maximum number of results (default 50) |
| offset | integer Default: 0 Pagination offset (default 0) |
| status | string Enum: "pending" "running" "completed" "failed" Filter by execution status |
| workflow_id | string Filter by workflow name |
| start_time | string <date-time> Filter by start time (RFC3339 format) |
| end_time | string <date-time> Filter by end time (RFC3339 format) |
| X-Tenant-ID | string Filter by tenant ID |
| X-Org-ID | string Filter by organization ID |
{- "executions": [
- {
- "request_id": "string",
- "workflow_name": "string",
- "status": "pending",
- "total_steps": 0,
- "completed_steps": 0,
- "started_at": "2019-08-24T14:15:22Z",
- "completed_at": "2019-08-24T14:15:22Z",
- "duration_ms": 0,
- "total_tokens": 0,
- "total_cost_usd": 0.1,
- "org_id": "string",
- "tenant_id": "string",
- "user_id": "string",
- "error_message": "string",
- "input_summary": "string",
- "output_summary": "string"
}
], - "total": 0,
- "limit": 0,
- "offset": 0
}Get full execution details including summary and all steps.
| id required | string Execution request ID |
{- "summary": {
- "request_id": "string",
- "workflow_name": "string",
- "status": "pending",
- "total_steps": 0,
- "completed_steps": 0,
- "started_at": "2019-08-24T14:15:22Z",
- "completed_at": "2019-08-24T14:15:22Z",
- "duration_ms": 0,
- "total_tokens": 0,
- "total_cost_usd": 0.1,
- "org_id": "string",
- "tenant_id": "string",
- "user_id": "string",
- "error_message": "string",
- "input_summary": "string",
- "output_summary": "string"
}, - "steps": [
- {
- "request_id": "string",
- "step_index": 0,
- "step_name": "string",
- "status": "pending",
- "started_at": "2019-08-24T14:15:22Z",
- "completed_at": "2019-08-24T14:15:22Z",
- "duration_ms": 0,
- "input": { },
- "output": { },
- "provider": "string",
- "model": "string",
- "tokens_in": 0,
- "tokens_out": 0,
- "cost_usd": 0.1,
- "policies_checked": [
- "string"
], - "policies_triggered": [
- {
- "policy_id": "string",
- "policy_name": "string",
- "action": "block",
- "matched": "string",
- "resolution": "string"
}
], - "error_message": "string",
- "retry_count": 0,
- "approval_required": true,
- "approved_at": "2019-08-24T14:15:22Z",
- "approved_by": "string"
}
]
}Get all steps for an execution.
| id required | string Execution request ID |
[- {
- "request_id": "string",
- "step_index": 0,
- "step_name": "string",
- "status": "pending",
- "started_at": "2019-08-24T14:15:22Z",
- "completed_at": "2019-08-24T14:15:22Z",
- "duration_ms": 0,
- "input": { },
- "output": { },
- "provider": "string",
- "model": "string",
- "tokens_in": 0,
- "tokens_out": 0,
- "cost_usd": 0.1,
- "policies_checked": [
- "string"
], - "policies_triggered": [
- {
- "policy_id": "string",
- "policy_name": "string",
- "action": "block",
- "matched": "string",
- "resolution": "string"
}
], - "error_message": "string",
- "retry_count": 0,
- "approval_required": true,
- "approved_at": "2019-08-24T14:15:22Z",
- "approved_by": "string"
}
]Get a specific step by index.
| id required | string Execution request ID |
| stepIndex required | integer Step index (0-based) |
{- "request_id": "string",
- "step_index": 0,
- "step_name": "string",
- "status": "pending",
- "started_at": "2019-08-24T14:15:22Z",
- "completed_at": "2019-08-24T14:15:22Z",
- "duration_ms": 0,
- "input": { },
- "output": { },
- "provider": "string",
- "model": "string",
- "tokens_in": 0,
- "tokens_out": 0,
- "cost_usd": 0.1,
- "policies_checked": [
- "string"
], - "policies_triggered": [
- {
- "policy_id": "string",
- "policy_name": "string",
- "action": "block",
- "matched": "string",
- "resolution": "string"
}
], - "error_message": "string",
- "retry_count": 0,
- "approval_required": true,
- "approved_at": "2019-08-24T14:15:22Z",
- "approved_by": "string"
}Get a timeline view of execution steps with status indicators.
| id required | string Execution request ID |
[- {
- "step_index": 0,
- "step_name": "string",
- "status": "pending",
- "started_at": "2019-08-24T14:15:22Z",
- "completed_at": "2019-08-24T14:15:22Z",
- "duration_ms": 0,
- "has_error": true,
- "has_approval": true
}
]Export full execution record for compliance and auditing. Returns a downloadable JSON file.
| id required | string Execution request ID |
| format | string Default: "json" Export format (default json) |
| include_input | boolean Default: true Include step inputs (default true) |
| include_output | boolean Default: true Include step outputs (default true) |
| include_policies | boolean Default: true Include policy events (default true) |
{- "exported_at": "2019-08-24T14:15:22Z",
- "format": "string",
- "execution": {
- "summary": {
- "request_id": "string",
- "workflow_name": "string",
- "status": "pending",
- "total_steps": 0,
- "completed_steps": 0,
- "started_at": "2019-08-24T14:15:22Z",
- "completed_at": "2019-08-24T14:15:22Z",
- "duration_ms": 0,
- "total_tokens": 0,
- "total_cost_usd": 0.1,
- "org_id": "string",
- "tenant_id": "string",
- "user_id": "string",
- "error_message": "string",
- "input_summary": "string",
- "output_summary": "string"
}, - "steps": [
- {
- "request_id": "string",
- "step_index": 0,
- "step_name": "string",
- "status": "pending",
- "started_at": "2019-08-24T14:15:22Z",
- "completed_at": "2019-08-24T14:15:22Z",
- "duration_ms": 0,
- "input": { },
- "output": { },
- "provider": "string",
- "model": "string",
- "tokens_in": 0,
- "tokens_out": 0,
- "cost_usd": 0.1,
- "policies_checked": [
- "string"
], - "policies_triggered": [
- {
- "policy_id": "string",
- "policy_name": "string",
- "action": "block",
- "matched": "string",
- "resolution": "string"
}
], - "error_message": "string",
- "retry_count": 0,
- "approval_required": true,
- "approved_at": "2019-08-24T14:15:22Z",
- "approved_by": "string"
}
]
}
}Webhook subscription management for real-time event notifications. Subscribe to events like policy violations, workflow completions, budget alerts, etc.
Create a new webhook subscription to receive real-time event notifications. Events are delivered as HTTP POST requests to the specified URL with HMAC-SHA256 signatures when a secret is provided.
| url required | string <uri> URL to receive webhook event payloads |
| events required | Array of strings List of event types to subscribe to. Available events:
|
| secret | string Secret key for HMAC-SHA256 signature verification of webhook payloads |
| active | boolean Default: true Whether the subscription is active |
{- "events": [
- "policy.violation",
- "workflow.completed",
- "budget.exceeded"
], - "secret": "whsec_example_placeholder",
- "active": true
}{- "id": "wh_abc123",
- "events": [
- "policy.violation",
- "workflow.completed",
- "budget.exceeded"
], - "active": true,
- "tenant_id": "tenant-1",
- "org_id": "org-1",
- "secret": "whsec_example_placeholder",
- "created_at": "2026-01-17T10:00:00Z",
- "updated_at": "2026-01-17T10:00:00Z"
}{- "subscriptions": [
- {
- "id": "wh_abc123",
- "events": [
- "policy.violation",
- "workflow.completed"
], - "active": true,
- "tenant_id": "tenant-1",
- "org_id": "org-1",
- "created_at": "2026-01-17T10:00:00Z",
- "updated_at": "2026-01-17T10:00:00Z"
}
], - "total": 1
}Retrieve a specific webhook subscription by ID
| id required | string Example: wh_abc123 Webhook subscription ID |
{- "id": "wh_abc123",
- "events": [
- "policy.violation",
- "workflow.completed"
], - "active": true,
- "tenant_id": "tenant-1",
- "org_id": "org-1",
- "secret": "whsec_example_placeholder",
- "created_at": "2019-08-24T14:15:22Z",
- "updated_at": "2019-08-24T14:15:22Z"
}Update an existing webhook subscription
| id required | string Example: wh_abc123 Webhook subscription ID |
| url | string <uri> Updated URL to receive webhook event payloads |
| events | Array of strings Updated list of event types to subscribe to |
| active | boolean Whether the subscription is active |
{- "events": [
- "policy.violation",
- "workflow.completed",
- "workflow.failed"
], - "active": true
}{- "id": "wh_abc123",
- "events": [
- "policy.violation",
- "workflow.completed"
], - "active": true,
- "tenant_id": "tenant-1",
- "org_id": "org-1",
- "secret": "whsec_example_placeholder",
- "created_at": "2019-08-24T14:15:22Z",
- "updated_at": "2019-08-24T14:15:22Z"
}Budget management and LLM usage tracking for cost optimization. Supports budgets at organization, team, agent, workflow, and user scopes. Provides usage summaries, breakdowns, and pre-request budget checks.
Create a new budget with spending limits. Budgets can be scoped to organization, team, agent, workflow, or user level.
Enterprise only. These routes are not registered in Community edition, which returns 404 Not Found.
| X-Org-ID required | string Organization ID |
| id required | string |
| name required | string |
| scope required | string Enum: "organization" "team" "agent" "workflow" "user" |
| scope_id | string |
| limit_usd required | number <double> |
| period required | string Enum: "daily" "weekly" "monthly" "quarterly" "yearly" |
| on_exceed | string Default: "warn" Enum: "warn" "block" "downgrade" |
| alert_thresholds | Array of integers |
{- "id": "monthly-budget",
- "name": "Monthly Production Budget",
- "scope": "organization",
- "limit_usd": 1000,
- "period": "monthly",
- "on_exceed": "warn",
- "alert_thresholds": [
- 50,
- 80,
- 100
]
}{- "id": "string",
- "name": "string",
- "enabled": true,
- "scope": "organization",
- "scope_id": "string",
- "limit_usd": 0.1,
- "period": "daily",
- "on_exceed": "warn",
- "alert_thresholds": [
- 0
], - "org_id": "string",
- "tenant_id": "string",
- "created_at": "2019-08-24T14:15:22Z",
- "updated_at": "2019-08-24T14:15:22Z"
}List all budgets for the organization.
Enterprise only. These routes are not registered in Community edition, which returns 404 Not Found.
| scope | string Enum: "organization" "team" "agent" "workflow" "user" Filter by budget scope |
| limit | integer Default: 50 Maximum number of results |
| offset | integer Default: 0 Offset for pagination |
| X-Org-ID required | string Organization ID |
{- "budgets": [
- {
- "id": "string",
- "name": "string",
- "enabled": true,
- "scope": "organization",
- "scope_id": "string",
- "limit_usd": 0.1,
- "period": "daily",
- "on_exceed": "warn",
- "alert_thresholds": [
- 0
], - "org_id": "string",
- "tenant_id": "string",
- "created_at": "2019-08-24T14:15:22Z",
- "updated_at": "2019-08-24T14:15:22Z"
}
], - "count": 0
}Get a specific budget by ID.
Enterprise only. These routes are not registered in Community edition, which returns 404 Not Found.
| id required | string Budget ID |
{- "id": "string",
- "name": "string",
- "enabled": true,
- "scope": "organization",
- "scope_id": "string",
- "limit_usd": 0.1,
- "period": "daily",
- "on_exceed": "warn",
- "alert_thresholds": [
- 0
], - "org_id": "string",
- "tenant_id": "string",
- "created_at": "2019-08-24T14:15:22Z",
- "updated_at": "2019-08-24T14:15:22Z"
}Update an existing budget configuration.
Enterprise only. These routes are not registered in Community edition, which returns 404 Not Found.
| id required | string Budget ID |
| name | string |
| limit_usd | number <double> |
| on_exceed | string Enum: "warn" "block" "downgrade" |
| alert_thresholds | Array of integers |
{- "name": "string",
- "limit_usd": 0.1,
- "on_exceed": "warn",
- "alert_thresholds": [
- 0
]
}{- "id": "string",
- "name": "string",
- "enabled": true,
- "scope": "organization",
- "scope_id": "string",
- "limit_usd": 0.1,
- "period": "daily",
- "on_exceed": "warn",
- "alert_thresholds": [
- 0
], - "org_id": "string",
- "tenant_id": "string",
- "created_at": "2019-08-24T14:15:22Z",
- "updated_at": "2019-08-24T14:15:22Z"
}Get real-time status of a budget including current usage, remaining amount, and whether the budget is exceeded.
Enterprise only. These routes are not registered in Community edition, which returns 404 Not Found.
| id required | string Budget ID |
{- "budget": {
- "id": "monthly-budget",
- "name": "Monthly Production Budget",
- "scope": "organization",
- "limit_usd": 1000,
- "period": "monthly"
}, - "used_usd": 450.25,
- "remaining_usd": 549.75,
- "percentage": 45.025,
- "period_start": "2026-01-01T00:00:00Z",
- "period_end": "2026-02-01T00:00:00Z",
- "is_exceeded": false,
- "is_blocked": false
}Get alerts triggered for a specific budget.
Enterprise only. These routes are not registered in Community edition, which returns 404 Not Found.
| id required | string Budget ID |
| limit | integer Default: 50 Maximum number of alerts to return |
{- "alerts": [
- {
- "id": 0,
- "budget_id": "string",
- "threshold": 0,
- "percentage_reached": 0.1,
- "amount_usd": 0.1,
- "alert_type": "threshold_reached",
- "message": "string",
- "created_at": "2019-08-24T14:15:22Z",
- "acknowledged": true
}
], - "count": 0
}Check if a request should be allowed based on budget constraints. Returns whether the request is allowed and the applicable budget status.
Enterprise only. These routes are not registered in Community edition, which returns 404 Not Found.
| org_id required | string |
| team_id | string |
| agent_id | string |
| workflow_id | string |
| user_id | string |
{- "org_id": "your-org-id",
- "team_id": "engineering",
- "agent_id": "support-bot"
}{- "allowed": true
}Get aggregated LLM usage for the current period.
Available in both Community and Enterprise editions. Basic usage overview.
| period | string Default: "monthly" Enum: "daily" "weekly" "monthly" "quarterly" "yearly" Time period for aggregation |
| X-Org-ID required | string Organization ID |
{- "total_cost_usd": 450.25,
- "total_tokens_in": 1250000,
- "total_tokens_out": 375000,
- "total_requests": 5420,
- "average_cost_per_request": 0.083
}Get usage broken down by a specific dimension.
Enterprise only. These routes are not registered in Community edition, which returns 404 Not Found.
| group_by required | string Enum: "provider" "model" "agent" "team" "user" Dimension to group by |
| period | string Default: "monthly" Enum: "daily" "weekly" "monthly" "quarterly" "yearly" Time period for aggregation |
| X-Org-ID required | string Organization ID |
{- "group_by": "provider",
- "total_cost_usd": 450.25,
- "items": [
- {
- "group_by": "provider",
- "group_value": "anthropic",
- "cost_usd": 320.5,
- "tokens_in": 890000,
- "tokens_out": 245000,
- "request_count": 3200,
- "percentage": 71.2
}, - {
- "group_by": "provider",
- "group_value": "openai",
- "cost_usd": 129.75,
- "tokens_in": 360000,
- "tokens_out": 130000,
- "request_count": 2220,
- "percentage": 28.8
}
]
}List individual usage records with filtering.
Enterprise only. These routes are not registered in Community edition, which returns 404 Not Found.
| start_time | string <date-time> Filter records after this time |
| end_time | string <date-time> Filter records before this time |
| provider | string Filter by LLM provider |
| model | string Filter by model name |
| agent_id | string Filter by agent ID |
| limit | integer Default: 100 Maximum number of records |
| offset | integer Default: 0 Offset for pagination |
| X-Org-ID required | string Organization ID |
{- "records": [
- {
- "id": "string",
- "request_id": "string",
- "org_id": "string",
- "tenant_id": "string",
- "team_id": "string",
- "agent_id": "string",
- "user_id": "string",
- "workflow_id": "string",
- "provider": "string",
- "model": "string",
- "tokens_in": 0,
- "tokens_out": 0,
- "cost_usd": 0.1,
- "latency_ms": 0,
- "success": true,
- "error_message": "string",
- "created_at": "2019-08-24T14:15:22Z",
- "timestamp": "2019-08-24T14:15:22Z"
}
], - "count": 0,
- "total": 0
}Get pricing information for LLM models.
Available in both Community and Enterprise editions.
| provider | string Filter by provider name |
| model | string Filter by model name |
{- "provider": "anthropic",
- "model": "claude-sonnet-4",
- "pricing": {
- "input_per_1k": 0.003,
- "output_per_1k": 0.015
}
}Unified execution tracking and real-time streaming for MAP plans and WCP workflows. SSE streaming provides real-time status updates. Community: 5 concurrent connections per tenant. Enterprise: Unlimited.
Lists unified executions across both MAP plans and WCP workflows,
scoped to the tenant/org identified by the X-Tenant-ID and
X-Org-ID headers. The page size is capped by the license tier's
execution-history limit (at most 100 per page); out-of-range limit
or offset values are silently ignored and the defaults used.
| limit | integer [ 1 .. 100 ] Default: 20 Page size (default 20, max 100 or the tier history cap, whichever is lower) |
| offset | integer >= 0 Default: 0 Number of records to skip |
| execution_type | string Enum: "map_plan" "wcp_workflow" Filter by execution type |
| status | string Enum: "pending" "running" "completed" "failed" "cancelled" "aborted" "expired" Filter by execution status |
| X-Tenant-ID required | string Example: travel-us Tenant identifier scoping the request. The AxonFlow Agent gateway sets this header after authentication; the orchestrator fails closed when it is absent (401 on audit/decision endpoints, 400 on others — see each operation). Clients cannot widen their scope through it: handlers force the tenant filter from this header, never from the request body. |
| X-Org-ID required | string Organization identifier for scoping results |
{- "executions": [
- {
- "execution_id": "string",
- "execution_type": "map_plan",
- "name": "string",
- "source": "string",
- "status": "pending",
- "current_step_index": 0,
- "total_steps": 0,
- "progress_percent": 0.1,
- "started_at": "2019-08-24T14:15:22Z",
- "completed_at": "2019-08-24T14:15:22Z",
- "duration": "string",
- "estimated_cost_usd": 0.1,
- "actual_cost_usd": 0.1,
- "steps": [
- {
- "step_id": "string",
- "step_index": 0,
- "step_name": "string",
- "step_type": "llm_call",
- "status": "pending",
- "started_at": "2019-08-24T14:15:22Z",
- "ended_at": "2019-08-24T14:15:22Z",
- "duration": "string",
- "decision": "allow",
- "decision_reason": "string",
- "policies_matched": [
- "string"
], - "approval_status": "pending",
- "approved_by": "string",
- "approved_at": "2019-08-24T14:15:22Z",
- "rejected_by": "string",
- "rejected_at": "2019-08-24T14:15:22Z",
- "model": "string",
- "provider": "string",
- "cost_usd": 0.1,
- "tokens_in": 0,
- "tokens_out": 0,
- "input": null,
- "output": null,
- "result_summary": "string",
- "error": "string"
}
], - "error": "string",
- "tenant_id": "string",
- "org_id": "string",
- "user_id": "string",
- "client_id": "string",
- "metadata": { },
- "created_at": "2019-08-24T14:15:22Z",
- "updated_at": "2019-08-24T14:15:22Z"
}
], - "total": 0,
- "limit": 0,
- "offset": 0,
- "has_more": true
}Returns the unified status record for a MAP plan or WCP workflow
execution. The id is resolved across both subsystems (direct
execution id, plan_... plan ids, wf_/wcp_ workflow ids).
Requires both X-Tenant-ID and X-Org-ID; a tenant/org mismatch
returns 404 (not 403) to avoid a cross-tenant existence oracle.
| id required | string Execution id (or plan_/wf_/wcp_ prefixed subsystem id) |
| X-Tenant-ID required | string Example: travel-us Tenant identifier scoping the request. The AxonFlow Agent gateway sets this header after authentication; the orchestrator fails closed when it is absent (401 on audit/decision endpoints, 400 on others — see each operation). Clients cannot widen their scope through it: handlers force the tenant filter from this header, never from the request body. |
| X-Org-ID required | string Organization identifier for scoping results |
{- "execution_id": "string",
- "execution_type": "map_plan",
- "name": "string",
- "source": "string",
- "status": "pending",
- "current_step_index": 0,
- "total_steps": 0,
- "progress_percent": 0.1,
- "started_at": "2019-08-24T14:15:22Z",
- "completed_at": "2019-08-24T14:15:22Z",
- "duration": "string",
- "estimated_cost_usd": 0.1,
- "actual_cost_usd": 0.1,
- "steps": [
- {
- "step_id": "string",
- "step_index": 0,
- "step_name": "string",
- "step_type": "llm_call",
- "status": "pending",
- "started_at": "2019-08-24T14:15:22Z",
- "ended_at": "2019-08-24T14:15:22Z",
- "duration": "string",
- "decision": "allow",
- "decision_reason": "string",
- "policies_matched": [
- "string"
], - "approval_status": "pending",
- "approved_by": "string",
- "approved_at": "2019-08-24T14:15:22Z",
- "rejected_by": "string",
- "rejected_at": "2019-08-24T14:15:22Z",
- "model": "string",
- "provider": "string",
- "cost_usd": 0.1,
- "tokens_in": 0,
- "tokens_out": 0,
- "input": null,
- "output": null,
- "result_summary": "string",
- "error": "string"
}
], - "error": "string",
- "tenant_id": "string",
- "org_id": "string",
- "user_id": "string",
- "client_id": "string",
- "metadata": { },
- "created_at": "2019-08-24T14:15:22Z",
- "updated_at": "2019-08-24T14:15:22Z"
}Cancels a running MAP plan or WCP workflow through the unified API. The cancellation propagates to the owning subsystem (plan cancel or workflow abort). Cancelling an execution already in a terminal state returns 409.
| id required | string Execution id (or plan_/wf_/wcp_ prefixed subsystem id) |
| X-Tenant-ID required | string Example: travel-us Tenant identifier scoping the request. The AxonFlow Agent gateway sets this header after authentication; the orchestrator fails closed when it is absent (401 on audit/decision endpoints, 400 on others — see each operation). Clients cannot widen their scope through it: handlers force the tenant filter from this header, never from the request body. |
| X-Org-ID required | string Organization identifier for scoping results |
| reason | string Cancellation reason (defaults to "cancelled via unified API") |
{- "reason": "string"
}{- "execution_id": "string",
- "execution_type": "map_plan",
- "name": "string",
- "source": "string",
- "status": "pending",
- "current_step_index": 0,
- "total_steps": 0,
- "progress_percent": 0.1,
- "started_at": "2019-08-24T14:15:22Z",
- "completed_at": "2019-08-24T14:15:22Z",
- "duration": "string",
- "estimated_cost_usd": 0.1,
- "actual_cost_usd": 0.1,
- "steps": [
- {
- "step_id": "string",
- "step_index": 0,
- "step_name": "string",
- "step_type": "llm_call",
- "status": "pending",
- "started_at": "2019-08-24T14:15:22Z",
- "ended_at": "2019-08-24T14:15:22Z",
- "duration": "string",
- "decision": "allow",
- "decision_reason": "string",
- "policies_matched": [
- "string"
], - "approval_status": "pending",
- "approved_by": "string",
- "approved_at": "2019-08-24T14:15:22Z",
- "rejected_by": "string",
- "rejected_at": "2019-08-24T14:15:22Z",
- "model": "string",
- "provider": "string",
- "cost_usd": 0.1,
- "tokens_in": 0,
- "tokens_out": 0,
- "input": null,
- "output": null,
- "result_summary": "string",
- "error": "string"
}
], - "error": "string",
- "tenant_id": "string",
- "org_id": "string",
- "user_id": "string",
- "client_id": "string",
- "metadata": { },
- "created_at": "2019-08-24T14:15:22Z",
- "updated_at": "2019-08-24T14:15:22Z"
}Server-Sent Events stream for real-time execution status updates. Streams events for both MAP plan executions and WCP workflow executions. Community: Limited to 5 concurrent connections per tenant. Enterprise: Unlimited concurrent connections.
| id required | string |
| X-Tenant-ID required | string |
| X-Org-ID required | string Organization identifier. Like X-Tenant-ID, required by the unified-execution tenant-ownership check; missing either header is a 401. |
Multimodal image governance for LLM requests. Analyzes images for PII (via OCR), content safety, face/biometric detection, and document classification. Community tier provides fail-open governance with audit trail. Enterprise tier adds configurable enforcement and cloud analyzers.
Returns the media governance configuration for the current tenant.
{- "tenant_id": "string",
- "enabled": true,
- "allowed_analyzers": [
- "string"
], - "updated_at": "2019-08-24T14:15:22Z",
- "updated_by": "string"
}Updates media governance configuration. Enterprise tier only. Community and Evaluation tiers receive a 403 TIER_RESTRICTED response. To toggle system media policies on/off (available to all tiers), use the Dynamic Policy API (/api/v1/dynamic-policies) instead.
| enabled | boolean Enable or disable media governance |
| allowed_analyzers | Array of strings Restrict to specific analyzer types |
{- "enabled": true,
- "allowed_analyzers": [
- "string"
]
}{- "tenant_id": "string",
- "enabled": true,
- "allowed_analyzers": [
- "string"
], - "updated_at": "2019-08-24T14:15:22Z",
- "updated_by": "string"
}Exports the media governance audit trail (image analyses, policy actions, block decisions) for the tenant as JSON or CSV.
Enterprise only — non-paid tiers receive 403
(ENTERPRISE_REQUIRED). Tenant scope comes from the X-Tenant-ID
header. The export is capped at 10,000 rows, newest first.
| from | string <date-time> Window start (RFC3339). Defaults to 7 days ago. |
| to | string <date-time> Window end (RFC3339). Defaults to now. |
| format | string Default: "json" Enum: "json" "csv" Export format |
| X-Tenant-ID required | string Example: travel-us Tenant identifier scoping the request. The AxonFlow Agent gateway sets this header after authentication; the orchestrator fails closed when it is absent (401 on audit/decision endpoints, 400 on others — see each operation). Clients cannot widen their scope through it: handlers force the tenant filter from this header, never from the request body. |
{- "records": [
- {
- "request_id": "string",
- "tenant_id": "string",
- "timestamp": "2019-08-24T14:15:22Z",
- "media_type": "string",
- "analysis_results": { },
- "policy_actions": [
- "string"
], - "blocked": true
}
], - "tenant_id": "string",
- "from": "2019-08-24T14:15:22Z",
- "to": "2019-08-24T14:15:22Z",
- "count": 0
}List steps currently awaiting human approval for MAP-backed workflows —
workflows whose metadata carries a plan_id (MAP confirm / step mode).
Every returned entry has plan_id populated; this is the intentional
asymmetry with the WCP-plane listing at
/api/v1/workflows/approvals/pending, mirroring the approve/reject
asymmetry established in Issue #1677 / ADR-046.
Reviewer integrators that need to render plan context can read
plan_id directly without a second lookup; clients that want a
plane-neutral view can use /api/v1/hitl/queue instead.
Available on Evaluation+ licenses (same tier gate as the MAP
/steps/{step_id}/approve and /steps/{step_id}/reject endpoints).
| plan_id | string Filter to a single plan_id — returns only steps waiting on that plan. |
| limit | integer [ 1 .. 100 ] Default: 20 Maximum number of results to return |
{- "pending_approvals": [
- {
- "workflow_id": "wf_map_abc",
- "workflow_name": "map-confirm-plan-abc123",
- "plan_id": "plan-abc123",
- "step_id": "step_0_analyze",
- "step_index": 0,
- "step_name": "Analyze customer transaction",
- "step_type": "tool_call",
- "decision": "require_approval",
- "decision_reason": "High-value transaction requires review",
- "approval_status": "pending",
- "created_at": "2026-04-22T10:00:00Z"
}
], - "count": 1
}Runs all active policies against the provided input as a dry run. No audit writes or action application. Requires Evaluation or Enterprise license.
| query required | string The input text to simulate against all policies |
| request_type | string Request type (defaults to "simulation") |
object (UserContext) | |
object (ClientContext) | |
object |
{- "query": "string",
- "request_type": "string",
- "user": {
- "id": 0,
- "email": "string",
- "role": "string",
- "permissions": [
- "string"
], - "tenant_id": "string"
}, - "client": {
- "id": "string",
- "name": "string",
- "org_id": "string",
- "tenant_id": "string"
}, - "context": { }
}{- "allowed": true,
- "applied_policies": [
- "string"
], - "risk_score": 0,
- "required_actions": [
- "string"
], - "processing_time_ms": 0,
- "total_policies": 0,
- "dry_run": true,
- "simulated_at": "2019-08-24T14:15:22Z",
- "tier": "string",
- "daily_usage": {
- "used": 0,
- "limit": 0
}
}Tests a single policy against multiple inputs and returns aggregate statistics. Requires Evaluation or Enterprise license.
| policy_id required | string |
required | Array of objects |
{- "policy_id": "string",
- "inputs": [
- {
- "query": "string",
- "request_type": "string",
- "user": { },
- "context": { }
}
]
}{- "policy_id": "string",
- "total_inputs": 0,
- "matched": 0,
- "blocked": 0,
- "match_rate": 0,
- "block_rate": 0,
- "results": [
- {
- "input_index": 0,
- "matched": true,
- "blocked": true,
- "actions": [
- "string"
]
}
], - "processing_time_ms": 0,
- "generated_at": "2019-08-24T14:15:22Z",
- "tier": "string"
}Analyzes active policies for contradictions, shadows, and redundancies. Optionally filter to conflicts involving a specific policy. Requires Evaluation or Enterprise license.
| policy_id | string Optional — filter to conflicts involving this policy |
{- "policy_id": "string"
}{- "conflicts": [
- {
- "policy_a": {
- "id": "string",
- "name": "string",
- "type": "string"
}, - "policy_b": {
- "id": "string",
- "name": "string",
- "type": "string"
}, - "conflict_type": "contradictory_action",
- "description": "string",
- "severity": "high",
- "overlapping_field": "string"
}
], - "total_policies": 0,
- "conflict_count": 0,
- "checked_at": "2019-08-24T14:15:22Z",
- "tier": "string"
}Exports audit logs, workflow steps, and HITL approvals as a bundled JSON pack. Evaluation tier exports include a "NOT FOR REGULATORY SUBMISSION" watermark. Enterprise exports are clean (no watermark).
| start_date required | string Start date (YYYY-MM-DD or RFC3339) |
| end_date | string End date (defaults to now) |
| types | Array of strings Items Enum: "audit_logs" "workflow_steps" "hitl_approvals" Evidence types to include (defaults to all) |
| limit | integer Maximum records (capped by tier limit) |
{- "start_date": "string",
- "end_date": "string",
- "types": [
- "audit_logs"
], - "limit": 0
}{- "export_id": "string",
- "tenant_id": "string",
- "tier": "string",
- "date_range": {
- "start": "2019-08-24T14:15:22Z",
- "end": "2019-08-24T14:15:22Z"
}, - "disclaimer": "string",
- "record_count": 0,
- "audit_logs": [
- { }
], - "workflow_steps": [
- { }
], - "hitl_approvals": [
- { }
], - "exported_at": "2019-08-24T14:15:22Z",
- "daily_usage": {
- "used": 0,
- "limit": 0
}
}Returns counts of evidence records by type within the tier's lookback window.
{- "tenant_id": "string",
- "tier": "string",
- "window_days": 0,
- "counts": {
- "audit_logs": 0,
- "workflow_steps": 0,
- "hitl_approvals": 0,
- "total": 0
}, - "generated_at": "2019-08-24T14:15:22Z",
- "disclaimer": "string"
}