Anlyon API
Anlyon is the production execution runtime for AI agents. An agent invokes a named action; Anlyon resolves the action and its version, checks the caller’s scopes, evaluates policy, requests human approval when required, resolves credentials at dispatch, makes the production call itself, and records the outcome.
These guarantees cover actions routed through the hosted executor. A tool the caller’s own code invokes directly, with a credential that process holds, is not routed through Anlyon and is not governed by it.
Authentication
Developer API endpoints use a workspace API key as a bearer token:
Authorization: Bearer anlyon_your_api_key
API-key budget admission
Budgets reserve supported logical operations in Postgres with integer sub-cent cost accounting. They cover messages, event publishes, cache lookups, memory operations and action invocations; external provider bills and session callers are outside these caps. UTC calendar months own the reservations. Batches reserve all planned items before execution; partial failures retain that amount. Memory ingest reserves one job admission, not each generated chunk or token. Approval-pending actions reserve one invocation admission even before dispatch. These conservative admission estimates are distinct from invoice metering.
429 BUDGET_EXCEEDED refuses the whole admission. 503 BUDGET_RECONCILIATION_REQUIRED pauses keys whose legacy usage is unknown. A cached Idempotency-Key success replays normally. If that cache is lost or expires but a durable budget reservation exists, 409 BUDGET_EFFECT_ALREADY_RESERVED prevents executing the effect again. Investigate the original outcome before choosing a new key; a new key can duplicate work. Errors after admission keep their reservations until an operator proves no work occurred. Disabling or deleting a budget does not erase recorded usage.
Delivery signature environment attribution
Configured message and event-subscription signers emit legacy v1 plus signed
env/v2 attribution. v2 is HMAC-SHA256 over the exact UTF-8 string
anlyon-delivery-v2.${timestamp}.${environmentId}.${rawBody}. Receivers must
configure the expected environment independently; v1 alone provides no
environment boundary. Signing keys remain workspace-wide unless a subscription
uses its own secret. X-Anlyon-Environment-Id is reserved and informational,
not authority. Legacy queued work without recorded scope has no v2 claim.
See /verification for coverage, raw-body verification and staged migration.
Rate Limiting
Rate limits are based on your workspace plan:
- Free Plan: 300 requests/minute, 10,000 requests/hour
- Pay as You Go: Unlimited
- Enterprise: Custom limits
Error Handling
All errors follow a consistent format:
{
"success": false,
"error": {
"code": "ERROR_CODE",
"message": "Human-readable error message",
"details": {}
}
}
Common error codes:
AUTHENTICATION_ERROR- Invalid or missing API keyRATE_LIMIT_EXCEEDED- Too many requestsQUOTA_EXCEEDED- Usage quota exceededVALIDATION_ERROR- Invalid request dataNOT_FOUND- Resource not foundFEATURE_NOT_AVAILABLE- Feature not available on your plan
https://api.anlyon.comhttp://localhost:4000Messages
Publish and manage scheduled messages
- POSTPublish a single message
/api/v2/messages/publish - POSTPublish multiple messages in batch
/api/v2/messages/batch - GETList messages
/api/v2/messages - GETGet message status
/api/v2/messages/{messageId} - DELETECancel a scheduled message
/api/v2/messages/{messageId}
Schedules
Create and manage recurring schedules (cron jobs)
- GETList all schedules
/api/v2/schedules - POSTCreate a new schedule
/api/v2/schedules - GETGet a specific schedule
/api/v2/schedules/{scheduleId} - DELETEDelete a schedule
/api/v2/schedules/{scheduleId} - PATCHUpdate a schedule
/api/v2/schedules/{scheduleId} - POSTPause a schedule
/api/v2/schedules/{scheduleId}/pause - POSTResume a paused schedule
/api/v2/schedules/{scheduleId}/resume
URL Groups
Manage URL groups for broadcasting messages
- GETList URL groups
/api/v2/url-groups - POSTCreate a URL group
/api/v2/url-groups - GETGet a URL group
/api/v2/url-groups/{groupId} - DELETEDelete a URL group
/api/v2/url-groups/{groupId} - PATCHUpdate a URL group
/api/v2/url-groups/{groupId} - POSTAdd an endpoint to a URL group
/api/v2/url-groups/{groupId}/endpoints - DELETERemove an endpoint from a URL group
/api/v2/url-groups/{groupId}/endpoints/{endpointId} - POSTPublish to all endpoints in a group
/api/v2/url-groups/{groupId}/publish
Analytics
View analytics and usage statistics
- GETGet cross-product analytics overview
/api/v2/analytics/overview - GETGet agent analytics
/api/v2/analytics/agents - GETGet trust and control analytics
/api/v2/analytics/trust-control - GETGet delivery analytics
/api/v2/analytics/delivery - GETGet message analytics
/api/v2/analytics/messages - GETGet message time series data
/api/v2/analytics/time-series - GETGet top destination URLs
/api/v2/analytics/top-urls - GETGet current usage
/api/v2/analytics/usage/current - GETGet usage history
/api/v2/analytics/usage/history - GETGet schedule statistics
/api/v2/analytics/schedules - GETList recent schedule execution summaries
/api/v2/analytics/schedule-executions - GETGet failed-message error distribution
/api/v2/analytics/errors - GETGet workspace onboarding progress
/api/v2/analytics/onboarding
Billing
Manage billing, plans, and usage
- GETRead workspace overage alert target
/api/v2/billing/budget - GETGet current plan details
/api/v2/billing/plan - GETGet current billing period usage
/api/v2/billing/usage/current - GETList available plans
/api/v2/billing/plans - GETGet current quota utilization
/api/v2/billing/quota - GETGet daily billing usage history
/api/v2/billing/usage/history - GETEstimate current-month cost
/api/v2/billing/cost-estimate - GETList workspace invoices
/api/v2/billing/invoices - GETGet browser-safe Stripe configuration
/api/v2/billing/stripe-config
Notifications
Manage notifications and preferences
- GETList notifications
/api/v2/notifications - PATCHMark notification as read
/api/v2/notifications/{id}/read - PATCHMark all notifications as read
/api/v2/notifications/read-all - GETGet notification preferences
/api/v2/notifications/preferences - PATCHUpdate notification preferences
/api/v2/notifications/preferences - GETGet unread notification count
/api/v2/notifications/unread-count - DELETEDismiss a notification
/api/v2/notifications/{id} - GETGet your own notification preferences
/api/v2/notifications/preferences/me - PATCHUpdate your own notification preferences
/api/v2/notifications/preferences/me - POSTSend a test notification webhook
/api/v2/notifications/preferences/test-webhook
Sessions
Persist agent conversation threads and prompt-ready history
- GETList sessions
/api/v2/sessions - POSTCreate a session
/api/v2/sessions - GETGet a session
/api/v2/sessions/{id} - DELETEDelete a session
/api/v2/sessions/{id} - PATCHUpdate a session
/api/v2/sessions/{id} - GETList session messages
/api/v2/sessions/{id}/messages - POSTAppend session messages
/api/v2/sessions/{id}/messages - DELETEClear session messages
/api/v2/sessions/{id}/messages - DELETEPop the newest session message
/api/v2/sessions/{id}/messages/last - GETGet prompt-ready session context
/api/v2/sessions/{id}/context
Context
Assemble memory and session state into prompt-ready context
Actions
Define and invoke secret-backed hosted tools
- GETList actions
/api/v2/actions - POSTCreate an action
/api/v2/actions - POSTImport actions from OpenAPI
/api/v2/actions/import - GETList action invocations
/api/v2/actions/invocations - GETGet an action invocation
/api/v2/actions/invocations/{id} - GETGet an action
/api/v2/actions/{ref} - DELETEDelete an action
/api/v2/actions/{ref} - PATCHUpdate an action
/api/v2/actions/{ref} - POSTInvoke an action
/api/v2/actions/{ref}/invoke - GETList one action's immutable versions
/api/v2/actions/{ref}/versions - GETList governed effects
/api/v2/actions/effects - GETGet an effect with its evidence
/api/v2/actions/effects/{id} - POSTReconcile an effect now
/api/v2/actions/effects/{id}/reconcile - POSTAdd an investigation note
/api/v2/actions/effects/{id}/notes - POSTRecord a manual resolution
/api/v2/actions/effects/{id}/resolve - POSTReplay a lost write under the same identity
/api/v2/actions/effects/{id}/replay - GETGet a preview
/api/v2/actions/previews/{id} - POSTRefresh a preview's evidence
/api/v2/actions/previews/{id}/refresh - POSTPreview a governed invocation
/api/v2/actions/{ref}/previews - POSTResolve an unknown invocation
/api/v2/actions/invocations/{id}/resolve - GETList one action's invocations
/api/v2/actions/{ref}/invocations
Impact Limits
Shared business-impact limits (money, resource mutations) that governed effects reserve before dispatch. Separate from Budgets, which cap Anlyon usage.
- GETList impact limits
/api/v2/impact-limits - POSTCreate an impact limit
/api/v2/impact-limits - GETGet an impact limit
/api/v2/impact-limits/{id} - DELETEArchive an impact limit
/api/v2/impact-limits/{id} - PATCHUpdate an impact limit
/api/v2/impact-limits/{id}
Approval Policies
Configure the environment-scoped rules that decide whether a request needs approval, is auto-approved, or is auto-denied. Operator credentials only.
- POSTEvaluate current policies without executing
/api/v2/approval-policies/evaluate - GETList approval policies
/api/v2/approval-policies - POSTCreate an approval policy
/api/v2/approval-policies - POSTPlan a policy file
/api/v2/approval-policies/files/plan - POSTApply a policy file
/api/v2/approval-policies/files/apply - POSTTest a policy file against fixture requests
/api/v2/approval-policies/files/test - GETRead immutable policy history
/api/v2/approval-policies/{policyId}/versions - GETRead one policy version
/api/v2/approval-policies/{policyId}/versions/{version} - GETGet an approval policy
/api/v2/approval-policies/{policyId} - DELETEDelete an approval policy
/api/v2/approval-policies/{policyId} - PATCHUpdate an approval policy
/api/v2/approval-policies/{policyId}
Authentication
Inspect the credential making the request
Approvals
Create and decide human-in-the-loop safety gates
- GETList approvals
/api/v2/approvals - POSTRequest an approval
/api/v2/approvals - GETGet or wait for an approval
/api/v2/approvals/{id} - POSTApprove a request
/api/v2/approvals/{id}/approve - POSTDeny a request
/api/v2/approvals/{id}/deny
Budgets
Control per-API-key usage and estimated spend
- GETList API-key budgets
/api/v2/budgets - GETGet an API-key budget
/api/v2/budgets/{apiKeyId} - PUTCreate or replace an API-key budget
/api/v2/budgets/{apiKeyId} - DELETEDelete an API-key budget
/api/v2/budgets/{apiKeyId}
Secrets
Store write-only credentials used by hosted actions
- GETList secret metadata
/api/v2/secrets - GETGet secret metadata
/api/v2/secrets/{name} - PUTCreate or rotate a secret
/api/v2/secrets/{name} - DELETEDelete a secret
/api/v2/secrets/{name}
Files
Upload, inspect, download, and delete workspace files
- GETList files
/api/v2/files - POSTUpload a file directly
/api/v2/files - POSTCreate a presigned file upload
/api/v2/files/presign - GETGet file metadata
/api/v2/files/{fileId} - DELETEDelete a file
/api/v2/files/{fileId} - POSTConfirm a presigned upload
/api/v2/files/{fileId}/confirm - GETDownload a file
/api/v2/files/{fileId}/download
Cache
Store and semantically retrieve reusable model results
- GETList semantic cache entries
/api/v2/cache - POSTStore a semantic cache entry
/api/v2/cache - POSTLook up a semantic cache entry
/api/v2/cache/lookup - POSTFlush semantic cache entries
/api/v2/cache/flush - GETGet semantic cache statistics
/api/v2/cache/stats - GETGet a semantic cache entry
/api/v2/cache/{entryId} - DELETEDelete a semantic cache entry
/api/v2/cache/{entryId}
Events
Publish typed events and deliver them to filtered webhook subscriptions
- GETList event topics
/api/v2/events/topics - POSTCreate an event topic
/api/v2/events/topics - GETGet an event topic
/api/v2/events/topics/{ref} - DELETEDelete an event topic
/api/v2/events/topics/{ref} - PATCHUpdate an event topic
/api/v2/events/topics/{ref} - GETList topic subscriptions
/api/v2/events/topics/{ref}/subscriptions - POSTCreate a webhook subscription
/api/v2/events/topics/{ref}/subscriptions - DELETEDelete a webhook subscription
/api/v2/events/subscriptions/{subscriptionId} - PATCHUpdate a webhook subscription
/api/v2/events/subscriptions/{subscriptionId} - POSTRotate a subscription signing secret
/api/v2/events/subscriptions/{subscriptionId}/rotate-secret - GETList published events
/api/v2/events - POSTPublish an event
/api/v2/events - GETGet an event and its deliveries
/api/v2/events/{eventId}
DLQ
Inspect, retry, and permanently remove exhausted message deliveries
- GETList failed messages
/api/v2/dlq - DELETEPermanently clear the DLQ
/api/v2/dlq - GETGet DLQ statistics
/api/v2/dlq/stats - POSTRetry failed messages
/api/v2/dlq/retry-all - GETGet a failed message
/api/v2/dlq/{messageId} - DELETEPermanently delete a failed message
/api/v2/dlq/{messageId} - POSTRetry a failed message
/api/v2/dlq/{messageId}/retry
Flow Control
Coordinate per-key rate limits, parallelism, pausing, and delivery waitlists
- GETList flow-control keys
/api/v2/flow-control - POSTCreate a flow-control key
/api/v2/flow-control - GETGet a flow-control key
/api/v2/flow-control/{flowControlKeyId} - DELETEDelete a flow-control key
/api/v2/flow-control/{flowControlKeyId} - PATCHUpdate a flow-control key
/api/v2/flow-control/{flowControlKeyId} - POSTPause waitlist release
/api/v2/flow-control/{flowControlKeyId}/pause - POSTResume waitlist release
/api/v2/flow-control/{flowControlKeyId}/resume - POSTPin flow-control configuration
/api/v2/flow-control/{flowControlKeyId}/pin - POSTUnpin flow-control configuration
/api/v2/flow-control/{flowControlKeyId}/unpin - POSTReset the current rate counter
/api/v2/flow-control/{flowControlKeyId}/reset-rate - GETGet live flow-control status
/api/v2/flow-control/{flowControlKeyId}/status
Integrations
Connect Slack and Discord notification destinations without exposing stored credentials
- GETList workspace integrations
/api/v2/integrations - POSTCreate a Discord webhook integration
/api/v2/integrations/discord - POSTSend a Discord test notification
/api/v2/integrations/discord/{id}/test - GETList Slack channels
/api/v2/integrations/slack/{id}/channels - PATCHSelect a Slack channel
/api/v2/integrations/slack/{id}/channel - POSTSend a Slack test notification
/api/v2/integrations/slack/{id}/test - DELETEDelete an integration
/api/v2/integrations/{id} - PATCHEnable or disable an integration
/api/v2/integrations/{id}/toggle - PATCHUpdate integration event types
/api/v2/integrations/{id}/events
Logs
Query, inspect, and export redacted message and schedule execution history
- GETQuery unified execution logs
/api/v2/logs - GETGet detailed execution-log statistics
/api/v2/logs/stats - GETExport up to 10,000 execution logs
/api/v2/logs/export - GETList execution logs for a message
/api/v2/messages/{messageId}/logs - GETList execution logs for a schedule
/api/v2/schedules/{scheduleId}/logs
Queues
Configure isolated message streams with parallelism, pause/resume controls, and live lag
- GETList queues
/api/v2/queues - POSTCreate a queue
/api/v2/queues - GETGet a queue
/api/v2/queues/{queueId} - DELETESoft-delete a queue
/api/v2/queues/{queueId} - PATCHUpdate a queue
/api/v2/queues/{queueId} - POSTPause a queue
/api/v2/queues/{queueId}/pause - POSTResume a queue
/api/v2/queues/{queueId}/resume
Workflows
Define callback-driven workflows, trigger runs, inspect steps, and resume event waits
- GETList workflows
/api/v2/workflows - POSTCreate a workflow
/api/v2/workflows - GETList workflow runs
/api/v2/workflows/runs - GETGet a workflow run
/api/v2/workflows/runs/{runId} - GETList steps for a workflow run
/api/v2/workflows/runs/{runId}/steps - POSTCancel a workflow run
/api/v2/workflows/runs/{runId}/cancel - POSTNotify workflows waiting for an event
/api/v2/workflows/events/notify - GETGet a workflow
/api/v2/workflows/{workflowId} - DELETEDelete a workflow and its runs
/api/v2/workflows/{workflowId} - PATCHUpdate a workflow
/api/v2/workflows/{workflowId} - POSTTrigger a workflow run
/api/v2/workflows/{workflowId}/trigger
Memory
- GETList memories
/api/v2/memory - POSTRemember (store a memory)
/api/v2/memory - POSTBatch remember (v1.1)
/api/v2/memory/batch - POSTRecall (semantic/hybrid search)
/api/v2/memory/recall - POSTBatch forget by ids or documentId
/api/v2/memory/forget - POSTIngest a document (async)
/api/v2/memory/ingest - POSTUpload a file to R2 (v1.1)
/api/v2/memory/files - POSTSummarize memories (sync, v1.1)
/api/v2/memory/summarize - POSTConsolidate memories (async, v1.1)
/api/v2/memory/consolidate - GETGet job status
/api/v2/memory/jobs/{jobId} - GETGet a single memory
/api/v2/memory/{memoryId} - DELETEForget a single memory
/api/v2/memory/{memoryId} - GETList collections
/api/v2/memory/collections - POSTCreate a collection
/api/v2/memory/collections - GETGet a collection
/api/v2/memory/collections/{collectionId} - DELETEDelete a collection (cascades to memories)
/api/v2/memory/collections/{collectionId} - PATCHUpdate a collection
/api/v2/memory/collections/{collectionId} - POSTMigrate collection to new embedding model (v1.1)
/api/v2/memory/collections/{collectionId}/migrate
Stream
Runs
- GETList runs
/api/v2/runs - POSTStart a run
/api/v2/runs - POSTImport an OTLP/JSON trace
/api/v2/runs/import - GETGet a run with its span tree
/api/v2/runs/{runId} - PATCHEnd or update a run
/api/v2/runs/{runId} - GETExport a run as OTLP/JSON
/api/v2/runs/{runId}/export - GETList feedback for a run
/api/v2/runs/{runId}/feedback - POSTAttach feedback to a run
/api/v2/runs/{runId}/feedback - POSTIngest spans
/api/v2/runs/{runId}/spans

