API Reference

This page is the quick endpoint index for the machine API.

It sits between the conceptual docs and the full HTTP reference:

  1. Machine API Overview explains the model, auth setup, and policy rules
  2. this page gives you the fastest route to the right endpoint or endpoint guide
  3. Detailed Machine API Reference covers full request and response details
  4. Machine Endpoint Inventory is the audited controller-level route list

Use the CLI or Node SDK unless you specifically need raw HTTP control.

If you are using R4 as a password manager for an agent runtime, follow this sequence first:

  1. Register Agent Public Key
  2. List Vaults
  3. List Vault Items
  4. Get Vault Field Value when you already know the fieldId
  5. Get Vault Item Detail when you need the whole item's values

The first successful public-key registration is what makes the agent eligible for security-group, project, and direct vault access. Operators should grant those access paths only after step 1 succeeds.

StepEndpointMethodPurpose
1/api/v1/machine/vault/public-keyPOSTRegister or rotate the runtime public key
2/api/v1/machine/vault/syncGETRead the full or delta vault sync payload for continuous runtimes
3/api/v1/machine/vaultGETList the vaults accessible to the API key
4/api/v1/machine/searchPOSTSearch machine-visible vault and license metadata
5/api/v1/machine/vault/:vaultId/public-keysGETFetch the signer directory for wrapped-DEK and checkpoint verification
6/api/v1/machine/vault/:vaultId/wrapped-keyGETFetch the wrapped vault DEK for the authenticated agent
7/api/v1/machine/vault/:vaultId/itemsGETList vault items with signed summary metadata
8/api/v1/machine/vault/:vaultId/fields/:fieldIdGETFetch one field ciphertext plus the parent signed detail checkpoint
9/api/v1/machine/vault/:vaultId/items/:itemIdGETFetch item ciphertext plus signed detail metadata

Rotating to a different runtime key still requires the current private key and, when the old key still has active vault access, a complete replacement wrapped-DEK batch.

Important Current Constraint

AGENT-scoped machine API keys are the supported runtime path for password retrieval, secret usage, and checkpoint-signed vault metadata writes when the runtime has an active registered encryption key.

Attachment parity, procurement flows, and outbound machine webhooks now live on the same machine API, but they still require the right endpoint permissions and any extra tenant or org roles. See Current Limitations.

Machine API keys can also be limited by policy. The simplest setup is machine.all, but least-privilege runtimes can choose grouped grants such as machine.vault.all or individual permissions such as machine.vault.read and machine.vault.secret.read.

If you are building a "master agent" that creates other agents, add machine.agent.all, machine.permissions.all, and the tenant role TENANT_AGENT_MANAGER.

Use Agent Orchestration and Permission Management when you are building delegated agent workflows instead of simple secret retrieval.

If you want machine-side metadata discovery without broad project/admin powers, add machine.search.read. Continuous runtimes that need full or delta sync should add machine.vault.sync.read or the grouped machine.vault.all.

If you are building a read-only observer or anomaly-detection runtime, add machine.monitoring.read. metric-stats, entity-counts, request-events, audit-events, and vault-activity-events are scoped to the authenticated machine session; system-stats and session-stats are reserved for global-admin-backed machine keys.

If the CLI, SDK, MCP server, or current raw machine API is missing a capability your AGENT runtime needs, submit product-gap feedback through POST /api/v1/machine/feedback.

Identity Endpoint

Inspect the current machine principal, scope, tenant binding, and write-path constraints.

EndpointMethodDescription
/api/v1/machine/meGETRead the authenticated API key, org/tenant/agent context, and warnings

Search Endpoints

Search machine-visible metadata without decrypting secret values.

EndpointMethodDescription
/api/v1/machine/searchPOSTSearch vaults, vault items, field labels, and eligible licenses

Project Endpoints

Manage projects and their associated resources programmatically.

EndpointMethodDescription
/api/v1/machine/projectGETList all projects
/api/v1/machine/projectPOSTCreate a new project
/api/v1/machine/project/:idGETGet project details

Agent Endpoints

Create and manage subordinate AGENT runtimes programmatically.

EndpointMethodDescription
/api/v1/machine/agentGETList agents in the current tenant, including each agent's domainTenantId
/api/v1/machine/agentPOSTCreate a new agent and receive its one-time API key
/api/v1/machine/agent/:idGETGet one agent
/api/v1/machine/agent/:idPATCHUpdate agent metadata or security groups
/api/v1/machine/agent/:id/archivePATCHArchive an agent
/api/v1/machine/agent/:id/regenerate-api-keyPOSTRotate the agent's API key
/api/v1/machine/agent/:id/vault-itemPATCHLink the agent API key to a vault item
/api/v1/machine/agent/:id/tenant-rolesGETRead direct and inherited tenant roles
/api/v1/machine/agent/:id/tenant-rolesPATCHReplace direct tenant roles

These routes require both the machine permission family (machine.agent.read / machine.agent.write) and the session tenant role TENANT_AGENT_MANAGER. See Agent Orchestration for the end-to-end lifecycle and delegation flow.

Feedback Endpoints

Report unsupported product capabilities from an AGENT runtime.

EndpointMethodDescription
/api/v1/machine/feedbackPOSTStore AGENT feedback about missing CLI, SDK, MCP, or machine-API features

This route is AGENT-only and requires machine.feedback.write or machine.feedback.all. Do not send secrets, plaintext credentials, or private user data in the feedback body.

Permission Endpoints

Manage project, vault, or vault-item access entries through the machine API.

EndpointMethodDescription
/api/v1/machine/permissions/:id/accessGETInspect the current caller's effective access to one asset
/api/v1/machine/permissions/:assetType/warning-messageGETRead asset-type-specific permission caveats
/api/v1/machine/permissions/security-groupsGETList security groups you can assign
/api/v1/machine/permissions/tenant-membersGETList tenant members you can assign
/api/v1/machine/permissions/projectsGETList projects you can assign
/api/v1/machine/permissions/agentsGETList agents you can assign
/api/v1/machine/permissions/PROJECT/:id/permissionsGETList current project permission rows
/api/v1/machine/permissions/PROJECT/:id/resolved-accessGETInspect resolved project access
/api/v1/machine/permissions/PROJECT/:id/set-permissionsPOSTReplace project permission rows
/api/v1/machine/permissions/VAULT/:id/permissionsGETList current vault permission rows
/api/v1/machine/permissions/VAULT/:id/resolved-accessGETInspect resolved vault access
/api/v1/machine/permissions/VAULT/:id/set-permissionsPOSTReplace vault permission rows
/api/v1/machine/permissions/VAULT_ITEM/:id/permissionsGETList current vault-item permission rows
/api/v1/machine/permissions/VAULT_ITEM/:id/resolved-accessGETInspect resolved vault-item access
/api/v1/machine/permissions/VAULT_ITEM/:id/set-permissionsPOSTReplace vault-item permission rows

Project permission edits are the simplest delegated-access flow. Vault and vault-item permission edits require checkpoint-backed writes, and vault items still inherit parent-vault access. See Permission Management for the full request body, helper endpoints, and orchestration order.

set-permissions replaces the full permission list. Include every entry you want to keep, including the caller's own ADMIN row.

Vault Endpoints

Access and manage vault items and secrets programmatically.

Vault metadata such as vault names, item names, field labels, and websites is not end-to-end encrypted. Only field values are end-to-end encrypted v3 vault envelopes.

EndpointMethodDescription
/api/v1/machine/vault/public-keyPOSTRegister or rotate the agent public key
/api/v1/machine/vault/syncGETRead the full or delta vault sync payload
/api/v1/machine/vaultPOSTCreate a vault with signed metadata
/api/v1/machine/vaultGETList vaults accessible to the API key
/api/v1/machine/vault/:vaultIdGETGet vault detail
/api/v1/machine/vault/:id/updatePATCHRename or reclassify a vault
/api/v1/machine/vault/:vaultIdDELETEArchive a vault
/api/v1/machine/vault/:vaultId/itemsPOSTCreate a vault item with signed checkpoints
/api/v1/machine/vault/:vaultId/itemsGETList vault items with signed checkpoint metadata
/api/v1/machine/vault/:vaultId/fields/:fieldIdGETGet one field value with signed parent-item metadata
/api/v1/machine/vault/:vaultId/items/:itemIdGETGet vault item detail with signed checkpoint metadata
/api/v1/machine/vault-item/:id/updatePATCHAdd, edit, or delete vault-item fields
/api/v1/machine/vault-item/:id/movePATCHMove a vault item to another vault
/api/v1/machine/vault/:vaultId/items/:itemIdDELETEArchive a vault item

For vault-group, vault-import, wrapped-key, user-key-pair, shared-item, and vaults-data routes, use the Machine Endpoint Inventory or the Detailed Machine API Reference.

Attachment Endpoints

Manage checkpointed vault attachments through the machine API.

EndpointMethodDescription
/api/v1/machine/attachments/:vaultId/initialize-multipart-uploadGETStart a multipart upload for a vault attachment
/api/v1/machine/attachments/:vaultId/get-multipart-pre-signed-urlsPOSTFetch presigned part URLs
/api/v1/machine/attachments/:vaultId/finalize-multipart-uploadPOSTFinalize the multipart upload with S3
/api/v1/machine/attachments/:vaultId/createPOSTCreate the attachment placeholder row
/api/v1/machine/attachments/:vaultId/assets/:assetId/finish-uploadPATCHPersist the signed attachment checkpoint
/api/v1/machine/attachments/:vaultId/assets/:assetId/download-ticketGETFetch a signed download ticket with checkpoint metadata

Marketplace Endpoints

Search the catalog, manage machine-owned carts, and checkout orders.

EndpointMethodDescription
/api/v1/machine/marketplace/catalog/allGETList the published marketplace catalog
/api/v1/machine/marketplace/catalog/searchGETSearch the catalog with filters
/api/v1/machine/marketplace/quotePOSTCompute a quote for a product configuration
/api/v1/machine/marketplace/create-cartPOSTCreate a machine-owned cart
/api/v1/machine/marketplace/add-to-cartPOSTAdd a quoted item to the current cart
/api/v1/machine/marketplace/:id/cartGETRead one machine-owned cart with aggregate quote
/api/v1/machine/marketplace/checkoutPOSTConvert the cart into an order

Webhook Endpoints

Create outbound webhook subscriptions for scoped machine events.

EndpointMethodDescription
/api/v1/machine/webhookGETList the current machine key's webhook endpoints
/api/v1/machine/webhookPOSTCreate a webhook endpoint and signing secret
/api/v1/machine/webhook/:id/testPOSTSend a signed synthetic test delivery
/api/v1/machine/webhook/:id/deliveriesGETRead delivery history for one endpoint

Domain Manager Endpoints

Manage DNS records for domains purchased through R4.

EndpointMethodDescription
/api/v1/machine/domain-manager/dns-recordsGETGet DNS records for a domain

Budget Endpoints

Inspect or create governed subject budgets through the machine billing surface.

EndpointMethodDescription
/api/v1/machine/budgetPOSTCreate an org, tenant, user, or agent budget
/api/v1/machine/budgetGETList visible budgets together with their active windows

Monitoring Endpoints

Read machine-visible monitoring data and platform health summaries.

EndpointMethodDescription
/api/v1/machine/monitoring/metric-statsGETRead API request metrics filtered to the current machine session
/api/v1/machine/monitoring/entity-countsGETRead visible entity counts filtered to the current machine session
/api/v1/machine/monitoring/request-eventsGETRead raw scoped request telemetry with correlation metadata
/api/v1/machine/monitoring/audit-eventsGETRead scoped security audit events for compliance or incident response
/api/v1/machine/monitoring/vault-activity-eventsGETRead a scoped cross-vault activity feed for secret-change polling
/api/v1/machine/monitoring/system-statsGETRead process and host health stats with a global-admin-backed machine key
/api/v1/machine/monitoring/session-statsGETRead aggregate session-store stats with a global-admin-backed machine key

Common Response Formats

Success Responses

All successful responses return JSON with a 2xx status code. The response body structure varies by endpoint.

Error Responses

All errors follow a consistent format:

{
  "error": {
    "code": "error_code",
    "message": "Human-readable error message"
  }
}

Common error codes:

CodeHTTP StatusDescription
unauthorized401Invalid or missing API key
missing_api_key401No API key provided in the request
invalid_api_key401The provided API key is invalid
project_not_found404The requested project was not found
domain_not_found404The requested domain was not found
domain_not_managed403The domain is not managed through R4

Pagination

Currently, endpoints return all results in a single response. Future endpoints may support pagination with the following format:

{
  "data": [...],
  "pagination": {
    "page": 1,
    "limit": 50,
    "total": 150,
    "totalPages": 3
  }
}

Query parameters for paginated endpoints:

ParameterTypeDefaultDescription
pagenumber1Page number (1-indexed)
limitnumber50Number of items per page (max 100)

Changelog

v1.10.0 (March 2026)

  • Added GET /api/v1/machine/me for machine identity, context, and capability introspection
  • Added POST /feedback for AGENT capability-gap feedback
  • Added the Submit Feedback endpoint guide and linked it from the agent-facing docs

v1.9.0 (March 2026)

  • Added links for the machine vault update, vault-item update, and vault-item move write paths
  • Added the audited Machine Endpoint Inventory

v1.8.0 (March 2026)

  • Added machine monitoring endpoints under /monitoring
  • Added scoped metric-stats and entity-counts reads for machine observers
  • Added global-admin-gated system-stats and session-stats for infrastructure monitoring

v1.7.0 (March 2026)

  • Added machine agent lifecycle endpoints under /agent
  • Added direct agent tenant-role reads/writes under /agent/:id/tenant-roles
  • Added machine project/vault permission management under /permissions/:assetType/:id/*

v1.6.0 (March 2026)

  • Added GET /vault/:vaultId/fields/:fieldId for narrow single-field reads with the parent signed detail checkpoint

v1.5.0 (March 2026)

  • Removed the legacy GET /vault/env/:projectId plaintext env endpoint
  • Added signed machine vault summary/detail checkpoint metadata to GET /vault/:vaultId/items and GET /vault/:vaultId/items/:itemId
  • Tightened machine vault writes so create/archive flows now require user-backed signed checkpoints and client-encrypted field values

v1.3.0 (February 2026)

  • Added POST /vault/:vaultId/items endpoint for creating vault items

v1.2.0 (January 2026)

  • Added GET /project endpoint for listing all projects
  • Added POST /project endpoint for creating projects

v1.1.0 (January 2026)

  • Added GET /project/:id endpoint for project details

v1.0.0 (January 2026)

  • Initial release
  • Added GET /domain-manager/dns-records endpoint