Docs/Api Reference/Governance Api

Governance API

The governance API lets your own systems, such as a GRC tool, a CMDB or a compliance pipeline, read the governance, inventory and policy records that ANTS Platform keeps:

  • Agents and their governance profiles
  • Framework coverage per compliance framework for a project
  • Guardrail policies, one per agent
  • The AI tool registry used by Discover AI
  • Sanctions: the sanction status of each AI tool
  • Model approvals from the AI Inventory

It can also change three kinds of record: an agent's governance profile, an agent's guardrail policy, and a tool's sanction status. Writes use the same validation and side effects as the app.

Every read and every write is recorded in the audit log.

ℹ

The API is off by default. Your ANTS deployment must have it turned on, and an organization admin must turn it on for the organization. See Turn it on. Writes also need an organization key with Governance write.

Base path

All governance endpoints live under:

code
https://<your-host>/api/public/v1/governance

Use the same host as the rest of the public API. Paths on this page are relative to /api/public/v1/governance.

Turn it on

Three conditions must all hold before the API returns data. If any one is missing, every governance endpoint answers 404.

ConditionWhereDefault
The deployment allows the governance public APIYour ANTS deployment must have the governance public API turned on; ask your ANTS administrator.Off
The organization has turned it onOrganization Settings → Features → Governance public APIOff
The organization's plan includes Enterprise governanceBilling & Plans (Enterprise plans)

Organization API keys also need the organization API keys and Admin API entitlement (admin-api, Enterprise plans). Project keys do not.

Check that the deployment allows it

The Governance public API row appears on the Features tab only when your deployment has the API turned on. If you do not see it, ask your ANTS administrator.

Turn on the setting

Open Organization Settings → Features and turn on Governance public API. If your deployment uses step-up verification, you are asked for the code sent to your email.

Choose the access

Once the API is on, an Access selector appears under it:

  • Read only (the default): keys can read, and every write answers 403.
  • Read and write: organization keys that have Governance write turned on can change sanctions, guardrail policies and governance profiles.

Switching to Read and write also asks for step-up verification when it is enabled.

Allow specific keys to write

Read and write mode on its own lets no key write. Open Organization Settings → API Keys and turn on Governance write for each organization key that should be able to change governance data. The column is shown only when your deployment has the API turned on. Turning it on for a key asks for step-up verification when it is enabled.

Who can change these settings

SettingPermissionBuilt-in roles
Governance public API and AccesstenantSecurity.features:adminOwner and Security & Compliance
Governance write on an organization keyorganization:CRUD_apiKeysOwner

A custom role grants the first through Organization features & MFA at the Admin level.

Turning the API off, switching back to Read only, and turning Governance write off for a key do not ask for step-up. Turning the API off also resets the access to Read only, so turning it back on never restores write access by itself. Governance write is off for every key until an admin turns it on, including keys created before the API was available.

Every change to these settings is written to the audit log.

Authentication

Use HTTP Basic auth with an API key pair, the same as the rest of the public API: the public key (pk-ap-...) as the username and the secret key (sk-ap-...) as the password. See Authentication.

bash
curl "https://<your-host>/api/public/v1/governance/agents" \ -u "pk-ap-...:sk-ap-..."

Which key to use

EndpointsProject keyOrganization key
Project reads: agents, governance profiles, guardrail policies, framework coverageReads its own project. projectId is optional; if you send it, it must be the key's project, otherwise 403.projectId is required (400 without it) and must be a project of the key's organization, otherwise 404.
Organization reads: AI tools, sanctions, model approvals403Allowed
All writes403Allowed only for a key with Governance write on, while the access is Read and write

Every write needs an organization key. Project keys live in application code next to the agents they belong to, so a leaked project key cannot loosen its own agent's guardrail policy, change its risk tier or sanction a tool for the whole organization.

Other credentials, such as Discover AI enrollment keys, are refused with 403. On a deployment where project keys are limited to trace ingestion, project keys are refused with 403 here too; organization keys still work.

Pagination

Every list endpoint takes:

ParameterDescription
pagePage number, starting at 1. Default 1.
limitItems per page, 1 to 100. Default 50.

and returns:

json
{ "data": [], "meta": { "page": 1, "limit": 50, "totalItems": 0, "totalPages": 0 } }

A page past the end returns an empty data list. Timestamps are ISO 8601 strings in UTC.

Endpoints

Agents

MethodPathPurposeKey
GET/agentsList the agents of a projectProject or organization
GET/agents/{agentId}Get one agentProject or organization

Query parameters for GET /agents, besides page, limit and projectId:

ParameterDescription
searchCase-insensitive match on the name or display name
riskTierUNACCEPTABLE, HIGH, LIMITED, MINIMAL or NOT_CLASSIFIED
stageDeployment stage from the governance profile, case-insensitive
platformPlatform as returned in platform, for example sdk, aws-bedrock or google-vertex

Agents are ordered by name, then by ID.

bash
curl "https://<your-host>/api/public/v1/governance/agents?riskTier=HIGH&limit=1" \ -u "pk-ap-...:sk-ap-..."
json
{ "data": [ { "id": "7c1e9a04b2d35f86", "projectId": "cm4p8x2qk0003lm07abcd1234", "name": "invoice-reader", "displayName": "Invoice Reader", "platform": "sdk", "governanceStatus": "APPROVED", "owner": "Finance Automation", "purpose": "Extracts line items from supplier invoices", "riskTier": "HIGH", "stage": "Production", "models": ["gpt-4o", "gpt-4o-mini"], "lastActiveAt": "2026-10-24T08:12:40Z", "declaredTools": ["erp-lookup"], "dataSources": ["Supplier invoices"], "createdAt": "2026-06-02T14:05:11.000Z", "updatedAt": "2026-10-20T09:30:02.000Z" } ], "meta": { "page": 1, "limit": 1, "totalItems": 3, "totalPages": 3 } }
FieldMeaning
idThe agent ID
nameThe agent's system name
displayNameThe display name, or the name when none is set
platformWhere the agent runs: aws-bedrock or google-vertex for agents found in a cloud inventory, otherwise the platform its tags point to (such as crewai, claude-code, codex, copilot or cowork), otherwise sdk
governanceStatusThe governance profile status (DRAFT, PENDING_REVIEW, CHANGES_REQUESTED, APPROVED or ARCHIVED), or null when the agent has no profile
owner, purpose, riskTier, stageOwning team, business purpose, EU AI Act risk tier and deployment stage from the governance profile
modelsModels the agent called in the last 24 hours. null when usage data is temporarily unavailable.
lastActiveAtLast traced activity in the last 24 hours, or null
declaredToolsTools declared on the governance profile
dataSourcesInference-time data sources from the governance profile

Agent tags are not returned.

Governance profiles

MethodPathPurposeKey
GET/agents/{agentId}/profileGet an agent's governance profileProject or organization
PATCH/agents/{agentId}/profile?projectId=...Update profile fieldsOrganization, with Governance write

GET answers 404 when the agent has no governance profile. See Evidence Collection and Compliance for what the fields mean.

FieldMeaning
agentId, projectIdIdentity
statusDRAFT, PENDING_REVIEW, CHANGES_REQUESTED, APPROVED or ARCHIVED
riskTierUNACCEPTABLE, HIGH, LIMITED, MINIMAL or NOT_CLASSIFIED
euAiActClassification, euAiActAnnexIiiCategoryFrom the risk classification evidence
useCaseName, owner, purpose, stageFrom the use case evidence
dataSources, trainingDataSource, dataOwnerName, dataOwnerEmailFrom the data governance evidence
declaredToolsDeclared tools. Set them in the app on the agent's profile card; PATCH does not change them.
selectedFrameworksAny of EU_AI_ACT, ISO_42001, NIST_AI_RMF, SOC_2, ISO_27001, NIST_CSF_2
coveragePercentageShare of evidence filled in, 0 to 100
frameworkCoveragePer selected framework: total, complete and percentage
activeDriftAlertsNumber of open drift alerts
approvedAt, createdAt, updatedAtTimestamps

Update a governance profile

Send only the fields to change. At least one is required, and unknown fields are refused with 400.

FieldDescription
ownerOwning team, up to 500 characters
purposeBusiness purpose, up to 5,000 characters
stageDeployment stage, up to 100 characters. null clears it.
dataSourcesInference-time data sources, up to 100 entries of up to 500 characters. Replaces the whole list.
riskTierUNACCEPTABLE, HIGH, LIMITED, MINIMAL or NOT_CLASSIFIED
bash
curl -X PATCH "https://<your-host>/api/public/v1/governance/agents/7c1e9a04b2d35f86/profile?projectId=cm4p8x2qk0003lm07abcd1234" \ -u "pk-ap-...:sk-ap-..." \ -H "Content-Type: application/json" \ -d '{ "owner": "Finance Automation", "stage": "Production", "riskTier": "LIMITED" }'

The response is the updated profile, in the same shape as GET. The profile must already exist; create it in the app. Coverage and framework compliance are recalculated as they are when you edit the profile in the app. If the profile has no use case evidence (for owner, purpose or stage) or no data governance evidence (for dataSources), the request answers 404 and nothing is changed.

Framework coverage

MethodPathPurposeKey
GET/framework-coverageCompliance coverage per framework across a project's agentsProject or organization

This is the per-framework block of the governance dashboard. It returns one entry for each framework (EU_AI_ACT, ISO_42001, NIST_AI_RMF, SOC_2, ISO_27001, NIST_CSF_2), or an empty list when no agent in the project has a governance profile. It is not paginated.

json
{ "projectId": "cm4p8x2qk0003lm07abcd1234", "frameworks": [ { "framework": "EU_AI_ACT", "averageCoverage": 72, "agentsWithFullCoverage": 1, "totalAgentsWithFramework": 4, "totalRequirements": 40, "completedRequirements": 18, "partialRequirements": 15, "gapRequirements": 7 } ] }

A requirement counts as completed when every agent with a record for it has it complete, as partial when it has records but not all are complete, and as a gap when no agent has a record for it.

Guardrail policies

Guardrail policies are set per agent. There is no project-wide policy. See AI Guardrails.

MethodPathPurposeKey
GET/guardrail-policiesList a project's guardrail policiesProject or organization
GET/agents/{agentId}/guardrail-policyGet an agent's guardrail policyProject or organization
PUT/agents/{agentId}/guardrail-policy?projectId=...Create or update an agent's guardrail policyOrganization, with Governance write

GET /guardrail-policies takes enabled (true or false) to filter on whether real-time enforcement is on, besides page, limit and projectId. Policies are ordered by agent name, then by ID. GET /agents/{agentId}/guardrail-policy answers 404 when the agent has no policy.

json
{ "id": "cm6t1r9zx0011pq02efgh5678", "projectId": "cm4p8x2qk0003lm07abcd1234", "agentId": "7c1e9a04b2d35f86", "agentName": "invoice-reader", "enabled": true, "action": "ENFORCE", "redactEnabled": true, "categoryActions": { "pci": "BLOCK" }, "effectiveCategoryActions": { "pii": "REDACT", "pci": "BLOCK", "phi": "REDACT", "ethicsBias": "BLOCK", "safety": "BLOCK" }, "labels": { "pii": ["person", "email", "phone number"], "pci": ["credit card number", "cvv"], "phi": [], "ethicsBias": [], "safety": [] }, "minConfidenceScore": 0.5, "blockedMessage": "This request was blocked by company AI policy.", "deploymentMode": "ANTS_HOSTED", "createdAt": "2026-07-14T10:02:44.000Z", "updatedAt": "2026-10-21T16:45:09.000Z" }
FieldMeaning
id, projectId, agentNameIdentity
agentIdThe agent ID, or null for a policy saved before the agent first sent data
enabledWhether real-time enforcement is on
actionALLOW (Audit Only) or ENFORCE
redactEnabledWith ENFORCE, mask detected values instead of blocking
categoryActionsActions set per category, as stored, or null when the policy uses one action for every category
effectiveCategoryActionsThe action each category actually gets: its own action, or the policy's single action when it has none
labelsSelected detection labels per category
minConfidenceScoreDetection threshold, 0 to 1
blockedMessageThe Blocked Response Message, or null
deploymentModeANTS_HOSTED or SELF_HOSTED

Create or update a guardrail policy

Send only the fields to change. At least one is required, and unknown fields are refused with 400.

FieldDescription
enabledTurn real-time enforcement on or off
actionALLOW or ENFORCE
redactEnabledWith ENFORCE, mask values instead of blocking
categoryActionsAn action per category: pii, pci, phi, ethicsBias, safety, each AUDIT_ONLY, WARN, REDACT or BLOCK. REDACT is accepted only for pii, pci and phi. null removes the per-category actions so the single action applies to every category.
labelsAn object with any of pii, pci, phi, ethicsBias and safety. Each list you send replaces the stored list for that category; up to 200 labels of up to 100 characters each. Use the label names the policy editor uses, such as person, email or credit card number.
minConfidenceScore0 to 1
blockedMessageUp to 2,000 characters. null clears it.
bash
curl -X PUT "https://<your-host>/api/public/v1/governance/agents/7c1e9a04b2d35f86/guardrail-policy?projectId=cm4p8x2qk0003lm07abcd1234" \ -u "pk-ap-...:sk-ap-..." \ -H "Content-Type: application/json" \ -d '{ "enabled": true, "action": "ENFORCE", "categoryActions": { "pii": "REDACT", "pci": "BLOCK", "safety": "WARN" }, "blockedMessage": "This request was blocked by company AI policy." }'

The response is the saved policy, in the same shape as GET. The agent must exist in the project. If it has no policy yet, one is created from the app's defaults: real-time enforcement off, Audit Only, no labels and a confidence threshold of 0.5. Settings the API does not manage, such as the Scheduled Detection schedule, PagerDuty alerting and custom detectors, are kept as they are. The SDK policy cache is refreshed, so SDKs pick up the change on their next policy lookup.

AI tool registry

MethodPathPurposeKey
GET/ai-toolsList the AI tools in the registry and the organization's custom appsOrganization

Query parameters, besides page and limit:

ParameterDescription
sourcecatalog, custom or all (default)
searchCase-insensitive match on the name or display name

Catalog tools are the approved Tool Registry entries visible to the organization; where the organization has its own version of a tool, that version is returned. Custom apps are the organization's internal AI apps and tracked apps. Tools are ordered by display name, then by ID.

FieldMeaning
idThe catalog tool ID (a stable slug) or the custom app ID
sourcecatalog or custom
name, displayName, category, subCategoryDescription
vendor, vendorWebsite, vendorHqCountry, dataResidencyNotesVendor details, for catalog tools
riskLevel, riskRationaleCatalog risk. null for custom apps.
builtInWhether the tool ships with the product
kindinternal_ai or tracked_app, for custom apps
primaryDomain, domainsCustom apps only
createdAt, updatedAtTimestamps

Detection rules (URL patterns, API hosts, bundle IDs, paths), intercept patterns, request notes, who requested or approved a catalog entry, and any device, user or usage data are not returned.

Sanctions

MethodPathPurposeKey
GET/sanctionsList the sanction status of AI toolsOrganization
PUT/sanctionsSet the sanction status of one AI toolOrganization, with Governance write

GET takes status (SANCTIONED, TOLERATED or UNSANCTIONED) besides page and limit. Only tools that have a sanction set are listed. Sanctions are ordered by tool name.

FieldMeaning
providerThe tool name
statusSANCTIONED, TOLERATED or UNSANCTIONED
riskLevellow, medium, high or null
noteThe admin note, or null
updatedAtLast change

Set a sanction

FieldRequiredDescription
providerYesThe tool name as shown in the Discover AI inventory, 1 to 120 characters
statusYesSANCTIONED, TOLERATED or UNSANCTIONED
riskLevelNolow, medium or high
noteNoUp to 1,000 characters
bash
curl -X PUT "https://<your-host>/api/public/v1/governance/sanctions" \ -u "pk-ap-...:sk-ap-..." \ -H "Content-Type: application/json" \ -d '{ "provider": "ExampleChat", "status": "UNSANCTIONED", "riskLevel": "high", "note": "Use the approved enterprise assistant instead." }'
json
{ "provider": "ExampleChat", "status": "UNSANCTIONED", "riskLevel": "high", "note": "Use the approved enterprise assistant instead.", "updatedAt": "2026-10-24T11:20:31.000Z" }

The sanction applies to the whole organization. As in the app, riskLevel and note are replaced on every write, so leaving them out clears them. The change has the same effects as in the app: cached usage reports are refreshed and, while Warn mode is on, browser extensions pick up the new policy on their next check.

Model approvals

MethodPathPurposeKey
GET/model-approvalsList the organization's model approval recordsOrganization

status filters on approved or not_approved, besides page and limit. Only models with an approval record are listed; models never reviewed are not. Records are ordered by when they were created, oldest first.

json
{ "data": [ { "id": "cm5a0d3vb0007rs09ijkl9012", "model": "openai/gpt-4o", "modelName": "GPT-4o", "provider": "OpenAI", "family": "GPT-4", "lifecycleStatus": "current", "status": "approved", "approvedBy": "cm1u7w4ty0000ab01mnop3456", "approvedAt": "2026-08-11T13:40:00.000Z", "updatedAt": "2026-08-11T13:40:00.000Z" } ], "meta": { "page": 1, "limit": 50, "totalItems": 1, "totalPages": 1 } }
FieldMeaning
idThe approval record ID
modelThe model key
modelName, provider, familyModel description
lifecycleStatuscurrent, deprecated or archived
statusapproved or not_approved
approvedByThe approver's user ID, or null. Names and email addresses are not returned.
approvedAt, updatedAtTimestamps

Approving or revoking models is done in the app.

Rate limit

Each API key can make 60 requests per minute across all governance endpoints by default. Your ANTS administrator can set a different limit for the deployment.

Above the limit the API answers 429 with these headers:

code
Retry-After: <seconds> X-RateLimit-Limit: <limit>

and this body:

json
{ "message": "Rate limit exceeded", "error": "TooManyRequests" }

Requests refused before the limit is checked (404, 401, and the 403 key, mode and permission checks) do not count. If the rate limiter cannot be reached, reads are still served, and writes answer 503 so that no write goes through without a limit.

Errors

Errors return a JSON body with a message field and an error field:

json
{ "message": "Access denied - this endpoint requires an organization API key.", "error": "ForbiddenError" }
StatusMeaning
400The request is invalid: a parameter or body field fails validation, an unknown body field was sent, no field was sent to an update, or projectId is missing with an organization key. For validation errors message is Invalid request data and error lists the problems.
401The Authorization header is missing or the key is invalid or expired.
403The key may not do this: a project key on an organization endpoint or on a write, a project key asking for another project, a project key on an ingestion-only deployment, a key type that is not a project or organization API key, a write while the access is Read only, or a write with a key that does not have Governance write. The message says which.
404The API is not available: it is off for the deployment or the organization, or the organization's plan does not include it. Also returned when the project, agent, governance profile, evidence or guardrail policy is not found in the key's scope.
405The method is not supported on this path.
429The key's per-minute rate limit is spent. Retry after Retry-After seconds.
500Server error. This includes the case where the audit log entry cannot be written: a read then returns no data, and a write is rolled back.
503A write was refused because the rate limiter cannot be reached. Try again shortly.

A 404 is used for every "not available" case, so a caller cannot tell from outside whether the API exists for an organization. When the deployment has the API on, an invalid key gets 401 before the organization settings are checked.

Auditing

Every request that returns data or changes data is recorded in Audit Logs. The actor is the API key. Refused requests are not recorded.

Reads. Each successful read writes one entry, with no sampling, before the response is sent. If the entry cannot be written, the request fails with 500 and no data is returned.

ColumnValue
Resource TypegovernancePublicApi
Resource IDThe endpoint, such as governance.agents.list or governance.sanctions.list
Actionread
ProjectThe project read, for project endpoints
Afterendpoint (method and endpoint), keyType (project or organization), projectId, query (the parameters used), count (records returned) and recordIds (the ID of every record returned)

So for any key you can see which project and which records were read, and when.

Writes. Each change is saved in the same database transaction as its audit entry. If the entry cannot be written, the change is rolled back and the request fails with 500.

WriteResource TypeResource IDActionBefore and After
Set a sanctionshadowAiAppSanctionTool namecreate or updateTool, status, risk level, note and time of change
Create or update a guardrail policypiiPciConfigPolicy IDcreate or updateThe policy, in the API's response shape
Change the risk tiergovernanceProfileProfile record IDupdateThe governance profile record
Change owner, purpose, stage or data sourcesgovernanceEvidenceProfile record IDupdateThe evidence record

A profile update that changes both the risk tier and other fields writes both entries in one transaction.

Settings. Turning the API on or off and changing the access write an entry with resource type governancePublicApi and action governancePublicApi.enable, governancePublicApi.disable, governancePublicApi.modeReadWrite or governancePublicApi.modeReadOnly, with the user as actor and the settings before and after. Turning Governance write on or off for a key writes an apiKey entry with action governanceWrite.grant or governanceWrite.revoke.

For organization keys, the Actor column shows the key's ID rather than its public key.

Limits

Never returned by any governance endpoint: prompt or response content, trace input and output, detection evidence text, secrets and credentials, API keys, device identifiers, user activity and agent tags. Governance profiles do not include the other evidence categories (human oversight, security, bias, transparency, legal accountability), attestations, requester and approver user IDs, or document links. Guardrail policies do not include PagerDuty or schedule settings.

Not available through this API; use the app:

  • Turning the API on or off, changing its access, and allowing a key to write.
  • Creating or deleting governance profiles, editing other evidence, attestations, and the review workflow (submit, approve, request changes).
  • Drift alerts, policy violations and guardrail detections.
  • Deleting a guardrail policy, and its schedule, PagerDuty and custom detector settings.
  • Clearing a sanction. Set it to UNSANCTIONED instead.
  • Approving or revoking models, and the model and framework catalogs.
  • Adding, editing or requesting AI tools and custom apps.
  • Discover AI usage, users, devices and enrollment.
  • Budget AI keys, budgets and model groups.

Traces, observations, sessions, scores, prompts, projects, memberships and the other resources listed in the API Reference are available through the rest of the public API.

Next steps

© 2026 ANTS Platform, Inc.Docs v1.0 · Last updated June 2026