resources_gen.go (package eai)
Source: sdks/go/resources_gen.go. Back to the Go SDK reference index.
This page is generated by tools/docs/gen_sdk_reference.py from the SDK sources and the OpenAPI text folders. Do not edit it by hand: change the source and regenerate.
Class MetaService
MetaService groups the endpoints of: System endpoints: health, readiness, platform metadata and the current principal.
MetaService.Get
Get(ctx context.Context, opts ...CallOption) (json.RawMessage, error)
Describe the Control Plane instance. Name, version and API version of the instance, supported locales and default locale, loaded domains, and the features enabled by the configuration: OIDC, API key, SPIFFE and development authentication, OpenBao, OpenFGA, OPA and LiteLLM (true when their address is set). No authentication required.
Route: /v1/meta (GET).
| Name | Type | Default | Required | Description |
|---|---|---|---|---|
ctx | context.Context | yes | Context of the call: cancellation and deadline. | |
opts | ...CallOption | no | Per call options (query, idempotency key, traceparent, headers). |
Returns: (json.RawMessage, error). Decoded JSON answer of the operation "Describe the Control Plane instance". The error is a typed error of the SDK, nil on success.
Raises: error, the typed errors of the transport (Errors).
MetaService.Health
Health(ctx context.Context, opts ...CallOption) (json.RawMessage, error)
Check that the process is alive. Liveness probe: always answers 200 with status: ok and the version of the Control Plane while the process serves requests. It checks no dependency. No authentication, no rate limit.
Route: /healthz (GET).
| Name | Type | Default | Required | Description |
|---|---|---|---|---|
ctx | context.Context | yes | Context of the call: cancellation and deadline. | |
opts | ...CallOption | no | Per call options (query, idempotency key, traceparent, headers). |
Returns: (json.RawMessage, error). Decoded JSON answer of the operation "Check that the process is alive". The error is a typed error of the SDK, nil on success.
Raises: error, the typed errors of the transport (Errors).
MetaService.Me
Me(ctx context.Context, opts ...CallOption) (json.RawMessage, error)
Read the current principal. Who the caller is: principal id, kind, tenant, clearance, project, environment, authentication method and display name, with its roles and scopes. When the principal belongs to a tenant, the tenant (id, slug, name, status, data residency) is returned too. Requires authentication (401 otherwise).
Route: /v1/me (GET).
| Name | Type | Default | Required | Description |
|---|---|---|---|---|
ctx | context.Context | yes | Context of the call: cancellation and deadline. | |
opts | ...CallOption | no | Per call options (query, idempotency key, traceparent, headers). |
Returns: (json.RawMessage, error). Decoded JSON answer of the operation "Read the current principal". The error is a typed error of the SDK, nil on success.
Raises: error, the typed errors of the transport (Errors).
MetaService.Ready
Ready(ctx context.Context, opts ...CallOption) (json.RawMessage, error)
Check that the instance is ready. Readiness probe: checks that the database answers and that the schema migrations were applied. Answers 200 ready when every check passes, else 503 not_ready, with the result of each check and a message in the language of the request. The Redis cache state is reported but never makes the instance not ready. No authentication, no rate limit.
Route: /readyz (GET).
| Name | Type | Default | Required | Description |
|---|---|---|---|---|
ctx | context.Context | yes | Context of the call: cancellation and deadline. | |
opts | ...CallOption | no | Per call options (query, idempotency key, traceparent, headers). |
Returns: (json.RawMessage, error). Decoded JSON answer of the operation "Check that the instance is ready". The error is a typed error of the SDK, nil on success.
Raises: error, the typed errors of the transport (Errors).
Class CatalogService
CatalogService groups the endpoints of: Brick catalog (A to H).
CatalogService.Brick
Brick(ctx context.Context, id string, opts ...CallOption) (json.RawMessage, error)
Get one platform brick. One brick of the catalog, matched on its id without regard to case. Answers 404 not_found when no brick has this id. No authentication required.
Route: /v1/catalog/bricks/{brick_id} (GET).
| Name | Type | Default | Required | Description |
|---|---|---|---|---|
ctx | context.Context | yes | Context of the call: cancellation and deadline. | |
id | string | yes | Identifier of the brick in the catalog, case insensitive. | |
opts | ...CallOption | no | Per call options (query, idempotency key, traceparent, headers). |
Returns: (json.RawMessage, error). Decoded JSON answer of the operation "Get one platform brick". The error is a typed error of the SDK, nil on success.
Raises: error, the typed errors of the transport (Errors).
CatalogService.Bricks
Bricks(ctx context.Context, opts ...CallOption) (json.RawMessage, error)
List the platform bricks. Catalog of the platform bricks read from bricks.yaml of the catalog folder, in one page (next_cursor is always null). The file is loaded as safe YAML (no anchors or aliases, 2 MB at most). No authentication required.
Route: /v1/catalog/bricks (GET).
| Name | Type | Default | Required | Description |
|---|---|---|---|---|
ctx | context.Context | yes | Context of the call: cancellation and deadline. | |
opts | ...CallOption | no | Per call options (query, idempotency key, traceparent, headers). |
Returns: (json.RawMessage, error). Decoded JSON answer of the operation "List the platform bricks". The error is a typed error of the SDK, nil on success.
Raises: error, the typed errors of the transport (Errors).
Class RoadmapService
RoadmapService groups the endpoints of: Platform roadmap (12 phases).
RoadmapService.Get
Get(ctx context.Context, opts ...CallOption) (json.RawMessage, error)
Read the product roadmap. Roadmap read from roadmap.yaml of the catalog folder, always with a phases list (empty when the file is missing). Loaded as safe YAML. No authentication required.
Route: /v1/roadmap (GET).
| Name | Type | Default | Required | Description |
|---|---|---|---|---|
ctx | context.Context | yes | Context of the call: cancellation and deadline. | |
opts | ...CallOption | no | Per call options (query, idempotency key, traceparent, headers). |
Returns: (json.RawMessage, error). Decoded JSON answer of the operation "Read the product roadmap". The error is a typed error of the SDK, nil on success.
Raises: error, the typed errors of the transport (Errors).
Class ContractsService
ContractsService groups the endpoints of: Technical contracts (JSON Schemas) and server side validation.
ContractsService.Get
Get(ctx context.Context, name string, opts ...CallOption) (json.RawMessage, error)
Get a contract. Returns the JSON Schema of the contract as published. Open to any authenticated caller. An unknown name answers 404 unknown_contract.
Route: /v1/contracts/{name} (GET).
| Name | Type | Default | Required | Description |
|---|---|---|---|---|
ctx | context.Context | yes | Context of the call: cancellation and deadline. | |
name | string | yes | Name of the contract, for example agent-manifest. | |
opts | ...CallOption | no | Per call options (query, idempotency key, traceparent, headers). |
Returns: (json.RawMessage, error). Decoded JSON answer of the operation "Get a contract". The error is a typed error of the SDK, nil on success.
Raises: error, the typed errors of the transport (Errors).
ContractsService.List
List(ctx context.Context, opts ...CallOption) (json.RawMessage, error)
List the contracts. Lists the published contracts with their name, title, kind, type, file, schema id and description. Open to any authenticated caller. next_cursor is always null.
Route: /v1/contracts (GET).
| Name | Type | Default | Required | Description |
|---|---|---|---|---|
ctx | context.Context | yes | Context of the call: cancellation and deadline. | |
opts | ...CallOption | no | Per call options (query, idempotency key, traceparent, headers). |
Returns: (json.RawMessage, error). Decoded JSON answer of the operation "List the contracts". The error is a typed error of the SDK, nil on success.
Raises: error, the typed errors of the transport (Errors).
ContractsService.ValidateRemote
ValidateRemote(ctx context.Context, name string, body any, opts ...CallOption) (json.RawMessage, error)
Validate a document against a contract. Validates the body against the contract, formats included, without storing anything. The answer gives contract, valid and errors, each with the JSON path of the faulty value and a message. Open to any authenticated caller. An unknown contract answers 404 unknown_contract.
Route: /v1/contracts/{name}/validate (POST).
| Name | Type | Default | Required | Description |
|---|---|---|---|---|
ctx | context.Context | yes | Context of the call: cancellation and deadline. | |
name | string | yes | Name of the contract, for example agent-manifest. | |
body | any | yes | Any JSON document to validate. | |
opts | ...CallOption | no | Per call options (query, idempotency key, traceparent, headers). |
Returns: (json.RawMessage, error). Decoded JSON answer of the operation "Validate a document against a contract". The error is a typed error of the SDK, nil on success.
Raises: error, the typed errors of the transport (Errors).
Class ManifestsService
ManifestsService groups the endpoints of: Manifest apply and export (Agent, Model, Tool, Skill, Plugin, Connector, Channel).
ManifestsService.Apply
Apply(ctx context.Context, body any, opts ...CallOption) (json.RawMessage, error)
Apply a manifest. Creates or updates the object described by a manifest, in one transaction. Needs tenant_admin or developer.
Route: /v1/manifests/apply (POST).
| Name | Type | Default | Required | Description |
|---|---|---|---|---|
ctx | context.Context | yes | Context of the call: cancellation and deadline. | |
body | any | yes | Manifest document with kind, metadata and the specification of the object. | |
opts | ...CallOption | no | Per call options (query, idempotency key, traceparent, headers). |
Returns: (json.RawMessage, error). Decoded JSON answer of the operation "Apply a manifest". The error is a typed error of the SDK, nil on success.
Raises: error, the typed errors of the transport (Errors).
ManifestsService.Export
Export(ctx context.Context, kind string, name string, opts ...CallOption) (json.RawMessage, error)
Export a manifest. Returns the current manifest of an object of the tenant: built by the registry of the kind when it can export, otherwise the last applied document. Open to any member of the tenant. An unknown kind answers 422 unknown_kind (with the supported kinds); an unknown object 404 not_found.
Route: /v1/manifests/{kind}/{name} (GET).
| Name | Type | Default | Required | Description |
|---|---|---|---|---|
ctx | context.Context | yes | Context of the call: cancellation and deadline. | |
kind | string | yes | Kind of manifest, without case: Agent, Model, Tool, Skill, Plugin, Connector or Channel. | |
name | string | yes | Name of the object, the metadata.name of its manifest. | |
opts | ...CallOption | no | Per call options (query, idempotency key, traceparent, headers). |
Returns: (json.RawMessage, error). Decoded JSON answer of the operation "Export a manifest". The error is a typed error of the SDK, nil on success.
Raises: error, the typed errors of the transport (Errors).
Class TenantsService
TenantsService groups the endpoints of: Tenants (platform_admin).
TenantsService.Create
Create(ctx context.Context, body any, opts ...CallOption) (json.RawMessage, error)
Create a tenant. Creates a tenant and makes each subject of admins its tenant_admin. Needs platform_admin. A slug already used answers 409 conflict. Writes the audit event tenant.create in the chain of the new tenant.
Route: /v1/tenants (POST).
| Name | Type | Default | Required | Description |
|---|---|---|---|---|
ctx | context.Context | yes | Context of the call: cancellation and deadline. | |
body | any | yes | Slug, name, residency, settings and first administrators of the tenant. | |
opts | ...CallOption | no | Per call options (query, idempotency key, traceparent, headers). |
Returns: (json.RawMessage, error). Decoded JSON answer of the operation "Create a tenant". The error is a typed error of the SDK, nil on success.
Raises: error, the typed errors of the transport (Errors).
TenantsService.Get
Get(ctx context.Context, id string, opts ...CallOption) (json.RawMessage, error)
Get a tenant. Returns one tenant: slug, name, status, data residency and settings. A tenant the caller may not see answers 404 not_found.
Route: /v1/tenants/{tenant_id} (GET).
| Name | Type | Default | Required | Description |
|---|---|---|---|---|
ctx | context.Context | yes | Context of the call: cancellation and deadline. | |
id | string | yes | Identifier (UUID) of the tenant. | |
opts | ...CallOption | no | Per call options (query, idempotency key, traceparent, headers). |
Returns: (json.RawMessage, error). Decoded JSON answer of the operation "Get a tenant". The error is a typed error of the SDK, nil on success.
Raises: error, the typed errors of the transport (Errors).
TenantsService.List
List(ctx context.Context, opts ...CallOption) (*Page, error)
List the tenants. Lists the tenants the caller may see, ordered by slug, paginated: their own tenant for a tenant credential, every tenant for a platform administrator.
Route: /v1/tenants (GET).
| Name | Type | Default | Required | Description |
|---|---|---|---|---|
ctx | context.Context | yes | Context of the call: cancellation and deadline. | |
opts | ...CallOption | no | Per call options (query, idempotency key, traceparent, headers). |
Returns: (*Page, error). A Page: Page is one page of a cursor paginated collection {"items": [...], "next_cursor": "..."|null}. The error is a typed error of the SDK, nil on success.
Raises: error, the typed errors of the transport (Errors).
TenantsService.Update
Update(ctx context.Context, id string, body any, opts ...CallOption) (json.RawMessage, error)
Update a tenant. Changes the name, data residency, settings or status of a tenant. Needs tenant_admin; changing status (active or suspended) needs a platform administrator (403 forbidden). A suspended tenant answers 403 tenant_suspended to every credential. Writes the audit event tenant.update.
Route: /v1/tenants/{tenant_id} (PATCH).
| Name | Type | Default | Required | Description |
|---|---|---|---|---|
ctx | context.Context | yes | Context of the call: cancellation and deadline. | |
id | string | yes | Identifier (UUID) of the tenant. | |
body | any | yes | Fields to change; omitted fields keep their value. | |
opts | ...CallOption | no | Per call options (query, idempotency key, traceparent, headers). |
Returns: (json.RawMessage, error). Decoded JSON answer of the operation "Update a tenant". The error is a typed error of the SDK, nil on success.
Raises: error, the typed errors of the transport (Errors).
Class ProjectsService
ProjectsService groups the endpoints of: Projects and their environments.
ProjectsService.Create
Create(ctx context.Context, body any, opts ...CallOption) (json.RawMessage, error)
Create a project. Creates a project in the tenant of the caller. Needs tenant_admin.
Route: /v1/projects (POST).
| Name | Type | Default | Required | Description |
|---|---|---|---|---|
ctx | context.Context | yes | Context of the call: cancellation and deadline. | |
body | any | yes | Slug, name, settings, environments and attachment of the project. | |
opts | ...CallOption | no | Per call options (query, idempotency key, traceparent, headers). |
Returns: (json.RawMessage, error). Decoded JSON answer of the operation "Create a project". The error is a typed error of the SDK, nil on success.
Raises: error, the typed errors of the transport (Errors).
ProjectsService.CreateEnvironment
CreateEnvironment(ctx context.Context, id string, body any, opts ...CallOption) (json.RawMessage, error)
Create an environment. Adds an environment (dev, test, staging or prod) to the project. Needs tenant_admin and the relation editor on the project. An environment that already exists answers 409 conflict. Writes the audit event environment.create.
Route: /v1/projects/{project_id}/environments (POST).
| Name | Type | Default | Required | Description |
|---|---|---|---|---|
ctx | context.Context | yes | Context of the call: cancellation and deadline. | |
id | string | yes | Identifier (UUID) of the project. | |
body | any | yes | Name and settings of the environment. | |
opts | ...CallOption | no | Per call options (query, idempotency key, traceparent, headers). |
Returns: (json.RawMessage, error). Decoded JSON answer of the operation "Create an environment". The error is a typed error of the SDK, nil on success.
Raises: error, the typed errors of the transport (Errors).
ProjectsService.Delete
Delete(ctx context.Context, id string, opts ...CallOption) error
Delete a project. Deletes the project and its environments. Needs tenant_admin and the relation owner on the project (403 relation_required). Objects that still reference the project may block the deletion (409 conflict). Writes the audit event project.delete. Answers 204.
Route: /v1/projects/{project_id} (DELETE).
| Name | Type | Default | Required | Description |
|---|---|---|---|---|
ctx | context.Context | yes | Context of the call: cancellation and deadline. | |
id | string | yes | Identifier (UUID) of the project. | |
opts | ...CallOption | no | Per call options (query, idempotency key, traceparent, headers). |
Returns: error. Error of the call (a typed error of the SDK), nil on success.
Raises: error, the typed errors of the transport (Errors).
ProjectsService.Get
Get(ctx context.Context, id string, opts ...CallOption) (json.RawMessage, error)
Get a project. Returns the project with its environments. Needs the relation viewer on the project (403 relation_required, audited). Answers 404 not_found for an unknown project.
Route: /v1/projects/{project_id} (GET).
| Name | Type | Default | Required | Description |
|---|---|---|---|---|
ctx | context.Context | yes | Context of the call: cancellation and deadline. | |
id | string | yes | Identifier (UUID) of the project. | |
opts | ...CallOption | no | Per call options (query, idempotency key, traceparent, headers). |
Returns: (json.RawMessage, error). Decoded JSON answer of the operation "Get a project". The error is a typed error of the SDK, nil on success.
Raises: error, the typed errors of the transport (Errors).
ProjectsService.List
List(ctx context.Context, opts ...CallOption) (*Page, error)
List the projects. Lists the projects of the tenant ordered by slug, paginated, optionally filtered by organization or business unit. Open to any member of the tenant.
Route: /v1/projects (GET).
| Name | Type | Default | Required | Description |
|---|---|---|---|---|
ctx | context.Context | yes | Context of the call: cancellation and deadline. | |
opts | ...CallOption | no | Per call options (query, idempotency key, traceparent, headers). |
Returns: (*Page, error). A Page: Page is one page of a cursor paginated collection {"items": [...], "next_cursor": "..."|null}. The error is a typed error of the SDK, nil on success.
Raises: error, the typed errors of the transport (Errors).
ProjectsService.ListEnvironments
ListEnvironments(ctx context.Context, id string, opts ...CallOption) (*Page, error)
List the environments of a project. Lists the environments of the project, ordered by name. Needs the relation viewer on the project. Not paginated: next_cursor is always null.
Route: /v1/projects/{project_id}/environments (GET).
| Name | Type | Default | Required | Description |
|---|---|---|---|---|
ctx | context.Context | yes | Context of the call: cancellation and deadline. | |
id | string | yes | Identifier (UUID) of the project. | |
opts | ...CallOption | no | Per call options (query, idempotency key, traceparent, headers). |
Returns: (*Page, error). A Page: Page is one page of a cursor paginated collection {"items": [...], "next_cursor": "..."|null}. The error is a typed error of the SDK, nil on success.
Raises: error, the typed errors of the transport (Errors).
ProjectsService.Update
Update(ctx context.Context, id string, body any, opts ...CallOption) (json.RawMessage, error)
Update a project. Changes the name, description, settings, metadata or attachment of a project. Sending organization_id or business_unit_id as null detaches the project. The unit must belong to the organization (422 invalid_hierarchy). Needs tenant_admin and the relation editor on the project. Send expected_version to detect a concurrent change (409 version_conflict). Writes the audit event project.update.
Route: /v1/projects/{project_id} (PATCH).
| Name | Type | Default | Required | Description |
|---|---|---|---|---|
ctx | context.Context | yes | Context of the call: cancellation and deadline. | |
id | string | yes | Identifier (UUID) of the project. | |
body | any | yes | Fields to change; omitted fields keep their value. | |
opts | ...CallOption | no | Per call options (query, idempotency key, traceparent, headers). |
Returns: (json.RawMessage, error). Decoded JSON answer of the operation "Update a project". The error is a typed error of the SDK, nil on success.
Raises: error, the typed errors of the transport (Errors).
Class MembersService
MembersService groups the endpoints of: Tenant members and role assignment.
MembersService.Create
Create(ctx context.Context, body any, opts ...CallOption) (json.RawMessage, error)
Add a member. Gives a user (OIDC subject) a role and a clearance in the tenant, or in one project with project_id. The user record is created when unknown; an existing membership for the same user and project is updated. Needs tenant_admin; granting platform_admin needs a platform administrator (403 forbidden). Writes the audit event member.assign.
Route: /v1/members (POST).
| Name | Type | Default | Required | Description |
|---|---|---|---|---|
ctx | context.Context | yes | Context of the call: cancellation and deadline. | |
body | any | yes | User, role, clearance and optional project of the membership. | |
opts | ...CallOption | no | Per call options (query, idempotency key, traceparent, headers). |
Returns: (json.RawMessage, error). Decoded JSON answer of the operation "Add a member". The error is a typed error of the SDK, nil on success.
Raises: error, the typed errors of the transport (Errors).
MembersService.Delete
Delete(ctx context.Context, id string, opts ...CallOption) error
Remove a member. Removes the membership: the user loses the role it gave at the next request. Needs tenant_admin. Writes the audit event member.remove. Answers 204, or 404 not_found.
Route: /v1/members/{member_id} (DELETE).
| Name | Type | Default | Required | Description |
|---|---|---|---|---|
ctx | context.Context | yes | Context of the call: cancellation and deadline. | |
id | string | yes | Identifier (UUID) of the membership. | |
opts | ...CallOption | no | Per call options (query, idempotency key, traceparent, headers). |
Returns: error. Error of the call (a typed error of the SDK), nil on success.
Raises: error, the typed errors of the transport (Errors).
MembersService.List
List(ctx context.Context, opts ...CallOption) (*Page, error)
List the members. Lists the memberships of the tenant, paginated: user subject, email, display name, role, clearance, project and creation date. Open to any member of the tenant.
Route: /v1/members (GET).
| Name | Type | Default | Required | Description |
|---|---|---|---|---|
ctx | context.Context | yes | Context of the call: cancellation and deadline. | |
opts | ...CallOption | no | Per call options (query, idempotency key, traceparent, headers). |
Returns: (*Page, error). A Page: Page is one page of a cursor paginated collection {"items": [...], "next_cursor": "..."|null}. The error is a typed error of the SDK, nil on success.
Raises: error, the typed errors of the transport (Errors).
MembersService.Update
Update(ctx context.Context, id string, body any, opts ...CallOption) (json.RawMessage, error)
Update a member. Changes the role or the clearance of a membership. Needs tenant_admin; granting platform_admin needs a platform administrator (403 forbidden). Writes the audit event member.update. Answers 404 not_found for an unknown membership.
Route: /v1/members/{member_id} (PATCH).
| Name | Type | Default | Required | Description |
|---|---|---|---|---|
ctx | context.Context | yes | Context of the call: cancellation and deadline. | |
id | string | yes | Identifier (UUID) of the membership. | |
body | any | yes | New role and/or clearance. | |
opts | ...CallOption | no | Per call options (query, idempotency key, traceparent, headers). |
Returns: (json.RawMessage, error). Decoded JSON answer of the operation "Update a member". The error is a typed error of the SDK, nil on success.
Raises: error, the typed errors of the transport (Errors).
Class APIKeysService
APIKeysService groups the endpoints of: Tenant API keys (secret shown once).
APIKeysService.Create
Create(ctx context.Context, body any, opts ...CallOption) (json.RawMessage, error)
Create an API key. Creates an API key for scripts and services. Needs tenant_admin or developer. The answer (201) carries the full secret in key, shown only once: store it in a secret store right away.
Route: /v1/api-keys (POST).
| Name | Type | Default | Required | Description |
|---|---|---|---|---|
ctx | context.Context | yes | Context of the call: cancellation and deadline. | |
body | any | yes | Name, rights, binding and expiry of the new key. | |
opts | ...CallOption | no | Per call options (query, idempotency key, traceparent, headers). |
Returns: (json.RawMessage, error). Decoded JSON answer of the operation "Create an API key". The error is a typed error of the SDK, nil on success.
Raises: error, the typed errors of the transport (Errors).
APIKeysService.Delete
Delete(ctx context.Context, id string, opts ...CallOption) error
Revoke an API key. Revokes the key at once: every later request made with it answers 401 api_key_revoked. Revoking a key already revoked succeeds without change. Allowed to tenant_admin, security_officer and developer; a developer only revokes the keys they created, any other key answers 404 not_found. Writes the audit event api_key.revoke. Answers 204 without body.
Route: /v1/api-keys/{key_id} (DELETE).
| Name | Type | Default | Required | Description |
|---|---|---|---|---|
ctx | context.Context | yes | Context of the call: cancellation and deadline. | |
id | string | yes | Identifier (UUID) of the API key. | |
opts | ...CallOption | no | Per call options (query, idempotency key, traceparent, headers). |
Returns: error. Error of the call (a typed error of the SDK), nil on success.
Raises: error, the typed errors of the transport (Errors).
APIKeysService.List
List(ctx context.Context, opts ...CallOption) (*Page, error)
List the API keys. Lists the API keys of the tenant, paginated by limit and cursor, ordered by identifier. Each item gives the name, the public prefix, roles, scopes, clearance, project, environment, creator, expiry and revocation state; never the secret nor its hash. tenant_admin and security_officer see every key, a developer only the keys they created.
Route: /v1/api-keys (GET).
| Name | Type | Default | Required | Description |
|---|---|---|---|---|
ctx | context.Context | yes | Context of the call: cancellation and deadline. | |
opts | ...CallOption | no | Per call options (query, idempotency key, traceparent, headers). |
Returns: (*Page, error). A Page: Page is one page of a cursor paginated collection {"items": [...], "next_cursor": "..."|null}. The error is a typed error of the SDK, nil on success.
Raises: error, the typed errors of the transport (Errors).
APIKeysService.Rotate
Rotate(ctx context.Context, id string, opts ...CallOption) (json.RawMessage, error)
Rotate an API key. Issues a replacement key with the same name, roles, scopes, clearance, project and environment, and retires the old one. The new secret is in key of the 201 answer, shown once.
Route: /v1/api-keys/{key_id}/rotate (POST).
| Name | Type | Default | Required | Description |
|---|---|---|---|---|
ctx | context.Context | yes | Context of the call: cancellation and deadline. | |
id | string | yes | Identifier (UUID) of the API key. | |
opts | ...CallOption | no | Per call options (query, idempotency key, traceparent, headers). |
Returns: (json.RawMessage, error). Decoded JSON answer of the operation "Rotate an API key". The error is a typed error of the SDK, nil on success.
Raises: error, the typed errors of the transport (Errors).
Class ServiceIdentitiesService
ServiceIdentitiesService groups the endpoints of: Service identities (SPIFFE ids).
ServiceIdentitiesService.Assume
Assume(ctx context.Context, identityID string, body any, opts ...CallOption) (json.RawMessage, error)
Assume a service identity. Returns a signed, short lived ExecutionContext whose subject is the service identity, for the caller. It is not an API credential: downstream services verify it (POST /v1/context/verify or the JWKS) and the caller revokes it with POST /v1/context/{context_id}/revoke.
Route: /v1/service-identities/{identity_id}/assume (POST).
| Name | Type | Default | Required | Description |
|---|---|---|---|---|
ctx | context.Context | yes | Context of the call: cancellation and deadline. | |
identityID | string | yes | Identifier (UUID) of the service identity. | |
body | any | yes | Purpose, audiences, lifetime and scopes of the requested context. | |
opts | ...CallOption | no | Per call options (query, idempotency key, traceparent, headers). |
Returns: (json.RawMessage, error). Decoded JSON answer of the operation "Assume a service identity". The error is a typed error of the SDK, nil on success.
Raises: error, the typed errors of the transport (Errors).
ServiceIdentitiesService.Create
Create(ctx context.Context, body any, opts ...CallOption) (json.RawMessage, error)
Create a service identity. Registers a workload identity of the tenant with its SPIFFE ID, roles, scopes and clearance. Needs tenant_admin or security_officer; the roles and scopes granted follow the same rules as API keys (only what the caller holds). A SPIFFE ID already registered answers 409 conflict. Writes the audit event service_identity.create. Assuming the identity also needs the explicit relation can_assume (see the assume route).
Route: /v1/service-identities (POST).
| Name | Type | Default | Required | Description |
|---|---|---|---|---|
ctx | context.Context | yes | Context of the call: cancellation and deadline. | |
body | any | yes | Name, SPIFFE ID and rights of the identity. | |
opts | ...CallOption | no | Per call options (query, idempotency key, traceparent, headers). |
Returns: (json.RawMessage, error). Decoded JSON answer of the operation "Create a service identity". The error is a typed error of the SDK, nil on success.
Raises: error, the typed errors of the transport (Errors).
ServiceIdentitiesService.Delete
Delete(ctx context.Context, id string, opts ...CallOption) error
Delete a service identity. Deletes the service identity; it can no longer be assumed nor authenticate with its SPIFFE ID. Needs tenant_admin or security_officer. Writes the audit event service_identity.delete. Answers 204, or 404 not_found.
Route: /v1/service-identities/{identity_id} (DELETE).
| Name | Type | Default | Required | Description |
|---|---|---|---|---|
ctx | context.Context | yes | Context of the call: cancellation and deadline. | |
id | string | yes | Identifier (UUID) of the service identity. | |
opts | ...CallOption | no | Per call options (query, idempotency key, traceparent, headers). |
Returns: error. Error of the call (a typed error of the SDK), nil on success.
Raises: error, the typed errors of the transport (Errors).
ServiceIdentitiesService.List
List(ctx context.Context, opts ...CallOption) (*Page, error)
List the service identities. Lists the service identities of the tenant, ordered by name, with their SPIFFE ID, roles, scopes and clearance. Open to any member of the tenant. Not paginated: next_cursor is always null.
Route: /v1/service-identities (GET).
| Name | Type | Default | Required | Description |
|---|---|---|---|---|
ctx | context.Context | yes | Context of the call: cancellation and deadline. | |
opts | ...CallOption | no | Per call options (query, idempotency key, traceparent, headers). |
Returns: (*Page, error). A Page: Page is one page of a cursor paginated collection {"items": [...], "next_cursor": "..."|null}. The error is a typed error of the SDK, nil on success.
Raises: error, the typed errors of the transport (Errors).
Class AuthzService
AuthzService groups the endpoints of: Relationship based authorization (OpenFGA or builtin).
AuthzService.Check
Check(ctx context.Context, body any, opts ...CallOption) (json.RawMessage, error)
Check a relation. Tells whether subject holds relation on object, following inheritance. Up to 20 contextual_tuples are taken as true for this check only and never stored (an invalid one answers 422 validation_error). Open to any member of the tenant. The answer gives allowed, engine, subject, relation and object. Writes the audit event authz.check with the decision. When the engine cannot answer, the decision is a refusal, it is audited and the API answers 502 authz_backend_error.
Route: /v1/authz/check (POST).
| Name | Type | Default | Required | Description |
|---|---|---|---|---|
ctx | context.Context | yes | Context of the call: cancellation and deadline. | |
body | any | yes | Subject, relation, object and optional contextual tuples. | |
opts | ...CallOption | no | Per call options (query, idempotency key, traceparent, headers). |
Returns: (json.RawMessage, error). Decoded JSON answer of the operation "Check a relation". The error is a typed error of the SDK, nil on success.
Raises: error, the typed errors of the transport (Errors).
AuthzService.DeleteTuples
DeleteTuples(ctx context.Context, body any, opts ...CallOption) (json.RawMessage, error)
Delete authorization tuples. Deletes one tuple ({subject, relation, object}) or up to 100 ({"tuples": [...]}). Needs tenant_admin or security_officer. Tuples that do not exist are ignored; the answer gives deleted (number removed) and engine. Writes the audit event authz.delete. 502 authz_backend_error when the engine cannot answer.
Route: /v1/authz/tuples (DELETE).
| Name | Type | Default | Required | Description |
|---|---|---|---|---|
ctx | context.Context | yes | Context of the call: cancellation and deadline. | |
body | any | yes | One tuple, or an object tuples with 1 to 100 tuples. | |
opts | ...CallOption | no | Per call options (query, idempotency key, traceparent, headers). |
Returns: (json.RawMessage, error). Decoded JSON answer of the operation "Delete authorization tuples". The error is a typed error of the SDK, nil on success.
Raises: error, the typed errors of the transport (Errors).
AuthzService.ListTuples
ListTuples(ctx context.Context, opts ...CallOption) (json.RawMessage, error)
List authorization tuples. Lists the stored tuples of the tenant, ordered by object, relation and subject, at most 1000, optionally filtered by object and subject (exact match). Open to any member of the tenant. next_cursor is always null.
Route: /v1/authz/tuples (GET).
| Name | Type | Default | Required | Description |
|---|---|---|---|---|
ctx | context.Context | yes | Context of the call: cancellation and deadline. | |
opts | ...CallOption | no | Per call options (query, idempotency key, traceparent, headers). |
Returns: (json.RawMessage, error). Decoded JSON answer of the operation "List authorization tuples". The error is a typed error of the SDK, nil on success.
Raises: error, the typed errors of the transport (Errors).
AuthzService.WriteTuples
WriteTuples(ctx context.Context, body any, opts ...CallOption) (json.RawMessage, error)
Write authorization tuples. Grants one tuple ({subject, relation, object}) or up to 100 ({"tuples": [...]}) in one transaction. Needs tenant_admin or security_officer. A wildcard subject (user:*) on a relation reserved to named subjects, such as can_assume, answers 422 authz_wildcard_not_allowed. The answer (201) gives written and engine. Writes the audit event authz.write. 502 authz_backend_error when the engine cannot answer.
Route: /v1/authz/tuples (POST).
| Name | Type | Default | Required | Description |
|---|---|---|---|---|
ctx | context.Context | yes | Context of the call: cancellation and deadline. | |
body | any | yes | One tuple, or an object tuples with 1 to 100 tuples. | |
opts | ...CallOption | no | Per call options (query, idempotency key, traceparent, headers). |
Returns: (json.RawMessage, error). Decoded JSON answer of the operation "Write authorization tuples". The error is a typed error of the SDK, nil on success.
Raises: error, the typed errors of the transport (Errors).
Class PoliciesService
PoliciesService groups the endpoints of: Policies, evaluation (Policy Contract) and recorded decisions.
PoliciesService.Create
Create(ctx context.Context, body any, opts ...CallOption) (json.RawMessage, error)
Create a policy. Creates a policy of the tenant and appends its first revision. An opa policy needs rego (422 validation_error) and, unless OPA loads signed bundles, is pushed to OPA at once (503 policy_engine_unavailable when OPA cannot be reached). A name already used answers 409 conflict. Needs tenant_admin or security_officer. Writes the audit event policy.create.
Route: /v1/policies (POST).
| Name | Type | Default | Required | Description |
|---|---|---|---|---|
ctx | context.Context | yes | Context of the call: cancellation and deadline. | |
body | any | yes | Name, engine, rules or Rego, priority and status of the policy. | |
opts | ...CallOption | no | Per call options (query, idempotency key, traceparent, headers). |
Returns: (json.RawMessage, error). Decoded JSON answer of the operation "Create a policy". The error is a typed error of the SDK, nil on success.
Raises: error, the typed errors of the transport (Errors).
PoliciesService.Decisions
Decisions(ctx context.Context, opts ...CallOption) (*Page, error)
List the policy decisions. Lists the decisions of the tenant, newest first, paginated: subject, action, resource, context, allow, policy and version, reasons, obligations, engine and date. Needs tenant_admin, security_officer or auditor.
Route: /v1/policies/decisions (GET).
| Name | Type | Default | Required | Description |
|---|---|---|---|---|
ctx | context.Context | yes | Context of the call: cancellation and deadline. | |
opts | ...CallOption | no | Per call options (query, idempotency key, traceparent, headers). |
Returns: (*Page, error). A Page: Page is one page of a cursor paginated collection {"items": [...], "next_cursor": "..."|null}. The error is a typed error of the SDK, nil on success.
Raises: error, the typed errors of the transport (Errors).
PoliciesService.Delete
Delete(ctx context.Context, id string, opts ...CallOption) error
Delete a policy. Deletes the policy and appends a delete revision. An OPA policy pushed directly to OPA is removed from it too (503 policy_engine_unavailable when OPA cannot be reached). Needs tenant_admin or security_officer. Writes the audit event policy.delete. Answers 204, or 404 not_found.
Route: /v1/policies/{policy_id} (DELETE).
| Name | Type | Default | Required | Description |
|---|---|---|---|---|
ctx | context.Context | yes | Context of the call: cancellation and deadline. | |
id | string | yes | Identifier (UUID) of the policy. | |
opts | ...CallOption | no | Per call options (query, idempotency key, traceparent, headers). |
Returns: error. Error of the call (a typed error of the SDK), nil on success.
Raises: error, the typed errors of the transport (Errors).
PoliciesService.EvaluateRaw
EvaluateRaw(ctx context.Context, body any, opts ...CallOption) (json.RawMessage, error)
Evaluate a policy request. Returns the decision for a Policy Contract request. The body is a Policy Contract ({schema_version, request}) or just its request object (subject, action, resource, context); it is validated against the policy-contract contract (422 validation_error).
Route: /v1/policies/evaluate (POST).
| Name | Type | Default | Required | Description |
|---|---|---|---|---|
ctx | context.Context | yes | Context of the call: cancellation and deadline. | |
body | any | yes | Policy Contract document, or its request object alone. | |
opts | ...CallOption | no | Per call options (query, idempotency key, traceparent, headers). |
Returns: (json.RawMessage, error). Decoded JSON answer of the operation "Evaluate a policy request". The error is a typed error of the SDK, nil on success.
Raises: error, the typed errors of the transport (Errors).
PoliciesService.Get
Get(ctx context.Context, id string, opts ...CallOption) (json.RawMessage, error)
Get a policy. Returns one policy. Open to any member of the tenant. Answers 404 not_found.
Route: /v1/policies/{policy_id} (GET).
| Name | Type | Default | Required | Description |
|---|---|---|---|---|
ctx | context.Context | yes | Context of the call: cancellation and deadline. | |
id | string | yes | Identifier (UUID) of the policy. | |
opts | ...CallOption | no | Per call options (query, idempotency key, traceparent, headers). |
Returns: (json.RawMessage, error). Decoded JSON answer of the operation "Get a policy". The error is a typed error of the SDK, nil on success.
Raises: error, the typed errors of the transport (Errors).
PoliciesService.List
List(ctx context.Context, opts ...CallOption) (*Page, error)
List the policies. Lists the policies of the tenant in evaluation order (priority, then name), with their rules or Rego. Open to any member of the tenant. next_cursor is always null.
Route: /v1/policies (GET).
| Name | Type | Default | Required | Description |
|---|---|---|---|---|
ctx | context.Context | yes | Context of the call: cancellation and deadline. | |
opts | ...CallOption | no | Per call options (query, idempotency key, traceparent, headers). |
Returns: (*Page, error). A Page: Page is one page of a cursor paginated collection {"items": [...], "next_cursor": "..."|null}. The error is a typed error of the SDK, nil on success.
Raises: error, the typed errors of the transport (Errors).
PoliciesService.Replace
Replace(ctx context.Context, id string, body any, opts ...CallOption) (json.RawMessage, error)
Replace a policy. Replaces every field of the policy and appends an update revision. Same validation as at creation (rego for opa, unique name). An opa policy is pushed to OPA unless OPA loads bundles. Needs tenant_admin or security_officer. Writes the audit event policy.update. Answers 404 not_found for an unknown policy.
Route: /v1/policies/{policy_id} (PUT).
| Name | Type | Default | Required | Description |
|---|---|---|---|---|
ctx | context.Context | yes | Context of the call: cancellation and deadline. | |
id | string | yes | Identifier (UUID) of the policy. | |
body | any | yes | Full new content of the policy. | |
opts | ...CallOption | no | Per call options (query, idempotency key, traceparent, headers). |
Returns: (json.RawMessage, error). Decoded JSON answer of the operation "Replace a policy". The error is a typed error of the SDK, nil on success.
Raises: error, the typed errors of the transport (Errors).
Class ApprovalsService
ApprovalsService groups the endpoints of: Human approvals with separation of duties.
ApprovalsService.Cancel
Cancel(ctx context.Context, approvalID string, body any, opts ...CallOption) (json.RawMessage, error)
Cancel an approval request. Withdraws a pending request. Allowed to its requester, a tenant_admin or a security_officer (403 forbidden otherwise, the refusal being audited). The request ends cancelled and its subject reacts as to a refusal: a waiting run fails (approval_cancelled), a pending break glass grant or mandate is rejected. A request that is no longer pending answers 409 approval_closed. Writes the audit event approval.cancel with the reason. The answer carries run_state when a run is attached.
Route: /v1/approvals/{approval_id}/cancel (POST).
| Name | Type | Default | Required | Description |
|---|---|---|---|---|
ctx | context.Context | yes | Context of the call: cancellation and deadline. | |
approvalID | string | yes | Identifier (UUID) of the approval request. | |
body | any | yes | Reason of the cancellation. | |
opts | ...CallOption | no | Per call options (query, idempotency key, traceparent, headers). |
Returns: (json.RawMessage, error). Decoded JSON answer of the operation "Cancel an approval request". The error is a typed error of the SDK, nil on success.
Raises: error, the typed errors of the transport (Errors).
ApprovalsService.Create
Create(ctx context.Context, body any, opts ...CallOption) (json.RawMessage, error)
Request an approval. Creates a pending approval request. Needs tenant_admin, developer, agent, security_officer or finops.
Route: /v1/approvals (POST).
| Name | Type | Default | Required | Description |
|---|---|---|---|---|
ctx | context.Context | yes | Context of the call: cancellation and deadline. | |
body | any | yes | Action, resource, quorum, approvers and expiry of the request. | |
opts | ...CallOption | no | Per call options (query, idempotency key, traceparent, headers). |
Returns: (json.RawMessage, error). Decoded JSON answer of the operation "Request an approval". The error is a typed error of the SDK, nil on success.
Raises: error, the typed errors of the transport (Errors).
ApprovalsService.Decide
Decide(ctx context.Context, id string, body any, opts ...CallOption) (json.RawMessage, error)
Approve or reject a request. Records the decision of the caller on a pending request.
Route: /v1/approvals/{approval_id}/decide (POST).
| Name | Type | Default | Required | Description |
|---|---|---|---|---|
ctx | context.Context | yes | Context of the call: cancellation and deadline. | |
id | string | yes | Identifier (UUID) of the approval request. | |
body | any | yes | Decision and optional comment. | |
opts | ...CallOption | no | Per call options (query, idempotency key, traceparent, headers). |
Returns: (json.RawMessage, error). Decoded JSON answer of the operation "Approve or reject a request". The error is a typed error of the SDK, nil on success.
Raises: error, the typed errors of the transport (Errors).
ApprovalsService.Get
Get(ctx context.Context, id string, opts ...CallOption) (json.RawMessage, error)
Get an approval request. Returns one approval request with its decisions (approver, decision, comment, date) and approvals_count. A pending request past its expiry is marked expired and its waiting run is failed. Open to any member of the tenant. Answers 404 approval_not_found.
Route: /v1/approvals/{approval_id} (GET).
| Name | Type | Default | Required | Description |
|---|---|---|---|---|
ctx | context.Context | yes | Context of the call: cancellation and deadline. | |
id | string | yes | Identifier (UUID) of the approval request. | |
opts | ...CallOption | no | Per call options (query, idempotency key, traceparent, headers). |
Returns: (json.RawMessage, error). Decoded JSON answer of the operation "Get an approval request". The error is a typed error of the SDK, nil on success.
Raises: error, the typed errors of the transport (Errors).
ApprovalsService.List
List(ctx context.Context, opts ...CallOption) (*Page, error)
List the approval requests. Lists the approval requests of the tenant, newest first, paginated, optionally filtered by status. Pending requests past their expiry are marked expired first. Each item carries its decisions and approvals_count. Open to any member of the tenant.
Route: /v1/approvals (GET).
| Name | Type | Default | Required | Description |
|---|---|---|---|---|
ctx | context.Context | yes | Context of the call: cancellation and deadline. | |
opts | ...CallOption | no | Per call options (query, idempotency key, traceparent, headers). |
Returns: (*Page, error). A Page: Page is one page of a cursor paginated collection {"items": [...], "next_cursor": "..."|null}. The error is a typed error of the SDK, nil on success.
Raises: error, the typed errors of the transport (Errors).
Class RiskService
RiskService groups the endpoints of: Risk assessments, controls, exceptions and evidence.
RiskService.CreateAssessment
CreateAssessment(ctx context.Context, body any, opts ...CallOption) (json.RawMessage, error)
Assess the risk of an AI system. Classifies the target under the EU AI Act and records the assessment. Needs tenant_admin, security_officer, developer or ai_governance_officer; the status approved needs tenant_admin, security_officer or ai_governance_officer (403 forbidden).
Route: /v1/risk/assessments (POST).
| Name | Type | Default | Required | Description |
|---|---|---|---|---|
ctx | context.Context | yes | Context of the call: cancellation and deadline. | |
body | any | yes | Target, use cases, answers, owner, status and evidence of the assessment. | |
opts | ...CallOption | no | Per call options (query, idempotency key, traceparent, headers). |
Returns: (json.RawMessage, error). Decoded JSON answer of the operation "Assess the risk of an AI system". The error is a typed error of the SDK, nil on success.
Raises: error, the typed errors of the transport (Errors).
RiskService.CreateControl
CreateControl(ctx context.Context, body any, opts ...CallOption) (json.RawMessage, error)
Adopt or update a control. Creates or updates the control of the given code. For a catalogue code, the title and frameworks default to the catalogue ones. Needs tenant_admin or security_officer. Errors 400 invalid_request: status other than planned, implemented, partially_implemented or not_applicable; no title for a custom code; a framework other than iso_42001, nist_ai_rmf, gdpr or eu_ai_act. Evidence given is added. Writes the audit event risk.control.upsert.
Route: /v1/risk/controls (POST).
| Name | Type | Default | Required | Description |
|---|---|---|---|---|
ctx | context.Context | yes | Context of the call: cancellation and deadline. | |
body | any | yes | Code, title, frameworks, status, owner and evidence of the control. | |
opts | ...CallOption | no | Per call options (query, idempotency key, traceparent, headers). |
Returns: (json.RawMessage, error). Decoded JSON answer of the operation "Adopt or update a control". The error is a typed error of the SDK, nil on success.
Raises: error, the typed errors of the transport (Errors).
RiskService.CreateException
CreateException(ctx context.Context, body any, opts ...CallOption) (json.RawMessage, error)
Request a control exception. Records a time limited exception on a control (control_id or control_code) or on a target (target_ref). Needs tenant_admin, security_officer or developer.
Route: /v1/risk/exceptions (POST).
| Name | Type | Default | Required | Description |
|---|---|---|---|---|
ctx | context.Context | yes | Context of the call: cancellation and deadline. | |
body | any | yes | Control or target, reason, compensating controls, approver and expiry. | |
opts | ...CallOption | no | Per call options (query, idempotency key, traceparent, headers). |
Returns: (json.RawMessage, error). Decoded JSON answer of the operation "Request a control exception". The error is a typed error of the SDK, nil on success.
Raises: error, the typed errors of the transport (Errors).
RiskService.Evidence
Evidence(ctx context.Context, opts ...CallOption) (json.RawMessage, error)
Get the compliance evidence. Returns the evidence recorded on controls and assessments, newest first, plus evidence collected automatically from the platform and mapped to the catalogue controls: counts of agents, tools, models, assessments, enabled DLP rules and retention policies, keys, audit events and exports with the state of the audit chain, evaluations, red team runs, incidents and approvals. Open to any member of the tenant.
Route: /v1/risk/evidence (GET).
| Name | Type | Default | Required | Description |
|---|---|---|---|---|
ctx | context.Context | yes | Context of the call: cancellation and deadline. | |
opts | ...CallOption | no | Per call options (query, idempotency key, traceparent, headers). |
Returns: (json.RawMessage, error). Decoded JSON answer of the operation "Get the compliance evidence". The error is a typed error of the SDK, nil on success.
Raises: error, the typed errors of the transport (Errors).
RiskService.ListAssessments
ListAssessments(ctx context.Context, opts ...CallOption) (*Page, error)
List the risk assessments. Lists the assessments of the tenant, newest first, at most 500, optionally for one target. Each item gives the target, eu_ai_act_category (also as risk_level), use cases, answers, rationale, obligations, status and owner. Open to any member of the tenant. next_cursor is always null.
Route: /v1/risk/assessments (GET).
| Name | Type | Default | Required | Description |
|---|---|---|---|---|
ctx | context.Context | yes | Context of the call: cancellation and deadline. | |
opts | ...CallOption | no | Per call options (query, idempotency key, traceparent, headers). |
Returns: (*Page, error). A Page: Page is one page of a cursor paginated collection {"items": [...], "next_cursor": "..."|null}. The error is a typed error of the SDK, nil on success.
Raises: error, the typed errors of the transport (Errors).
RiskService.ListControls
ListControls(ctx context.Context, opts ...CallOption) (*Page, error)
List the controls. Lists the controls adopted by the tenant, ordered by code, each with evidence_count, its exceptions and active_exceptions, and the builtin catalog with adopted telling which ones the tenant uses. Open to any member of the tenant.
Route: /v1/risk/controls (GET).
| Name | Type | Default | Required | Description |
|---|---|---|---|---|
ctx | context.Context | yes | Context of the call: cancellation and deadline. | |
opts | ...CallOption | no | Per call options (query, idempotency key, traceparent, headers). |
Returns: (*Page, error). A Page: Page is one page of a cursor paginated collection {"items": [...], "next_cursor": "..."|null}. The error is a typed error of the SDK, nil on success.
Raises: error, the typed errors of the transport (Errors).
Class IncidentsService
IncidentsService groups the endpoints of: Incidents and containment actions.
IncidentsService.Action
Action(ctx context.Context, id string, body any, opts ...CallOption) (json.RawMessage, error)
Run a containment action. Runs a containment action through the domain that owns the target and records it on the incident. Needs tenant_admin or security_officer.
Route: /v1/incidents/{incident_id}/actions (POST).
| Name | Type | Default | Required | Description |
|---|---|---|---|---|
ctx | context.Context | yes | Context of the call: cancellation and deadline. | |
id | string | yes | Identifier (UUID) of the incident. | |
body | any | yes | Action, target and reason. | |
opts | ...CallOption | no | Per call options (query, idempotency key, traceparent, headers). |
Returns: (json.RawMessage, error). Decoded JSON answer of the operation "Run a containment action". The error is a typed error of the SDK, nil on success.
Raises: error, the typed errors of the transport (Errors).
IncidentsService.Create
Create(ctx context.Context, body any, opts ...CallOption) (json.RawMessage, error)
Open an incident. Opens an incident in status open, adds the created entry to the timeline and forwards it to the SIEM. Needs tenant_admin, security_officer, developer or agent. An unknown severity answers 400 invalid_request. Writes the audit event incident.create. The answer (201) carries the incident with its timeline.
Route: /v1/incidents (POST).
| Name | Type | Default | Required | Description |
|---|---|---|---|---|
ctx | context.Context | yes | Context of the call: cancellation and deadline. | |
body | any | yes | Title, severity, description, category, resources and assignee. | |
opts | ...CallOption | no | Per call options (query, idempotency key, traceparent, headers). |
Returns: (json.RawMessage, error). Decoded JSON answer of the operation "Open an incident". The error is a typed error of the SDK, nil on success.
Raises: error, the typed errors of the transport (Errors).
IncidentsService.Get
Get(ctx context.Context, id string, opts ...CallOption) (json.RawMessage, error)
Get an incident. Returns the incident with its timeline (kind, message, data, actor, date) and its containment actions (action, target, status, result). Open to any member of the tenant. Answers 404 not_found.
Route: /v1/incidents/{incident_id} (GET).
| Name | Type | Default | Required | Description |
|---|---|---|---|---|
ctx | context.Context | yes | Context of the call: cancellation and deadline. | |
id | string | yes | Identifier (UUID) of the incident. | |
opts | ...CallOption | no | Per call options (query, idempotency key, traceparent, headers). |
Returns: (json.RawMessage, error). Decoded JSON answer of the operation "Get an incident". The error is a typed error of the SDK, nil on success.
Raises: error, the typed errors of the transport (Errors).
IncidentsService.List
List(ctx context.Context, opts ...CallOption) (*Page, error)
List the incidents. Lists the incidents of the tenant, newest identifier first, paginated, optionally filtered by status and severity. Items do not carry the timeline nor the actions (read one incident for those). Open to any member of the tenant.
Route: /v1/incidents (GET).
| Name | Type | Default | Required | Description |
|---|---|---|---|---|
ctx | context.Context | yes | Context of the call: cancellation and deadline. | |
opts | ...CallOption | no | Per call options (query, idempotency key, traceparent, headers). |
Returns: (*Page, error). A Page: Page is one page of a cursor paginated collection {"items": [...], "next_cursor": "..."|null}. The error is a typed error of the SDK, nil on success.
Raises: error, the typed errors of the transport (Errors).
IncidentsService.Update
Update(ctx context.Context, id string, body any, opts ...CallOption) (json.RawMessage, error)
Update an incident. Changes the status, severity or assignee and optionally adds a note. Each change is added to the timeline and forwarded to the SIEM; moving to resolved or closed sets resolved_at. Needs tenant_admin or security_officer. An unknown status or severity answers 400 invalid_request. Writes the audit event incident.update.
Route: /v1/incidents/{incident_id} (PATCH).
| Name | Type | Default | Required | Description |
|---|---|---|---|---|
ctx | context.Context | yes | Context of the call: cancellation and deadline. | |
id | string | yes | Identifier (UUID) of the incident. | |
body | any | yes | Fields to change and an optional note. | |
opts | ...CallOption | no | Per call options (query, idempotency key, traceparent, headers). |
Returns: (json.RawMessage, error). Decoded JSON answer of the operation "Update an incident". The error is a typed error of the SDK, nil on success.
Raises: error, the typed errors of the transport (Errors).
Class GovernanceService
GovernanceService groups the endpoints of: Governance registry of agents, models, tools and owners.
GovernanceService.Registry
Registry(ctx context.Context, opts ...CallOption) (json.RawMessage, error)
Read the governance registry. Inventory of agents, models, providers, tools, skills, plugins and connectors (5000 items per kind at most, by name), one list per kind (agents, models, ...), with a summary per kind: total, count by status, count by risk level (unassessed when none) and number of items without owner. missing_sources lists the tables not installed on this instance; their list is empty. Requires a tenant principal (403 tenant_required). An unknown kind answers 400 invalid_request with the allowed kinds.
Route: /v1/governance/registry (GET).
| Name | Type | Default | Required | Description |
|---|---|---|---|---|
ctx | context.Context | yes | Context of the call: cancellation and deadline. | |
opts | ...CallOption | no | Per call options (query, idempotency key, traceparent, headers). |
Returns: (json.RawMessage, error). Decoded JSON answer of the operation "Read the governance registry". The error is a typed error of the SDK, nil on success.
Raises: error, the typed errors of the transport (Errors).
Class SecretsService
SecretsService groups the endpoints of: Write only secrets (OpenBao).
SecretsService.Delete
Delete(ctx context.Context, path string, opts ...CallOption) error
Delete a secret. Deletes the secret and, with OpenBao, its value in the vault. Needs tenant_admin, security_officer or developer; a developer only deletes the secrets they wrote (403 forbidden). Objects that still refer to the path stop working. Writes the audit event secret.delete. Answers 204, 404 not_found, or 502 secret_backend_error when the vault cannot be reached.
Route: /v1/secrets/{path} (DELETE).
| Name | Type | Default | Required | Description |
|---|---|---|---|---|
ctx | context.Context | yes | Context of the call: cancellation and deadline. | |
path | string | yes | Path of the secret, slashes included, for example connectors/crm/password. | |
opts | ...CallOption | no | Per call options (query, idempotency key, traceparent, headers). |
Returns: error. Error of the call (a typed error of the SDK), nil on success.
Raises: error, the typed errors of the transport (Errors).
SecretsService.List
List(ctx context.Context, opts ...CallOption) (*Page, error)
List the secrets. Lists the metadata of the tenant secrets ordered by path: id, path, backend (openbao or local), version, created_by, created_at, updated_at. Never the value. Open to any member of the tenant. next_cursor is always null.
Route: /v1/secrets (GET).
| Name | Type | Default | Required | Description |
|---|---|---|---|---|
ctx | context.Context | yes | Context of the call: cancellation and deadline. | |
opts | ...CallOption | no | Per call options (query, idempotency key, traceparent, headers). |
Returns: (*Page, error). A Page: Page is one page of a cursor paginated collection {"items": [...], "next_cursor": "..."|null}. The error is a typed error of the SDK, nil on success.
Raises: error, the typed errors of the transport (Errors).
SecretsService.Put
Put(ctx context.Context, body any, opts ...CallOption) (json.RawMessage, error)
Write a secret. Creates the secret, or replaces its value when the path exists (the version grows by one). Needs tenant_admin, security_officer or developer; a developer only overwrites the secrets they wrote (403 forbidden). A path with a .. segment answers 400 invalid_request. The answer (201) gives the metadata, never the value. Writes the audit event secret.write. 502 secret_backend_error when the vault cannot be reached.
Route: /v1/secrets (POST).
| Name | Type | Default | Required | Description |
|---|---|---|---|---|
ctx | context.Context | yes | Context of the call: cancellation and deadline. | |
body | any | yes | Path and value of the secret. | |
opts | ...CallOption | no | Per call options (query, idempotency key, traceparent, headers). |
Returns: (json.RawMessage, error). Decoded JSON answer of the operation "Write a secret". The error is a typed error of the SDK, nil on success.
Raises: error, the typed errors of the transport (Errors).
Class ProvidersService
ProvidersService groups the endpoints of: LLM Provider Registry, kill switch and preset catalog.
ProvidersService.Catalog
Catalog(ctx context.Context, opts ...CallOption) (json.RawMessage, error)
Read the provider catalog. Every provider type the platform supports, with the fields and credentials it needs, labels in the language of the request, the configured providers of each type, and how its models are found (api: listing API, manual_only: typed by the administrator). Requires a reader role.
Route: /v1/providers/catalog (GET).
| Name | Type | Default | Required | Description |
|---|---|---|---|---|
ctx | context.Context | yes | Context of the call: cancellation and deadline. | |
opts | ...CallOption | no | Per call options (query, idempotency key, traceparent, headers). |
Returns: (json.RawMessage, error). Decoded JSON answer of the operation "Read the provider catalog". The error is a typed error of the SDK, nil on success.
Raises: error, the typed errors of the transport (Errors).
ProvidersService.Create
Create(ctx context.Context, body any, opts ...CallOption) (json.RawMessage, error)
Create a model provider. Creates a provider for the tenant, or a shared one with scope: platform (platform_admin only), and answers 201 without the credentials. Requires tenant_admin, platform_admin or ai_platform_engineer.
Route: /v1/providers (POST).
| Name | Type | Default | Required | Description |
|---|---|---|---|---|
ctx | context.Context | yes | Context of the call: cancellation and deadline. | |
body | any | yes | provider_type (or type, a catalog type or alias), optional name (default the type), api_base (or base_url), config, credentials (secret fields), regions, retention, scope (platform for a shared provider). | |
opts | ...CallOption | no | Per call options (query, idempotency key, traceparent, headers). |
Returns: (json.RawMessage, error). Decoded JSON answer of the operation "Create a model provider". The error is a typed error of the SDK, nil on success.
Raises: error, the typed errors of the transport (Errors).
ProvidersService.Delete
Delete(ctx context.Context, id string, opts ...CallOption) error
Delete a model provider. Deletes the provider and answers 204; a shared provider needs platform_admin (403 platform_only). Audited (provider.delete). Unknown or invisible provider: 404 provider_not_found. Requires tenant_admin, platform_admin or ai_platform_engineer.
Route: /v1/providers/{pid} (DELETE).
| Name | Type | Default | Required | Description |
|---|---|---|---|---|
ctx | context.Context | yes | Context of the call: cancellation and deadline. | |
id | string | yes | Identifier (UUID) of the provider. | |
opts | ...CallOption | no | Per call options (query, idempotency key, traceparent, headers). |
Returns: error. Error of the call (a typed error of the SDK), nil on success.
Raises: error, the typed errors of the transport (Errors).
ProvidersService.Disable
Disable(ctx context.Context, id string, opts ...CallOption) (json.RawMessage, error)
Disable a provider (kill switch). Kill switch of the provider: the gateway refuses its models at once (403 provider_disabled) and discovery is refused (409). A shared provider needs platform_admin. Audited (provider.disable). Requires tenant_admin, platform_admin, ai_platform_engineer or security_officer.
Route: /v1/providers/{pid}/disable (POST).
| Name | Type | Default | Required | Description |
|---|---|---|---|---|
ctx | context.Context | yes | Context of the call: cancellation and deadline. | |
id | string | yes | Identifier (UUID) of the provider. | |
opts | ...CallOption | no | Per call options (query, idempotency key, traceparent, headers). |
Returns: (json.RawMessage, error). Decoded JSON answer of the operation "Disable a provider (kill switch)". The error is a typed error of the SDK, nil on success.
Raises: error, the typed errors of the transport (Errors).
ProvidersService.Enable
Enable(ctx context.Context, id string, opts ...CallOption) (json.RawMessage, error)
Enable a disabled provider. Lifts the kill switch of the provider. A shared provider needs platform_admin. Audited (provider.enable). Requires tenant_admin, platform_admin or ai_platform_engineer.
Route: /v1/providers/{pid}/enable (POST).
| Name | Type | Default | Required | Description |
|---|---|---|---|---|
ctx | context.Context | yes | Context of the call: cancellation and deadline. | |
id | string | yes | Identifier (UUID) of the provider. | |
opts | ...CallOption | no | Per call options (query, idempotency key, traceparent, headers). |
Returns: (json.RawMessage, error). Decoded JSON answer of the operation "Enable a disabled provider". The error is a typed error of the SDK, nil on success.
Raises: error, the typed errors of the transport (Errors).
ProvidersService.Get
Get(ctx context.Context, id string, opts ...CallOption) (json.RawMessage, error)
Get a configured provider. One provider without its credentials. A provider of another tenant, or an id that is not a UUID, answers 404 provider_not_found. Requires a reader role.
Route: /v1/providers/{pid} (GET).
| Name | Type | Default | Required | Description |
|---|---|---|---|---|
ctx | context.Context | yes | Context of the call: cancellation and deadline. | |
id | string | yes | Identifier (UUID) of the provider. | |
opts | ...CallOption | no | Per call options (query, idempotency key, traceparent, headers). |
Returns: (json.RawMessage, error). Decoded JSON answer of the operation "Get a configured provider". The error is a typed error of the SDK, nil on success.
Raises: error, the typed errors of the transport (Errors).
ProvidersService.List
List(ctx context.Context, opts ...CallOption) (*Page, error)
List the configured providers. Shared providers and the providers of the caller's tenant, with their type, address, configuration, regions, retention, state and last test; credentials are never returned (only the names of the fields that are set). Requires a reader role.
Route: /v1/providers (GET).
| Name | Type | Default | Required | Description |
|---|---|---|---|---|
ctx | context.Context | yes | Context of the call: cancellation and deadline. | |
opts | ...CallOption | no | Per call options (query, idempotency key, traceparent, headers). |
Returns: (*Page, error). A Page: Page is one page of a cursor paginated collection {"items": [...], "next_cursor": "..."|null}. The error is a typed error of the SDK, nil on success.
Raises: error, the typed errors of the transport (Errors).
ProvidersService.Test
Test(ctx context.Context, id string, opts ...CallOption) (json.RawMessage, error)
Test a provider connection. Calls the listing endpoint of the provider with its stored credentials (for signed protocols such as Bedrock and Vertex, checks that the credential set is complete) and answers ok, the HTTP status, a detail and the models seen. The result is stored as the connection state and audited (provider.test). Requires tenant_admin, platform_admin or ai_platform_engineer.
Route: /v1/providers/{pid}/test (POST).
| Name | Type | Default | Required | Description |
|---|---|---|---|---|
ctx | context.Context | yes | Context of the call: cancellation and deadline. | |
id | string | yes | Identifier (UUID) of the provider. | |
opts | ...CallOption | no | Per call options (query, idempotency key, traceparent, headers). |
Returns: (json.RawMessage, error). Decoded JSON answer of the operation "Test a provider connection". The error is a typed error of the SDK, nil on success.
Raises: error, the typed errors of the transport (Errors).
ProvidersService.Update
Update(ctx context.Context, id string, body any, opts ...CallOption) (json.RawMessage, error)
Update a model provider. Changes the configuration, address, regions, retention or credentials of a provider. New credentials are written to the secret store and reset the connection state until the next test. A remote address must use TLS (422 tls_required) and pass the outbound address rules; an unknown credential field answers 422. A shared provider needs platform_admin. Audited (provider.update, without values). Requires tenant_admin, platform_admin or ai_platform_engineer.
Route: /v1/providers/{pid} (PATCH).
| Name | Type | Default | Required | Description |
|---|---|---|---|---|
ctx | context.Context | yes | Context of the call: cancellation and deadline. | |
id | string | yes | Identifier (UUID) of the provider. | |
body | any | yes | Fields to change: config, api_base (or base_url), credentials (secret fields; a secret field sent in config is moved to them), regions, retention. | |
opts | ...CallOption | no | Per call options (query, idempotency key, traceparent, headers). |
Returns: (json.RawMessage, error). Decoded JSON answer of the operation "Update a model provider". The error is a typed error of the SDK, nil on success.
Raises: error, the typed errors of the transport (Errors).
Class ModelsService
ModelsService groups the endpoints of: Model registry, lifecycle status and Capability Resolver.
ModelsService.Create
Create(ctx context.Context, body any, opts ...CallOption) (json.RawMessage, error)
Register a model. Registers a model for the tenant, or a shared one with scope: platform (platform_admin only), and answers 201. The body is a Model Manifest v1 or a bare spec; it must be valid (422 invalid_manifest) and its category must exist. A model id already registered in the same scope answers 409 model_exists. Audited (model.create). Requires tenant_admin, platform_admin or ai_platform_engineer.
Route: /v1/models (POST).
| Name | Type | Default | Required | Description |
|---|---|---|---|---|
ctx | context.Context | yes | Context of the call: cancellation and deadline. | |
body | any | yes | A Model Manifest v1 (kind: Model, metadata, spec) or the spec alone (model_id, provider, provider_model_id, capabilities, context_window, status...), with the sheet fields, optional pricing and scope. | |
opts | ...CallOption | no | Per call options (query, idempotency key, traceparent, headers). |
Returns: (json.RawMessage, error). Decoded JSON answer of the operation "Register a model". The error is a typed error of the SDK, nil on success.
Raises: error, the typed errors of the transport (Errors).
ModelsService.Delete
Delete(ctx context.Context, modelID string, opts ...CallOption) error
Delete a model from the registry. Deletes the tenant entry of the model (an override of a shared model brings the shared entry back), or the shared entry when there is no tenant entry; the shared entry needs platform_admin (403 platform_only). Answers 204; audited (model.delete). Unknown model: 404 model_not_found. Requires tenant_admin, platform_admin or ai_platform_engineer.
Route: /v1/models/{model_id} (DELETE).
| Name | Type | Default | Required | Description |
|---|---|---|---|---|
ctx | context.Context | yes | Context of the call: cancellation and deadline. | |
modelID | string | yes | Registry identifier of the model (not the provider model id). | |
opts | ...CallOption | no | Per call options (query, idempotency key, traceparent, headers). |
Returns: error. Error of the call (a typed error of the SDK), nil on success.
Raises: error, the typed errors of the transport (Errors).
ModelsService.Disable
Disable(ctx context.Context, modelID string, opts ...CallOption) (json.RawMessage, error)
Disable a model (kill switch). Kill switch of the model for the tenant: the gateway refuses it at once (403 model_disabled). On a shared model this creates a tenant override. Audited (model.disable). Requires tenant_admin, platform_admin, ai_platform_engineer or security_officer.
Route: /v1/models/{model_id}/disable (POST).
| Name | Type | Default | Required | Description |
|---|---|---|---|---|
ctx | context.Context | yes | Context of the call: cancellation and deadline. | |
modelID | string | yes | Registry identifier of the model. | |
opts | ...CallOption | no | Per call options (query, idempotency key, traceparent, headers). |
Returns: (json.RawMessage, error). Decoded JSON answer of the operation "Disable a model (kill switch)". The error is a typed error of the SDK, nil on success.
Raises: error, the typed errors of the transport (Errors).
ModelsService.Get
Get(ctx context.Context, modelID string, opts ...CallOption) (json.RawMessage, error)
Get a registered model. One model of the registry, or its Model Manifest v1 with format=manifest. Unknown model: 404 model_not_found. Requires a reader role.
Route: /v1/models/{model_id} (GET).
| Name | Type | Default | Required | Description |
|---|---|---|---|---|
ctx | context.Context | yes | Context of the call: cancellation and deadline. | |
modelID | string | yes | Registry identifier of the model. | |
opts | ...CallOption | no | Per call options (query, idempotency key, traceparent, headers). |
Returns: (json.RawMessage, error). Decoded JSON answer of the operation "Get a registered model". The error is a typed error of the SDK, nil on success.
Raises: error, the typed errors of the transport (Errors).
ModelsService.List
List(ctx context.Context, opts ...CallOption) (*Page, error)
List the registered models. Models visible to the caller (shared models with the tenant overrides applied, and the tenant models), optionally filtered. One page only (next_cursor is always null). Requires a reader role.
Route: /v1/models (GET).
| Name | Type | Default | Required | Description |
|---|---|---|---|---|
ctx | context.Context | yes | Context of the call: cancellation and deadline. | |
opts | ...CallOption | no | Per call options (query, idempotency key, traceparent, headers). |
Returns: (*Page, error). A Page: Page is one page of a cursor paginated collection {"items": [...], "next_cursor": "..."|null}. The error is a typed error of the SDK, nil on success.
Raises: error, the typed errors of the transport (Errors).
ModelsService.Resolve
Resolve(ctx context.Context, body any, opts ...CallOption) (json.RawMessage, error)
Resolve the native call parameters. Capability Resolver: translates normalized call parameters (for example the reasoning effort none, low, medium, high, max) into the native parameters of the model, from what its manifest declares. An unsupported value is rejected with an explicit code or adjusted with a warning in the answer, never silently. Unknown model: 404 model_not_found. Requires a reader role.
Route: /v1/models/resolve (POST).
| Name | Type | Default | Required | Description |
|---|---|---|---|---|
ctx | context.Context | yes | Context of the call: cancellation and deadline. | |
body | any | yes | model (or model_id) and the normalized parameters, either in params or at the top level of the body. | |
opts | ...CallOption | no | Per call options (query, idempotency key, traceparent, headers). |
Returns: (json.RawMessage, error). Decoded JSON answer of the operation "Resolve the native call parameters". The error is a typed error of the SDK, nil on success.
Raises: error, the typed errors of the transport (Errors).
ModelsService.SetStatus
SetStatus(ctx context.Context, modelID string, body any, opts ...CallOption) (json.RawMessage, error)
Change the status of a model. Sets the status to approved, restricted, deprecated or blocked (422 status_invalid otherwise). For a tenant, a promotion to approved is not applied at once: an approval request is opened and the answer is 202 with it; the status changes once it is approved. Other changes apply at once and are audited (model.status, with the previous and new status). Requires tenant_admin, platform_admin, ai_platform_engineer or security_officer.
Route: /v1/models/{model_id}/status (POST).
| Name | Type | Default | Required | Description |
|---|---|---|---|---|
ctx | context.Context | yes | Context of the call: cancellation and deadline. | |
modelID | string | yes | Registry identifier of the model. | |
body | any | yes | status (approved, restricted, deprecated or blocked) and an optional reason. | |
opts | ...CallOption | no | Per call options (query, idempotency key, traceparent, headers). |
Returns: (json.RawMessage, error). Decoded JSON answer of the operation "Change the status of a model". The error is a typed error of the SDK, nil on success.
Raises: error, the typed errors of the transport (Errors).
ModelsService.Update
Update(ctx context.Context, modelID string, body any, opts ...CallOption) (json.RawMessage, error)
Update a registered model. Changes fields of the model spec, the sheet (category, display_name, knowledge_cutoff) or the prices; the model id never changes. A tenant change of a shared model creates a tenant override. The merged spec must stay a valid Model Manifest v1 (422 invalid_manifest) and the category must exist. Audited (model.update). Requires tenant_admin, platform_admin or ai_platform_engineer.
Route: /v1/models/{model_id} (PATCH).
| Name | Type | Default | Required | Description |
|---|---|---|---|---|
ctx | context.Context | yes | Context of the call: cancellation and deadline. | |
modelID | string | yes | Registry identifier of the model. | |
body | any | yes | Spec fields to change, sheet fields and pricing (per million tokens: input_per_mtok, output_per_mtok, cached_input_per_mtok, cache_write_per_mtok; per unit: per_image, per_second, per_character; with a currency). Use POST .../status to change the status. | |
opts | ...CallOption | no | Per call options (query, idempotency key, traceparent, headers). |
Returns: (json.RawMessage, error). Decoded JSON answer of the operation "Update a registered model". The error is a typed error of the SDK, nil on success.
Raises: error, the typed errors of the transport (Errors).
Class RoutesService
RoutesService groups the endpoints of: Model Router rules and fallback chains.
RoutesService.Create
Create(ctx context.Context, body any, opts ...CallOption) (json.RawMessage, error)
Create a routing rule. Creates a routing rule of the tenant and answers 201. A platform principal without tenant answers 403 platform_only; an unknown strategy 422 parameter_invalid. Audited (route.create). Requires tenant_admin, platform_admin or ai_platform_engineer.
Route: /v1/routes (POST).
| Name | Type | Default | Required | Description |
|---|---|---|---|---|
ctx | context.Context | yes | Context of the call: cancellation and deadline. | |
body | any | yes | name (default default), match (request fields the rule applies to, a value or a list of values), strategy (priority by default, cost, latency, quality), candidates (model ids, or a single target_model), fallbacks, constraints, priority (default 100, lower first), enabled (default true). | |
opts | ...CallOption | no | Per call options (query, idempotency key, traceparent, headers). |
Returns: (json.RawMessage, error). Decoded JSON answer of the operation "Create a routing rule". The error is a typed error of the SDK, nil on success.
Raises: error, the typed errors of the transport (Errors).
RoutesService.Delete
Delete(ctx context.Context, id string, opts ...CallOption) error
Delete a routing rule. Deletes a routing rule of the tenant and answers 204. Unknown rule: 404 route_not_found. Audited (route.delete). Requires tenant_admin, platform_admin or ai_platform_engineer.
Route: /v1/routes/{rid} (DELETE).
| Name | Type | Default | Required | Description |
|---|---|---|---|---|
ctx | context.Context | yes | Context of the call: cancellation and deadline. | |
id | string | yes | Identifier of the routing rule. | |
opts | ...CallOption | no | Per call options (query, idempotency key, traceparent, headers). |
Returns: error. Error of the call (a typed error of the SDK), nil on success.
Raises: error, the typed errors of the transport (Errors).
RoutesService.List
List(ctx context.Context, opts ...CallOption) (*Page, error)
List the routing rules. Routing rules of the tenant by priority then name, each with its match, strategy, candidates, fallbacks, constraints and target_model (the first candidate). Requires a reader role.
Route: /v1/routes (GET).
| Name | Type | Default | Required | Description |
|---|---|---|---|---|
ctx | context.Context | yes | Context of the call: cancellation and deadline. | |
opts | ...CallOption | no | Per call options (query, idempotency key, traceparent, headers). |
Returns: (*Page, error). A Page: Page is one page of a cursor paginated collection {"items": [...], "next_cursor": "..."|null}. The error is a typed error of the SDK, nil on success.
Raises: error, the typed errors of the transport (Errors).
RoutesService.Replace
Replace(ctx context.Context, id string, body any, opts ...CallOption) (json.RawMessage, error)
Replace a routing rule. Replaces the match, strategy, candidates, fallbacks, constraints, priority and enabled flag of a rule of the tenant (omitted fields take their default; the name is kept). Unknown rule: 404 route_not_found. Audited (route.update). Requires tenant_admin, platform_admin or ai_platform_engineer.
Route: /v1/routes/{rid} (PUT).
| Name | Type | Default | Required | Description |
|---|---|---|---|---|
ctx | context.Context | yes | Context of the call: cancellation and deadline. | |
id | string | yes | Identifier of the routing rule. | |
body | any | yes | The complete rule: same fields as on creation except name. | |
opts | ...CallOption | no | Per call options (query, idempotency key, traceparent, headers). |
Returns: (json.RawMessage, error). Decoded JSON answer of the operation "Replace a routing rule". The error is a typed error of the SDK, nil on success.
Raises: error, the typed errors of the transport (Errors).
RoutesService.Simulate
Simulate(ctx context.Context, body any, opts ...CallOption) (json.RawMessage, error)
Simulate the routing of a request. Shows which model a request would be routed to, without calling it: the rule given by route_id or the first enabled rule that matches, the tenant allow and deny lists (narrowed by the request), the classification and the fallback policy. Answers the selected model, fallbacks, rejected candidates with their reason and the rule used; no eligible model answers 422 no_eligible_model. Restricted models are only allowed for tenant_admin and security_officer with allow_restricted. Requires a reader role.
Route: /v1/routes/simulate (POST).
| Name | Type | Default | Required | Description |
|---|---|---|---|---|
ctx | context.Context | yes | Context of the call: cancellation and deadline. | |
body | any | yes | Request to simulate: model, candidates, strategy, purpose, capabilities, data_classification (default internal), region_allow, provider_allow, model_allow, allow_restricted, fallback_policy (default allowed), optional route_id, and any field the rules match on. | |
opts | ...CallOption | no | Per call options (query, idempotency key, traceparent, headers). |
Returns: (json.RawMessage, error). Decoded JSON answer of the operation "Simulate the routing of a request". The error is a typed error of the SDK, nil on success.
Raises: error, the typed errors of the transport (Errors).
Class LiteLLMService
LiteLLMService groups the endpoints of: Generated LiteLLM configuration.
LiteLLMService.Config
Config(ctx context.Context, opts ...CallOption) (json.RawMessage, error)
Generate the LiteLLM configuration. LiteLLM proxy configuration generated from the visible models and the enabled providers (a tenant provider wins over a shared one of the same type). It never holds a secret value: credentials are os.environ/<NAME> references resolved by the LiteLLM deployment. Requires tenant_admin, platform_admin, ai_platform_engineer, security_officer or auditor.
Route: /v1/litellm/config (GET).
| Name | Type | Default | Required | Description |
|---|---|---|---|---|
ctx | context.Context | yes | Context of the call: cancellation and deadline. | |
opts | ...CallOption | no | Per call options (query, idempotency key, traceparent, headers). |
Returns: (json.RawMessage, error). Decoded JSON answer of the operation "Generate the LiteLLM configuration". The error is a typed error of the SDK, nil on success.
Raises: error, the typed errors of the transport (Errors).
LiteLLMService.Sync
Sync(ctx context.Context, opts ...CallOption) (json.RawMessage, error)
Push the configuration to LiteLLM. Makes the LiteLLM proxy hold exactly the generated model list: models created by the Control Plane and no longer wanted are removed, missing ones are added; models added by hand in LiteLLM are left alone. Without EAI_LITELLM_URL nothing is pushed (mode: in_process). A transport error answers 502 upstream_error. Audited (litellm.sync). Requires tenant_admin, platform_admin or ai_platform_engineer.
Route: /v1/litellm/sync (POST).
| Name | Type | Default | Required | Description |
|---|---|---|---|---|
ctx | context.Context | yes | Context of the call: cancellation and deadline. | |
opts | ...CallOption | no | Per call options (query, idempotency key, traceparent, headers). |
Returns: (json.RawMessage, error). Decoded JSON answer of the operation "Push the configuration to LiteLLM". The error is a typed error of the SDK, nil on success.
Raises: error, the typed errors of the transport (Errors).
Class AdaptersService
AdaptersService groups the endpoints of: Specialized adapters (video, realtime voice, batch).
AdaptersService.List
List(ctx context.Context, opts ...CallOption) (json.RawMessage, error)
List the specialized adapters. Specialized adapters of the gateway (image generation, speech to text, text to speech, video generation...) with their modality, label in the language of the request and in both languages, status (configured when their address is set, else not_configured) and the controls applied to them. Requires a reader role.
Route: /v1/adapters (GET).
| Name | Type | Default | Required | Description |
|---|---|---|---|---|
ctx | context.Context | yes | Context of the call: cancellation and deadline. | |
opts | ...CallOption | no | Per call options (query, idempotency key, traceparent, headers). |
Returns: (json.RawMessage, error). Decoded JSON answer of the operation "List the specialized adapters". The error is a typed error of the SDK, nil on success.
Raises: error, the typed errors of the transport (Errors).
Class ContextService
ContextService groups the endpoints of: Context Manager budget and compression planning.
ContextService.Plan
Plan(ctx context.Context, body any, opts ...CallOption) (json.RawMessage, error)
Plan the context window. Context Manager dry run: computes the token budget of a model window (output, reasoning and safety reserves) and which segments are kept, compressed or dropped by priority. With model, the window and output reserve come from the registry. A window that is not a positive integer answers 422 parameter_invalid; segments that cannot fit answer 422 context_overflow. Requires a reader role.
Route: /v1/context/plan (POST).
| Name | Type | Default | Required | Description |
|---|---|---|---|---|
ctx | context.Context | yes | Context of the call: cancellation and deadline. | |
body | any | yes | model (or model_id), or window (tokens); output (reserved output tokens, default the model maximum capped at 4096), reasoning (reserved reasoning tokens), safety (margin) and segments (each with type, optional segment_id, priority, classification and its content). | |
opts | ...CallOption | no | Per call options (query, idempotency key, traceparent, headers). |
Returns: (json.RawMessage, error). Decoded JSON answer of the operation "Plan the context window". The error is a typed error of the SDK, nil on success.
Raises: error, the typed errors of the transport (Errors).
Class GatewayService
GatewayService groups the endpoints of: AI Gateway, the only path agents use to call models (OpenAI compatible bodies plus the eai extension).
GatewayService.AudioSpeech
AudioSpeech(ctx context.Context, body any, opts ...CallOption) ([]byte, error)
Synthesize speech from text. Text to speech through the TTS adapter, in the OpenAI audio/speech format; the audio comes back as is (audio/*). The tenant kill switch, data classification and caller clearance, secret isolation and audit apply, and the cost is reserved from the quotas by number of characters. Requires a tenant principal with the scope models:invoke. Without a configured adapter: 501 adapter_not_available; adapter unreachable: 502 upstream_error.
Route: /v1/gateway/audio/speech (POST).
| Name | Type | Default | Required | Description |
|---|---|---|---|---|
ctx | context.Context | yes | Context of the call: cancellation and deadline. | |
body | any | yes | OpenAI speech request (model, input, voice, response_format...) plus the optional eai object (data_classification, agent_id, run_id). | |
opts | ...CallOption | no | Per call options (query, idempotency key, traceparent, headers). |
Returns: ([]byte, error). Decoded JSON answer of the operation "Synthesize speech from text". The error is a typed error of the SDK, nil on success.
Raises: error, the typed errors of the transport (Errors).
GatewayService.AudioTranscriptions
AudioTranscriptions(ctx context.Context, body any, opts ...CallOption) (json.RawMessage, error)
Transcribe an audio file. Speech to text through the STT adapter, in the OpenAI audio/transcriptions format. Requires a tenant principal with the scope models:invoke.
Route: /v1/gateway/audio/transcriptions (POST).
| Name | Type | Default | Required | Description |
|---|---|---|---|---|
ctx | context.Context | yes | Context of the call: cancellation and deadline. | |
body | any | yes | Multipart file plus model, language, prompt, response_format (json, text, srt, verbose_json, vtt), temperature (0 to 1), timestamp_granularities (word, segment) and eai (a JSON object as text); or JSON with content_base64, mime_type, filename and the same fields. | |
opts | ...CallOption | no | Per call options (query, idempotency key, traceparent, headers). |
Returns: (json.RawMessage, error). Decoded JSON answer of the operation "Transcribe an audio file". The error is a typed error of the SDK, nil on success.
Raises: error, the typed errors of the transport (Errors).
GatewayService.ChatCompletionsRaw
ChatCompletionsRaw(ctx context.Context, body any, opts ...CallOption) (json.RawMessage, error)
Call a chat model. OpenAI compatible chat completion through every control of the gateway; with stream: true the answer is Server-Sent Events, with the cost guardrails checked during the stream. Requires a tenant principal (403 platform_only) whose credential carries the scope models:invoke.
Route: /v1/gateway/chat/completions (POST).
| Name | Type | Default | Required | Description |
|---|---|---|---|---|
ctx | context.Context | yes | Context of the call: cancellation and deadline. | |
body | any | yes | OpenAI chat request (model is the registry id, messages, stream, max_tokens, tools...) plus the optional eai object: data_classification (public, internal by default, confidential, restricted, secret), agent_id, session_id, run_id, purpose, project_id, effort, max_cost, fallback_policy and allow lists that can only narrow the tenant ones (provider_allow, model_allow, region_allow). | |
opts | ...CallOption | no | Per call options (query, idempotency key, traceparent, headers). |
Returns: (json.RawMessage, error). Decoded JSON answer of the operation "Call a chat model". The error is a typed error of the SDK, nil on success.
Raises: error, the typed errors of the transport (Errors).
GatewayService.Embeddings
Embeddings(ctx context.Context, body any, opts ...CallOption) (json.RawMessage, error)
Compute embeddings. OpenAI compatible embeddings through the same controls as chat (kill switches, allow lists, classification, DLP on each input, cost guardrails, policy decision, audit). The model must declare the embeddings capability and, when dimensions is given, support it (422 capability_not_supported, 422 embedding_dimensions_invalid). Requires a tenant principal with the scope models:invoke.
Route: /v1/gateway/embeddings (POST).
| Name | Type | Default | Required | Description |
|---|---|---|---|---|
ctx | context.Context | yes | Context of the call: cancellation and deadline. | |
body | any | yes | OpenAI embeddings request (model, input as a text or a list, optional dimensions) plus the optional eai object. | |
opts | ...CallOption | no | Per call options (query, idempotency key, traceparent, headers). |
Returns: (json.RawMessage, error). Decoded JSON answer of the operation "Compute embeddings". The error is a typed error of the SDK, nil on success.
Raises: error, the typed errors of the transport (Errors).
GatewayService.Estimate
Estimate(ctx context.Context, body any, opts ...CallOption) (json.RawMessage, error)
Estimate a gateway call. Runs every preflight control of the gateway without calling the model and returns the resolved model, decision id, input tokens, maximum output tokens, estimator, estimated cost, cost limit, fallbacks, warnings and context plan. A request refused by a control answers with the same error as the real call. Requires a tenant principal with the scope models:invoke.
Route: /v1/gateway/estimate (POST).
| Name | Type | Default | Required | Description |
|---|---|---|---|---|
ctx | context.Context | yes | Context of the call: cancellation and deadline. | |
body | any | yes | The body of the call to estimate, with optional kind (chat, embeddings or rerank); without kind it is guessed from input (embeddings) or query (rerank), else chat. | |
opts | ...CallOption | no | Per call options (query, idempotency key, traceparent, headers). |
Returns: (json.RawMessage, error). Decoded JSON answer of the operation "Estimate a gateway call". The error is a typed error of the SDK, nil on success.
Raises: error, the typed errors of the transport (Errors).
GatewayService.ImageGenerations
ImageGenerations(ctx context.Context, body any, opts ...CallOption) (json.RawMessage, error)
Generate images. Image generation through the image adapter in the OpenAI format. The prompt goes through the DLP of the tenant (422 dlp_blocked), the kill switch, classification, secret isolation and audit apply, and the cost is reserved by number of images; text fields of the answer (revised_prompt) are scanned too. Requires a tenant principal with the scope models:invoke. Without a configured adapter: 501 adapter_not_available.
Route: /v1/gateway/images/generations (POST).
| Name | Type | Default | Required | Description |
|---|---|---|---|---|
ctx | context.Context | yes | Context of the call: cancellation and deadline. | |
body | any | yes | OpenAI image request (model, prompt, n, size...) plus the optional eai object. | |
opts | ...CallOption | no | Per call options (query, idempotency key, traceparent, headers). |
Returns: (json.RawMessage, error). Decoded JSON answer of the operation "Generate images". The error is a typed error of the SDK, nil on success.
Raises: error, the typed errors of the transport (Errors).
GatewayService.Rerank
Rerank(ctx context.Context, body any, opts ...CallOption) (json.RawMessage, error)
Rerank documents. Reranks documents against a query through the same controls as chat (DLP on the query, cost guardrails, policy decision, audit). The model must declare the rerank capability (422 capability_not_supported). Requires a tenant principal with the scope models:invoke.
Route: /v1/gateway/rerank (POST).
| Name | Type | Default | Required | Description |
|---|---|---|---|---|
ctx | context.Context | yes | Context of the call: cancellation and deadline. | |
body | any | yes | Rerank request: model, query, documents (texts or objects), optional top_n, plus the optional eai object. | |
opts | ...CallOption | no | Per call options (query, idempotency key, traceparent, headers). |
Returns: (json.RawMessage, error). Decoded JSON answer of the operation "Rerank documents". The error is a typed error of the SDK, nil on success.
Raises: error, the typed errors of the transport (Errors).
GatewayService.VideoGeneration
VideoGeneration(ctx context.Context, id string, opts ...CallOption) (json.RawMessage, error)
Read a video generation job. State and result of a video generation job, read from the video adapter with the same kill switch and audit as the other adapter calls. Requires a tenant principal (403 platform_only otherwise) whose credential carries the scope models:invoke. Without a configured video adapter: 501 adapter_not_available.
Route: /v1/gateway/video/generations/{job_id} (GET).
| Name | Type | Default | Required | Description |
|---|---|---|---|---|
ctx | context.Context | yes | Context of the call: cancellation and deadline. | |
id | string | yes | Identifier of the job returned by POST /v1/gateway/video/generations. | |
opts | ...CallOption | no | Per call options (query, idempotency key, traceparent, headers). |
Returns: (json.RawMessage, error). Decoded JSON answer of the operation "Read a video generation job". The error is a typed error of the SDK, nil on success.
Raises: error, the typed errors of the transport (Errors).
GatewayService.VideoGenerations
VideoGenerations(ctx context.Context, body any, opts ...CallOption) (json.RawMessage, error)
Start a video generation. Starts a video generation job on the video adapter, with the same kill switch, classification, DLP of the prompt, cost reservation and audit as the other adapters; read the job with GET /v1/gateway/video/generations/{job_id}. Requires a tenant principal with the scope models:invoke. Without a configured adapter: 501 adapter_not_available.
Route: /v1/gateway/video/generations (POST).
| Name | Type | Default | Required | Description |
|---|---|---|---|---|
ctx | context.Context | yes | Context of the call: cancellation and deadline. | |
body | any | yes | Video generation request of the adapter (model, prompt and its options) plus the optional eai object. | |
opts | ...CallOption | no | Per call options (query, idempotency key, traceparent, headers). |
Returns: (json.RawMessage, error). Decoded JSON answer of the operation "Start a video generation". The error is a typed error of the SDK, nil on success.
Raises: error, the typed errors of the transport (Errors).
Class AgentsService
AgentsService groups the endpoints of: Agent registry and lifecycle (suspend, resume, kill).
AgentsService.Create
Create(ctx context.Context, body any, opts ...CallOption) (json.RawMessage, error)
Register an agent or a version. Applies an Agent manifest: creates the agent, or adds a version to an existing one and makes it current. The manifest is validated against the v1 contract (422 invalid_manifest); risk level unacceptable is refused (422 agent_risk_unacceptable); the same version with other content is refused (409 version_immutable). apply_status in the answer is created, version_added or unchanged. Needs tenant_admin, developer or application_owner; the caller becomes ReBAC owner. Audited as agent.apply.
Route: /v1/agents (POST).
| Name | Type | Default | Required | Description |
|---|---|---|---|---|
ctx | context.Context | yes | Context of the call: cancellation and deadline. | |
body | any | yes | Agent manifest (kind: Agent, metadata with name, version and owner, spec). | |
opts | ...CallOption | no | Per call options (query, idempotency key, traceparent, headers). |
Returns: (json.RawMessage, error). Decoded JSON answer of the operation "Register an agent or a version". The error is a typed error of the SDK, nil on success.
Raises: error, the typed errors of the transport (Errors).
AgentsService.Delete
Delete(ctx context.Context, id string, opts ...CallOption) error
Delete an agent. Deletes the agent and its versions. Needs the role tenant_admin and the ReBAC relation owner on the agent. Refused with 409 agent_has_active_runs while a run of the agent is still active (pending, running, waiting or suspended); 404 agent_not_found for an unknown agent. Audited as agent.delete.
Route: /v1/agents/{agent_id} (DELETE).
| Name | Type | Default | Required | Description |
|---|---|---|---|---|
ctx | context.Context | yes | Context of the call: cancellation and deadline. | |
id | string | yes | Identifier (UUID) or name of the agent. | |
opts | ...CallOption | no | Per call options (query, idempotency key, traceparent, headers). |
Returns: error. Error of the call (a typed error of the SDK), nil on success.
Raises: error, the typed errors of the transport (Errors).
AgentsService.Get
Get(ctx context.Context, id string, opts ...CallOption) (json.RawMessage, error)
Get an agent. Returns the agent, the manifest of its current version and runs, the number of its runs per state. Needs the ReBAC relation viewer on the agent. 404 agent_not_found.
Route: /v1/agents/{agent_id} (GET).
| Name | Type | Default | Required | Description |
|---|---|---|---|---|
ctx | context.Context | yes | Context of the call: cancellation and deadline. | |
id | string | yes | Identifier (UUID) or name of the agent. | |
opts | ...CallOption | no | Per call options (query, idempotency key, traceparent, headers). |
Returns: (json.RawMessage, error). Decoded JSON answer of the operation "Get an agent". The error is a typed error of the SDK, nil on success.
Raises: error, the typed errors of the transport (Errors).
AgentsService.Kill
Kill(ctx context.Context, id string, opts ...CallOption) (json.RawMessage, error)
Kill an agent. Kill switch: every active run of the agent is cancelled with the error killed and the agent status becomes killed for good (it can never be resumed). Needs tenant_admin or security_officer. 409 agent_killed if already killed. The answer lists affected_runs. Audited as agent.kill.
Route: /v1/agents/{agent_id}/kill (POST).
| Name | Type | Default | Required | Description |
|---|---|---|---|---|
ctx | context.Context | yes | Context of the call: cancellation and deadline. | |
id | string | yes | Identifier (UUID) or name of the agent. | |
opts | ...CallOption | no | Per call options (query, idempotency key, traceparent, headers). |
Returns: (json.RawMessage, error). Decoded JSON answer of the operation "Kill an agent". The error is a typed error of the SDK, nil on success.
Raises: error, the typed errors of the transport (Errors).
AgentsService.List
List(ctx context.Context, opts ...CallOption) (*Page, error)
List the agents. Agents of the tenant, in name order, paginated with cursor. Any tenant principal may call it.
Route: /v1/agents (GET).
| Name | Type | Default | Required | Description |
|---|---|---|---|---|
ctx | context.Context | yes | Context of the call: cancellation and deadline. | |
opts | ...CallOption | no | Per call options (query, idempotency key, traceparent, headers). |
Returns: (*Page, error). A Page: Page is one page of a cursor paginated collection {"items": [...], "next_cursor": "..."|null}. The error is a typed error of the SDK, nil on success.
Raises: error, the typed errors of the transport (Errors).
AgentsService.Resume
Resume(ctx context.Context, id string, opts ...CallOption) (json.RawMessage, error)
Request the resumption of an agent. Opens a promotion approval to bring a suspended agent back to active and answers 202 with approval_id and status: pending_approval; approvers are tenant_admin or security_officer. Once approved, the runs suspended by the agent suspension resume. Needs tenant_admin or security_officer. Refused with 409 agent_killed, or 409 kill_switch_active while a SOC containment holds the agent (lifted only through POST /v1/soc/recoveries).
Route: /v1/agents/{agent_id}/resume (POST).
| Name | Type | Default | Required | Description |
|---|---|---|---|---|
ctx | context.Context | yes | Context of the call: cancellation and deadline. | |
id | string | yes | Identifier (UUID) or name of the agent. | |
opts | ...CallOption | no | Per call options (query, idempotency key, traceparent, headers). |
Returns: (json.RawMessage, error). Decoded JSON answer of the operation "Request the resumption of an agent". The error is a typed error of the SDK, nil on success.
Raises: error, the typed errors of the transport (Errors).
AgentsService.Suspend
Suspend(ctx context.Context, id string, opts ...CallOption) (json.RawMessage, error)
Suspend an agent. Kill switch, reversible: the agent status becomes suspended, its active runs move to suspended and new runs are refused. Needs tenant_admin or security_officer. 409 agent_killed for a killed agent. The answer lists affected_runs. Audited as agent.suspend.
Route: /v1/agents/{agent_id}/suspend (POST).
| Name | Type | Default | Required | Description |
|---|---|---|---|---|
ctx | context.Context | yes | Context of the call: cancellation and deadline. | |
id | string | yes | Identifier (UUID) or name of the agent. | |
opts | ...CallOption | no | Per call options (query, idempotency key, traceparent, headers). |
Returns: (json.RawMessage, error). Decoded JSON answer of the operation "Suspend an agent". The error is a typed error of the SDK, nil on success.
Raises: error, the typed errors of the transport (Errors).
AgentsService.Update
Update(ctx context.Context, id string, body any, opts ...CallOption) (json.RawMessage, error)
Update an agent. Changes the registry fields of the agent (owner, risk level, description, labels) without creating a version. Needs tenant_admin, developer or application_owner and the ReBAC relation editor. Invalid values answer 400 invalid_request. Audited as agent.update with the changed field names.
Route: /v1/agents/{agent_id} (PATCH).
| Name | Type | Default | Required | Description |
|---|---|---|---|---|
ctx | context.Context | yes | Context of the call: cancellation and deadline. | |
id | string | yes | Identifier (UUID) or name of the agent. | |
body | any | yes | Fields to change; the omitted ones are kept. | |
opts | ...CallOption | no | Per call options (query, idempotency key, traceparent, headers). |
Returns: (json.RawMessage, error). Decoded JSON answer of the operation "Update an agent". The error is a typed error of the SDK, nil on success.
Raises: error, the typed errors of the transport (Errors).
AgentsService.Versions
Versions(ctx context.Context, id string, opts ...CallOption) (json.RawMessage, error)
List the versions of an agent. Every registered version of the agent, newest first, with its manifest, digest, author and current (true for the version in use). Needs the ReBAC relation viewer. One page only.
Route: /v1/agents/{agent_id}/versions (GET).
| Name | Type | Default | Required | Description |
|---|---|---|---|---|
ctx | context.Context | yes | Context of the call: cancellation and deadline. | |
id | string | yes | Identifier (UUID) or name of the agent. | |
opts | ...CallOption | no | Per call options (query, idempotency key, traceparent, headers). |
Returns: (json.RawMessage, error). Decoded JSON answer of the operation "List the versions of an agent". The error is a typed error of the SDK, nil on success.
Raises: error, the typed errors of the transport (Errors).
Class RunsService
RunsService groups the endpoints of: Runs (Execution Contract), steps, replay, events and subagents.
RunsService.AddStep
AddStep(ctx context.Context, id string, body any, opts ...CallOption) (json.RawMessage, error)
Report a step of a run. Records one step reported by the runtime and returns the decision of the Loop Controller: run_state, next_kind, retry, backoff_seconds, error, approval_id and the budgets. Needs tenant_admin, developer or agent. Steps: 1. The Kill Switch Registry and, for a sensitive step, the delegation chain, session and policy are checked. 2. A pending run moves to running; any other state than running answers 409 run_not_running. 3. Usage and cost are added to the budget consumption (cost in the run currency, else 400 invalid_request). 4. A step matching autonomy.human_approval_for without approval_id stays pending, an approval is opened and the run moves to waiting_approval; a step of kind approval with state pending opens an approval with quorum. 5. Budgets, max steps and retries decide the next state (failed or timed_out when exceeded).
Route: /v1/runs/{run_id}/steps (POST).
| Name | Type | Default | Required | Description |
|---|---|---|---|---|
ctx | context.Context | yes | Context of the call: cancellation and deadline. | |
id | string | yes | Identifier (UUID) of the run. | |
body | any | yes | The step: kind, state, usage, cost, error and run state hints. | |
opts | ...CallOption | no | Per call options (query, idempotency key, traceparent, headers). |
Returns: (json.RawMessage, error). Decoded JSON answer of the operation "Report a step of a run". The error is a typed error of the SDK, nil on success.
Raises: error, the typed errors of the transport (Errors).
RunsService.Cancel
Cancel(ctx context.Context, id string, opts ...CallOption) (json.RawMessage, error)
Cancel a run. Moves the run to cancelled with the error cancelled; its active sub-agent runs are cancelled too. Needs tenant_admin, developer, agent or security_officer. A run already terminal answers 409 invalid_transition. Audited as run.transition.
Route: /v1/runs/{run_id}/cancel (POST).
| Name | Type | Default | Required | Description |
|---|---|---|---|---|
ctx | context.Context | yes | Context of the call: cancellation and deadline. | |
id | string | yes | Identifier (UUID) of the run. | |
opts | ...CallOption | no | Per call options (query, idempotency key, traceparent, headers). |
Returns: (json.RawMessage, error). Decoded JSON answer of the operation "Cancel a run". The error is a typed error of the SDK, nil on success.
Raises: error, the typed errors of the transport (Errors).
RunsService.Events
Events(ctx context.Context, id string, opts ...CallOption) (*SSEStream, error)
Stream the events of a run. Server-Sent Events stream (text/event-stream) of the run events: run.created, run.state, step.recorded, checkpoint.created, subagent.spawned. Each message carries id, event and data (type, data, at). Steps: 1. The events already recorded after Last-Event-ID are sent. 2. Without follow the stream ends at once; with follow=true it polls every second. 3. The stream ends with an end event carrying the run state when the run is terminal, when timeout has elapsed or when the client disconnects. 404 run_not_found.
Route: /v1/runs/{run_id}/events (GET).
| Name | Type | Default | Required | Description |
|---|---|---|---|---|
ctx | context.Context | yes | Context of the call: cancellation and deadline. | |
id | string | yes | Identifier (UUID) of the run. | |
opts | ...CallOption | no | Per call options (query, idempotency key, traceparent, headers). |
Returns: (*SSEStream, error). A SSEStream: SSEStream reads Server-Sent Events; "data: [DONE]" ends the stream. Always Close it. The error is a typed error of the SDK, nil on success.
Raises: error, the typed errors of the transport (Errors).
RunsService.GetRaw
GetRaw(ctx context.Context, id string, opts ...CallOption) (json.RawMessage, error)
Get a run. Returns the Execution Contract v1 of the run: agent and version, task, state, steps, budget limits and consumption, errors, retry policy, resume information and trace. 404 run_not_found.
Route: /v1/runs/{run_id} (GET).
| Name | Type | Default | Required | Description |
|---|---|---|---|---|
ctx | context.Context | yes | Context of the call: cancellation and deadline. | |
id | string | yes | Identifier (UUID) of the run. | |
opts | ...CallOption | no | Per call options (query, idempotency key, traceparent, headers). |
Returns: (json.RawMessage, error). Decoded JSON answer of the operation "Get a run". The error is a typed error of the SDK, nil on success.
Raises: error, the typed errors of the transport (Errors).
RunsService.List
List(ctx context.Context, opts ...CallOption) (*Page, error)
List the runs. Runs of the tenant, newest first, paginated with cursor. Filters: agent_id (id or name; agent is an alias), state, session_id, parent_run_id. An unknown state or a malformed UUID answers 400 invalid_request.
Route: /v1/runs (GET).
| Name | Type | Default | Required | Description |
|---|---|---|---|---|
ctx | context.Context | yes | Context of the call: cancellation and deadline. | |
opts | ...CallOption | no | Per call options (query, idempotency key, traceparent, headers). |
Returns: (*Page, error). A Page: Page is one page of a cursor paginated collection {"items": [...], "next_cursor": "..."|null}. The error is a typed error of the SDK, nil on success.
Raises: error, the typed errors of the transport (Errors).
RunsService.Replay
Replay(ctx context.Context, id string, opts ...CallOption) (json.RawMessage, error)
Replay a run. Returns the full history of a run for review: its Execution Contract, steps, checkpoints, the audit events that name it and a single timeline sorted by time (run events and audit events). Needs tenant_admin, developer, agent, auditor or security_officer. Read only: nothing is re-executed.
Route: /v1/runs/{run_id}/replay (GET).
| Name | Type | Default | Required | Description |
|---|---|---|---|---|
ctx | context.Context | yes | Context of the call: cancellation and deadline. | |
id | string | yes | Identifier (UUID) of the run. | |
opts | ...CallOption | no | Per call options (query, idempotency key, traceparent, headers). |
Returns: (json.RawMessage, error). Decoded JSON answer of the operation "Replay a run". The error is a typed error of the SDK, nil on success.
Raises: error, the typed errors of the transport (Errors).
RunsService.Resume
Resume(ctx context.Context, id string, opts ...CallOption) (json.RawMessage, error)
Resume a run. Moves a suspended, failed, timed_out or waiting_input run back to running (else 409 invalid_transition). Needs tenant_admin, developer or agent; the agent must be active (409 agent_not_active). Strategies: 1. from_last_checkpoint (default, except for waiting_input): resume from checkpoint_id or the last checkpoint (409 no_checkpoint if none). 2. restart_step (default for waiting_input): replay the current step. 3. restart_run: start over with the budget consumption reset. A run that failed on budget_exceeded, max_steps_exceeded, killed or approval_rejected can only use restart_run (409 run_not_resumable). Returns the run and the checkpoint used.
Route: /v1/runs/{run_id}/resume (POST).
| Name | Type | Default | Required | Description |
|---|---|---|---|---|
ctx | context.Context | yes | Context of the call: cancellation and deadline. | |
id | string | yes | Identifier (UUID) of the run. | |
opts | ...CallOption | no | Per call options (query, idempotency key, traceparent, headers). |
Returns: (json.RawMessage, error). Decoded JSON answer of the operation "Resume a run". The error is a typed error of the SDK, nil on success.
Raises: error, the typed errors of the transport (Errors).
RunsService.SpawnSubagent
SpawnSubagent(ctx context.Context, id string, body any, opts ...CallOption) (json.RawMessage, error)
Spawn a sub-agent run. Starts a child run from a pending or running parent (else 409 run_not_running) and returns its Execution Contract. Needs tenant_admin, developer or agent and the scope agents:run. Checks, in order: the Kill Switch Registry; the depth against autonomy.max_depth (default 1, 409 subagent_depth_exceeded); the number of children against autonomy.max_subagents (default 3, 409 subagent_count_exceeded); the child agent against the subagents list of the parent manifest (403 subagent_not_allowed); the parent delegation. The child budget cannot exceed what the parent has left, the child joins the parent session, and a running parent records a subagent step.
Route: /v1/runs/{run_id}/subagents (POST).
| Name | Type | Default | Required | Description |
|---|---|---|---|---|
ctx | context.Context | yes | Context of the call: cancellation and deadline. | |
id | string | yes | Identifier (UUID) of the parent run. | |
body | any | yes | Child agent, task and budget. | |
opts | ...CallOption | no | Per call options (query, idempotency key, traceparent, headers). |
Returns: (json.RawMessage, error). Decoded JSON answer of the operation "Spawn a sub-agent run". The error is a typed error of the SDK, nil on success.
Raises: error, the typed errors of the transport (Errors).
RunsService.Start
Start(ctx context.Context, agentID string, body any, opts ...CallOption) (json.RawMessage, error)
Start a run of an agent. Creates a run and returns its Execution Contract (201). Needs tenant_admin, developer or agent, the scope agents:run and the ReBAC relation can_invoke. Steps: 1. The agent must be active (else 409 agent_not_active, audited as a denial). 2. The policy agent.run is evaluated with the agent risk, owner, purpose and the data_classification of the task (403 policy_denied). 3. The budget is the manifest budget, tightened by budgets (a request can never loosen it; 422 invalid_budget). 4. The delegation and workload identity are attached, the run is created in pending (or running with start=true) and audited as run.create. A repeated Idempotency-Key returns the first run; the same key for another agent answers 409 idempotency_conflict. An unknown session_id answers 404 session_not_found.
Route: /v1/agents/{agent_id}/runs (POST).
| Name | Type | Default | Required | Description |
|---|---|---|---|---|
ctx | context.Context | yes | Context of the call: cancellation and deadline. | |
agentID | string | yes | Identifier (UUID) or name of the agent. | |
body | any | yes | Task of the run, optional session, budget, retry policy and delegation. | |
opts | ...CallOption | no | Per call options (query, idempotency key, traceparent, headers). |
Returns: (json.RawMessage, error). Decoded JSON answer of the operation "Start a run of an agent". The error is a typed error of the SDK, nil on success.
Raises: error, the typed errors of the transport (Errors).
RunsService.Steps
Steps(ctx context.Context, id string, opts ...CallOption) (json.RawMessage, error)
List the steps of a run. Steps of the run in order, each with seq, kind, state, attempt, tokens, cost and error when present. One page only. 404 run_not_found.
Route: /v1/runs/{run_id}/steps (GET).
| Name | Type | Default | Required | Description |
|---|---|---|---|---|
ctx | context.Context | yes | Context of the call: cancellation and deadline. | |
id | string | yes | Identifier (UUID) of the run. | |
opts | ...CallOption | no | Per call options (query, idempotency key, traceparent, headers). |
Returns: (json.RawMessage, error). Decoded JSON answer of the operation "List the steps of a run". The error is a typed error of the SDK, nil on success.
Raises: error, the typed errors of the transport (Errors).
RunsService.Subagents
Subagents(ctx context.Context, id string, opts ...CallOption) (json.RawMessage, error)
List the sub-agent runs. Summaries of the child runs started by this run, oldest first. One page only. 404 run_not_found.
Route: /v1/runs/{run_id}/subagents (GET).
| Name | Type | Default | Required | Description |
|---|---|---|---|---|
ctx | context.Context | yes | Context of the call: cancellation and deadline. | |
id | string | yes | Identifier (UUID) of the parent run. | |
opts | ...CallOption | no | Per call options (query, idempotency key, traceparent, headers). |
Returns: (json.RawMessage, error). Decoded JSON answer of the operation "List the sub-agent runs". The error is a typed error of the SDK, nil on success.
Raises: error, the typed errors of the transport (Errors).
Class CheckpointsService
CheckpointsService groups the endpoints of: Run checkpoints.
CheckpointsService.Create
Create(ctx context.Context, runID string, body any, opts ...CallOption) (json.RawMessage, error)
Save a checkpoint. Saves a state of the run with the next sequence number and the current step sequence, so the run can later resume from it. Needs tenant_admin, developer or agent. Refused with 409 run_finished on a run succeeded or cancelled. Emits checkpoint.created; audited as run.checkpoint.
Route: /v1/runs/{run_id}/checkpoints (POST).
| Name | Type | Default | Required | Description |
|---|---|---|---|---|
ctx | context.Context | yes | Context of the call: cancellation and deadline. | |
runID | string | yes | Identifier (UUID) of the run. | |
body | any | yes | State to save and optional label. | |
opts | ...CallOption | no | Per call options (query, idempotency key, traceparent, headers). |
Returns: (json.RawMessage, error). Decoded JSON answer of the operation "Save a checkpoint". The error is a typed error of the SDK, nil on success.
Raises: error, the typed errors of the transport (Errors).
CheckpointsService.Get
Get(ctx context.Context, id string, opts ...CallOption) (json.RawMessage, error)
Get a checkpoint. Returns one checkpoint: run, sequence number, step sequence at save time, label and saved state. 404 checkpoint_not_found.
Route: /v1/checkpoints/{checkpoint_id} (GET).
| Name | Type | Default | Required | Description |
|---|---|---|---|---|
ctx | context.Context | yes | Context of the call: cancellation and deadline. | |
id | string | yes | Identifier (UUID) of the checkpoint. | |
opts | ...CallOption | no | Per call options (query, idempotency key, traceparent, headers). |
Returns: (json.RawMessage, error). Decoded JSON answer of the operation "Get a checkpoint". The error is a typed error of the SDK, nil on success.
Raises: error, the typed errors of the transport (Errors).
CheckpointsService.List
List(ctx context.Context, runID string, opts ...CallOption) (json.RawMessage, error)
List the checkpoints of a run. Checkpoints of the run in sequence order. One page only. 404 run_not_found.
Route: /v1/runs/{run_id}/checkpoints (GET).
| Name | Type | Default | Required | Description |
|---|---|---|---|---|
ctx | context.Context | yes | Context of the call: cancellation and deadline. | |
runID | string | yes | Identifier (UUID) of the run. | |
opts | ...CallOption | no | Per call options (query, idempotency key, traceparent, headers). |
Returns: (json.RawMessage, error). Decoded JSON answer of the operation "List the checkpoints of a run". The error is a typed error of the SDK, nil on success.
Raises: error, the typed errors of the transport (Errors).
Class HeartbeatsService
HeartbeatsService groups the endpoints of: Run heartbeats and stale run detection.
HeartbeatsService.Beat
Beat(ctx context.Context, runID string, body any, opts ...CallOption) (json.RawMessage, error)
Send a run heartbeat. Records that the runtime is alive and tells it whether to go on: action is continue, or stop with a reason (run_cancelled, run_terminal, run_suspended, agent_killed, agent_suspended). The answer also gives stale_after_seconds. A terminal run is not updated. Needs tenant_admin, developer or agent. Audited only for the first heartbeat of a run and when the runtime is told to stop.
Route: /v1/runs/{run_id}/heartbeat (POST).
| Name | Type | Default | Required | Description |
|---|---|---|---|---|
ctx | context.Context | yes | Context of the call: cancellation and deadline. | |
runID | string | yes | Identifier (UUID) of the run. | |
body | any | yes | Optional progress information. | |
opts | ...CallOption | no | Per call options (query, idempotency key, traceparent, headers). |
Returns: (json.RawMessage, error). Decoded JSON answer of the operation "Send a run heartbeat". The error is a typed error of the SDK, nil on success.
Raises: error, the typed errors of the transport (Errors).
HeartbeatsService.Stale
Stale(ctx context.Context, opts ...CallOption) (json.RawMessage, error)
List run heartbeats. Liveness of the runs expected to send heartbeats (running and waiting_input). By default only the stale ones (no heartbeat within the threshold) are returned, with active, stale_count and stale_after_seconds. With format=prometheus the answer is Prometheus exposition text (eai_runs_total, eai_runs_active, eai_runs_stale, eai_heartbeat_stale_threshold_seconds).
Route: /v1/heartbeats (GET).
| Name | Type | Default | Required | Description |
|---|---|---|---|---|
ctx | context.Context | yes | Context of the call: cancellation and deadline. | |
opts | ...CallOption | no | Per call options (query, idempotency key, traceparent, headers). |
Returns: (json.RawMessage, error). Decoded JSON answer of the operation "List run heartbeats". The error is a typed error of the SDK, nil on success.
Raises: error, the typed errors of the transport (Errors).
Class A2AService
A2AService groups the endpoints of: Agent to agent messaging.
A2AService.Inbox
Inbox(ctx context.Context, recipient string, opts ...CallOption) (*Page, error)
Read an A2A inbox. Returns the A2A messages addressed to recipient, oldest first, each with verified (the HMAC-SHA256 signature of the envelope matches the tenant key). Reading marks the returned messages as read. One page only (next_cursor is always null).
Route: /v1/a2a/inbox (GET).
| Name | Type | Default | Required | Description |
|---|---|---|---|---|
ctx | context.Context | yes | Context of the call: cancellation and deadline. | |
recipient | string | yes | Party whose inbox is read: agent:<name> or run:<id> (at least 3 characters). | |
opts | ...CallOption | no | Per call options (query, idempotency key, traceparent, headers). |
Returns: (*Page, error). A Page: Page is one page of a cursor paginated collection {"items": [...], "next_cursor": "..."|null}. The error is a typed error of the SDK, nil on success.
Raises: error, the typed errors of the transport (Errors).
A2AService.Send
Send(ctx context.Context, body any, opts ...CallOption) (json.RawMessage, error)
Send an A2A message. Sends a signed agent to agent message (envelope a2a.v1, HMAC-SHA256 signature per tenant). Needs tenant_admin, developer or agent. Steps: 1. to and from are resolved: agent:<name> or run:<id> (400 invalid_request otherwise). Without from, the sender is the calling principal. 2. A run: sender must be a run created by the caller (or the caller is tenant_admin, else 403 forbidden) and not finished (409 run_finished). 3. The policy agent.a2a.send is evaluated and the payload is screened as untrusted content; a prompt injection is refused with prompt_injection_blocked after the security event is recorded. 4. The envelope is stored in the recipient inbox and audited as a2a.send.
Route: /v1/a2a/messages (POST).
| Name | Type | Default | Required | Description |
|---|---|---|---|---|
ctx | context.Context | yes | Context of the call: cancellation and deadline. | |
body | any | yes | Recipient, message type, payload and optional conversation threading. | |
opts | ...CallOption | no | Per call options (query, idempotency key, traceparent, headers). |
Returns: (json.RawMessage, error). Decoded JSON answer of the operation "Send an A2A message". The error is a typed error of the SDK, nil on success.
Raises: error, the typed errors of the transport (Errors).
Class SessionsService
SessionsService groups the endpoints of: Conversation sessions and messages.
SessionsService.Create
Create(ctx context.Context, body any, opts ...CallOption) (json.RawMessage, error)
Open a session. Opens a conversation session, owned by user_id or by the caller. Opening a session for another user needs tenant_admin or agent (403 forbidden). Needs tenant_admin, developer or agent. 404 agent_not_found for an unknown agent_id. Audited as session.create.
Route: /v1/sessions (POST).
| Name | Type | Default | Required | Description |
|---|---|---|---|---|
ctx | context.Context | yes | Context of the call: cancellation and deadline. | |
body | any | yes | Agent, owner, channel, title, metadata and lifetime of the session. | |
opts | ...CallOption | no | Per call options (query, idempotency key, traceparent, headers). |
Returns: (json.RawMessage, error). Decoded JSON answer of the operation "Open a session". The error is a typed error of the SDK, nil on success.
Raises: error, the typed errors of the transport (Errors).
SessionsService.Delete
Delete(ctx context.Context, id string, opts ...CallOption) error
Delete a session. Deletes the session and its messages. Needs tenant_admin, developer or agent, and the caller must see the session (its owner, or tenant_admin, auditor, security_officer, agent); otherwise 404 session_not_found. Audited as session.delete.
Route: /v1/sessions/{session_id} (DELETE).
| Name | Type | Default | Required | Description |
|---|---|---|---|---|
ctx | context.Context | yes | Context of the call: cancellation and deadline. | |
id | string | yes | Identifier (UUID) of the session. | |
opts | ...CallOption | no | Per call options (query, idempotency key, traceparent, headers). |
Returns: error. Error of the call (a typed error of the SDK), nil on success.
Raises: error, the typed errors of the transport (Errors).
SessionsService.Get
Get(ctx context.Context, id string, opts ...CallOption) (json.RawMessage, error)
Get a session. Returns one session. Visible to its owner, to tenant_admin, auditor, security_officer and to the agent role; otherwise 404 session_not_found.
Route: /v1/sessions/{session_id} (GET).
| Name | Type | Default | Required | Description |
|---|---|---|---|---|
ctx | context.Context | yes | Context of the call: cancellation and deadline. | |
id | string | yes | Identifier (UUID) of the session. | |
opts | ...CallOption | no | Per call options (query, idempotency key, traceparent, headers). |
Returns: (json.RawMessage, error). Decoded JSON answer of the operation "Get a session". The error is a typed error of the SDK, nil on success.
Raises: error, the typed errors of the transport (Errors).
SessionsService.List
List(ctx context.Context, opts ...CallOption) (*Page, error)
List the sessions. Sessions, newest first, paginated with cursor. A caller sees its own sessions; tenant_admin, auditor and security_officer see every session of the tenant.
Route: /v1/sessions (GET).
| Name | Type | Default | Required | Description |
|---|---|---|---|---|
ctx | context.Context | yes | Context of the call: cancellation and deadline. | |
opts | ...CallOption | no | Per call options (query, idempotency key, traceparent, headers). |
Returns: (*Page, error). A Page: Page is one page of a cursor paginated collection {"items": [...], "next_cursor": "..."|null}. The error is a typed error of the SDK, nil on success.
Raises: error, the typed errors of the transport (Errors).
SessionsService.Messages
Messages(ctx context.Context, id string, opts ...CallOption) (*Page, error)
List the messages of a session. Messages in order, paginated with cursor. after (message id or timestamp) lets a runtime poll the new messages only; an unknown message id or a malformed timestamp answers 400 invalid_request.
Route: /v1/sessions/{session_id}/messages (GET).
| Name | Type | Default | Required | Description |
|---|---|---|---|---|
ctx | context.Context | yes | Context of the call: cancellation and deadline. | |
id | string | yes | Identifier (UUID) of the session. | |
opts | ...CallOption | no | Per call options (query, idempotency key, traceparent, headers). |
Returns: (*Page, error). A Page: Page is one page of a cursor paginated collection {"items": [...], "next_cursor": "..."|null}. The error is a typed error of the SDK, nil on success.
Raises: error, the typed errors of the transport (Errors).
SessionsService.PostMessage
PostMessage(ctx context.Context, id string, body any, opts ...CallOption) (json.RawMessage, error)
Add a message to a session. Appends a message with the next sequence number. The session must be open and not expired (409 session_closed). Needs tenant_admin, developer or agent. The audit event session.message.add keeps the role and the length only, never the content.
Route: /v1/sessions/{session_id}/messages (POST).
| Name | Type | Default | Required | Description |
|---|---|---|---|---|
ctx | context.Context | yes | Context of the call: cancellation and deadline. | |
id | string | yes | Identifier (UUID) of the session. | |
body | any | yes | Role, content and metadata of the message. | |
opts | ...CallOption | no | Per call options (query, idempotency key, traceparent, headers). |
Returns: (json.RawMessage, error). Decoded JSON answer of the operation "Add a message to a session". The error is a typed error of the SDK, nil on success.
Raises: error, the typed errors of the transport (Errors).
Class SchedulesService
SchedulesService groups the endpoints of: Cron schedules (Temporal backed).
SchedulesService.Create
Create(ctx context.Context, body any, opts ...CallOption) (json.RawMessage, error)
Create a schedule. Schedules runs of an agent from a cron expression evaluated in a time zone; the first next_run_at is computed (422 invalid_cron). When Temporal is configured the schedule is created there (503 scheduler_unavailable on failure). Needs tenant_admin, developer or application_owner. 404 agent_not_found. Audited as schedule.create.
Route: /v1/schedules (POST).
| Name | Type | Default | Required | Description |
|---|---|---|---|---|
ctx | context.Context | yes | Context of the call: cancellation and deadline. | |
body | any | yes | Agent, cron expression, time zone, run input and enabled flag. | |
opts | ...CallOption | no | Per call options (query, idempotency key, traceparent, headers). |
Returns: (json.RawMessage, error). Decoded JSON answer of the operation "Create a schedule". The error is a typed error of the SDK, nil on success.
Raises: error, the typed errors of the transport (Errors).
SchedulesService.Delete
Delete(ctx context.Context, id string, opts ...CallOption) error
Delete a schedule. Deletes the schedule; no new run is started by it. Needs tenant_admin, developer or application_owner. When the schedule is held by Temporal, it is deleted there too (503 scheduler_unavailable if Temporal cannot be reached). 404 schedule_not_found. Audited as schedule.delete.
Route: /v1/schedules/{schedule_id} (DELETE).
| Name | Type | Default | Required | Description |
|---|---|---|---|---|
ctx | context.Context | yes | Context of the call: cancellation and deadline. | |
id | string | yes | Identifier (UUID) of the schedule. | |
opts | ...CallOption | no | Per call options (query, idempotency key, traceparent, headers). |
Returns: error. Error of the call (a typed error of the SDK), nil on success.
Raises: error, the typed errors of the transport (Errors).
SchedulesService.List
List(ctx context.Context, opts ...CallOption) (*Page, error)
List the schedules. Cron schedules of the tenant, oldest first, optionally for one agent. One page only.
Route: /v1/schedules (GET).
| Name | Type | Default | Required | Description |
|---|---|---|---|---|
ctx | context.Context | yes | Context of the call: cancellation and deadline. | |
opts | ...CallOption | no | Per call options (query, idempotency key, traceparent, headers). |
Returns: (*Page, error). A Page: Page is one page of a cursor paginated collection {"items": [...], "next_cursor": "..."|null}. The error is a typed error of the SDK, nil on success.
Raises: error, the typed errors of the transport (Errors).
SchedulesService.Update
Update(ctx context.Context, id string, body any, opts ...CallOption) (json.RawMessage, error)
Update a schedule. Changes the cron expression, time zone, input or enabled flag. The next run time is computed again (422 invalid_cron for a bad expression or time zone) and the Temporal schedule is updated when Temporal holds it (503 scheduler_unavailable). Needs tenant_admin, developer or application_owner. Audited as schedule.update.
Route: /v1/schedules/{schedule_id} (PATCH).
| Name | Type | Default | Required | Description |
|---|---|---|---|---|
ctx | context.Context | yes | Context of the call: cancellation and deadline. | |
id | string | yes | Identifier (UUID) of the schedule. | |
body | any | yes | Fields to change; the omitted ones are kept. | |
opts | ...CallOption | no | Per call options (query, idempotency key, traceparent, headers). |
Returns: (json.RawMessage, error). Decoded JSON answer of the operation "Update a schedule". The error is a typed error of the SDK, nil on success.
Raises: error, the typed errors of the transport (Errors).
Class TriggersService
TriggersService groups the endpoints of: Event triggers.
TriggersService.Create
Create(ctx context.Context, body any, opts ...CallOption) (json.RawMessage, error)
Create a trigger. Starts a run of the agent for every published event whose subject matches (NATS wildcards * and > allowed) and whose payload passes the filter. Needs tenant_admin, developer or application_owner. 422 invalid_subject or invalid_filter; 404 agent_not_found. Audited as trigger.create.
Route: /v1/triggers (POST).
| Name | Type | Default | Required | Description |
|---|---|---|---|---|
ctx | context.Context | yes | Context of the call: cancellation and deadline. | |
body | any | yes | Agent, subject and optional payload filter. | |
opts | ...CallOption | no | Per call options (query, idempotency key, traceparent, headers). |
Returns: (json.RawMessage, error). Decoded JSON answer of the operation "Create a trigger". The error is a typed error of the SDK, nil on success.
Raises: error, the typed errors of the transport (Errors).
TriggersService.Delete
Delete(ctx context.Context, id string, opts ...CallOption) error
Delete a trigger. Deletes the event trigger; matching events no longer start runs. Needs tenant_admin, developer or application_owner. 404 trigger_not_found. Audited as trigger.delete.
Route: /v1/triggers/{trigger_id} (DELETE).
| Name | Type | Default | Required | Description |
|---|---|---|---|---|
ctx | context.Context | yes | Context of the call: cancellation and deadline. | |
id | string | yes | Identifier (UUID) of the trigger. | |
opts | ...CallOption | no | Per call options (query, idempotency key, traceparent, headers). |
Returns: error. Error of the call (a typed error of the SDK), nil on success.
Raises: error, the typed errors of the transport (Errors).
TriggersService.List
List(ctx context.Context, opts ...CallOption) (*Page, error)
List the triggers. Event triggers of the tenant, oldest first: agent, subject and filter. One page only.
Route: /v1/triggers (GET).
| Name | Type | Default | Required | Description |
|---|---|---|---|---|
ctx | context.Context | yes | Context of the call: cancellation and deadline. | |
opts | ...CallOption | no | Per call options (query, idempotency key, traceparent, headers). |
Returns: (*Page, error). A Page: Page is one page of a cursor paginated collection {"items": [...], "next_cursor": "..."|null}. The error is a typed error of the SDK, nil on success.
Raises: error, the typed errors of the transport (Errors).
Class EventsService
EventsService groups the endpoints of: Event publishing (NATS).
EventsService.Publish
Publish(ctx context.Context, body any, opts ...CallOption) (json.RawMessage, error)
Publish an event. Publishes an event (202): on NATS JetStream when configured, else in the platform outbox. The current W3C trace context is added to the headers. Every trigger whose subject and filter match starts a run of its agent (idempotent per event and trigger); the answer lists them in triggered, with skipped and an error code when a run could not start. Needs tenant_admin, developer or agent. 422 invalid_subject. Audited as event.publish.
Route: /v1/events/publish (POST).
| Name | Type | Default | Required | Description |
|---|---|---|---|---|
ctx | context.Context | yes | Context of the call: cancellation and deadline. | |
body | any | yes | Subject, payload and headers of the event. | |
opts | ...CallOption | no | Per call options (query, idempotency key, traceparent, headers). |
Returns: (json.RawMessage, error). Decoded JSON answer of the operation "Publish an event". The error is a typed error of the SDK, nil on success.
Raises: error, the typed errors of the transport (Errors).
Class SandboxService
SandboxService groups the endpoints of: Sandboxed executions (gVisor, Kata).
SandboxService.Execute
Execute(ctx context.Context, body any, opts ...CallOption) (json.RawMessage, error)
Run a command in a sandbox. Creates a sandbox execution: the image and command run as a Kubernetes Job with the runtime class of the profile (gVisor, Kata, Wasm) when Kubernetes is configured (status: submitted, or failed if the submission fails). Needs tenant_admin, developer or agent; the profile none needs tenant_admin (403). Invalid profile, image or limits answer 422 invalid_sandbox. The usage is metered and the request audited as sandbox.execute.
Route: /v1/sandbox/executions (POST).
| Name | Type | Default | Required | Description |
|---|---|---|---|---|
ctx | context.Context | yes | Context of the call: cancellation and deadline. | |
body | any | yes | Profile, image, command, environment and resource limits. | |
opts | ...CallOption | no | Per call options (query, idempotency key, traceparent, headers). |
Returns: (json.RawMessage, error). Decoded JSON answer of the operation "Run a command in a sandbox". The error is a typed error of the SDK, nil on success.
Raises: error, the typed errors of the transport (Errors).
SandboxService.Get
Get(ctx context.Context, id string, opts ...CallOption) (json.RawMessage, error)
Get a sandbox execution. Returns the sandbox execution: profile, image, command, limits, generated Kubernetes Job spec, status, executor and result. 404 sandbox_execution_not_found.
Route: /v1/sandbox/executions/{execution_id} (GET).
| Name | Type | Default | Required | Description |
|---|---|---|---|---|
ctx | context.Context | yes | Context of the call: cancellation and deadline. | |
id | string | yes | Identifier (UUID) of the sandbox execution. | |
opts | ...CallOption | no | Per call options (query, idempotency key, traceparent, headers). |
Returns: (json.RawMessage, error). Decoded JSON answer of the operation "Get a sandbox execution". The error is a typed error of the SDK, nil on success.
Raises: error, the typed errors of the transport (Errors).
Class ToolsService
ToolsService groups the endpoints of: Tool registry and Tool Gateway invocations.
ToolsService.Create
Create(ctx context.Context, body any, opts ...CallOption) (json.RawMessage, error)
Register a tool. Applies a Tool manifest: creates or updates the tool (apply_status: created, updated or unchanged). Checked: valid JSON Schemas for input and output, an http endpoint needs an http(s) URL allowed by the egress policy, an mcp endpoint needs mcp_server, a builtin handler must be echo or time.now, risk level unacceptable is refused (422 invalid_manifest). Needs tenant_admin, developer or application_owner; the caller becomes ReBAC owner. Audited as tool.apply.
Route: /v1/tools (POST).
| Name | Type | Default | Required | Description |
|---|---|---|---|---|
ctx | context.Context | yes | Context of the call: cancellation and deadline. | |
body | any | yes | Tool manifest (kind: Tool, metadata, spec with description, action, input schema, endpoint, data classification and options). | |
opts | ...CallOption | no | Per call options (query, idempotency key, traceparent, headers). |
Returns: (json.RawMessage, error). Decoded JSON answer of the operation "Register a tool". The error is a typed error of the SDK, nil on success.
Raises: error, the typed errors of the transport (Errors).
ToolsService.Delete
Delete(ctx context.Context, name string, opts ...CallOption) error
Delete a tool. Removes the tool from the registry. Needs tenant_admin and the ReBAC relation owner. 404 tool_not_found. Audited as tool.delete.
Route: /v1/tools/{name} (DELETE).
| Name | Type | Default | Required | Description |
|---|---|---|---|---|
ctx | context.Context | yes | Context of the call: cancellation and deadline. | |
name | string | yes | Name of the tool. | |
opts | ...CallOption | no | Per call options (query, idempotency key, traceparent, headers). |
Returns: error. Error of the call (a typed error of the SDK), nil on success.
Raises: error, the typed errors of the transport (Errors).
ToolsService.Get
Get(ctx context.Context, name string, opts ...CallOption) (json.RawMessage, error)
Get a tool. Returns the tool with its manifest, risk level, owner and status. Needs the ReBAC relation viewer. 404 tool_not_found.
Route: /v1/tools/{name} (GET).
| Name | Type | Default | Required | Description |
|---|---|---|---|---|
ctx | context.Context | yes | Context of the call: cancellation and deadline. | |
name | string | yes | Name of the tool. | |
opts | ...CallOption | no | Per call options (query, idempotency key, traceparent, headers). |
Returns: (json.RawMessage, error). Decoded JSON answer of the operation "Get a tool". The error is a typed error of the SDK, nil on success.
Raises: error, the typed errors of the transport (Errors).
ToolsService.Invocations
Invocations(ctx context.Context, opts ...CallOption) (*Page, error)
List the tool invocations. Invocations recorded by the Tool Gateway, newest first, paginated with cursor: tool and version, actor, run, agent, status, decision, approval, redacted arguments and result, DLP findings, HTTP status, error and duration. Arguments and results are stored redacted only.
Route: /v1/tools/invocations (GET).
| Name | Type | Default | Required | Description |
|---|---|---|---|---|
ctx | context.Context | yes | Context of the call: cancellation and deadline. | |
opts | ...CallOption | no | Per call options (query, idempotency key, traceparent, headers). |
Returns: (*Page, error). A Page: Page is one page of a cursor paginated collection {"items": [...], "next_cursor": "..."|null}. The error is a typed error of the SDK, nil on success.
Raises: error, the typed errors of the transport (Errors).
ToolsService.Invoke
Invoke(ctx context.Context, name string, body any, opts ...CallOption) (json.RawMessage, error)
Invoke a tool through the gateway. Runs the gateway pipeline described in the tag introduction and returns the invocation: status, masked result, error, duration_ms, decision_id, DLP findings, usage event and cost. Needs tenant_admin, developer or agent and the ReBAC relation can_invoke. Answers: 200 when executed (also when the upstream failed, see status and error); 202 pending_approval with approval_id when a human approval is needed (call again with the approved approval_id and the same arguments); 202 for a sandbox tool, with the sandbox execution id. Errors: 403 tool_blocked, insufficient_scope, tool_not_granted, classification_exceeded, policy_denied, dlp_blocked; 422 invalid_arguments; 409 approval_consumed (an approval serves one successful call); 429 rate_limited with Retry-After: 60 or quota_exceeded.
Route: /v1/tools/{name}/invoke (POST).
| Name | Type | Default | Required | Description |
|---|---|---|---|---|
ctx | context.Context | yes | Context of the call: cancellation and deadline. | |
name | string | yes | Name of the tool. | |
body | any | yes | Arguments of the call and its context (run, agent, approval, purpose, classification). | |
opts | ...CallOption | no | Per call options (query, idempotency key, traceparent, headers). |
Returns: (json.RawMessage, error). Decoded JSON answer of the operation "Invoke a tool through the gateway". The error is a typed error of the SDK, nil on success.
Raises: error, the typed errors of the transport (Errors).
ToolsService.List
List(ctx context.Context, opts ...CallOption) (*Page, error)
List the tools. Tools of the tenant in name order, optionally with one status. One page only.
Route: /v1/tools (GET).
| Name | Type | Default | Required | Description |
|---|---|---|---|---|
ctx | context.Context | yes | Context of the call: cancellation and deadline. | |
opts | ...CallOption | no | Per call options (query, idempotency key, traceparent, headers). |
Returns: (*Page, error). A Page: Page is one page of a cursor paginated collection {"items": [...], "next_cursor": "..."|null}. The error is a typed error of the SDK, nil on success.
Raises: error, the typed errors of the transport (Errors).
ToolsService.Update
Update(ctx context.Context, name string, body any, opts ...CallOption) (json.RawMessage, error)
Update a tool. Changes the owner, the description or the status. A status change needs tenant_admin or security_officer, other fields tenant_admin, developer or application_owner; the ReBAC relation editor is checked. approved goes through a promotion (202 with approval_id); other statuses apply at once (200). Audited as tool.update.
Route: /v1/tools/{name} (PATCH).
| Name | Type | Default | Required | Description |
|---|---|---|---|---|
ctx | context.Context | yes | Context of the call: cancellation and deadline. | |
name | string | yes | Name of the tool. | |
body | any | yes | Fields to change; the omitted ones are kept. | |
opts | ...CallOption | no | Per call options (query, idempotency key, traceparent, headers). |
Returns: (json.RawMessage, error). Decoded JSON answer of the operation "Update a tool". The error is a typed error of the SDK, nil on success.
Raises: error, the typed errors of the transport (Errors).
Class MCPService
MCPService groups the endpoints of: MCP servers and JSON-RPC 2.0 gateway.
MCPService.CreateServer
CreateServer(ctx context.Context, body any, opts ...CallOption) (json.RawMessage, error)
Register an MCP server. Registers an upstream server (201). The URL must be http(s) on an internal host allowed by the MCP egress policy (403 mcp_online_forbidden otherwise); bearer, api_key and query_param need an openbao:// or env:// credential_ref, query_param needs param, connector needs connector (400 invalid_request). A name already used answers 409 conflict. The project (default X-Project) must be the request project (403 mcp_project_forbidden). Needs tenant_admin, developer or application_owner; the caller becomes ReBAC owner. Audited as mcp.server.create.
Route: /v1/mcp/servers (POST).
| Name | Type | Default | Required | Description |
|---|---|---|---|---|
ctx | context.Context | yes | Context of the call: cancellation and deadline. | |
body | any | yes | Name, URL, transport, upstream authentication, allow lists, owner and project. | |
opts | ...CallOption | no | Per call options (query, idempotency key, traceparent, headers). |
Returns: (json.RawMessage, error). Decoded JSON answer of the operation "Register an MCP server". The error is a typed error of the SDK, nil on success.
Raises: error, the typed errors of the transport (Errors).
MCPService.DeleteServer
DeleteServer(ctx context.Context, id string, opts ...CallOption) error
Delete an MCP server. Removes the server from the registry. Needs tenant_admin, the ReBAC relation owner and access to the project of the server. 404 mcp_server_not_found. Audited as mcp.server.delete.
Route: /v1/mcp/servers/{server_id} (DELETE).
| Name | Type | Default | Required | Description |
|---|---|---|---|---|
ctx | context.Context | yes | Context of the call: cancellation and deadline. | |
id | string | yes | Identifier (UUID) or name of the MCP server. | |
opts | ...CallOption | no | Per call options (query, idempotency key, traceparent, headers). |
Returns: error. Error of the call (a typed error of the SDK), nil on success.
Raises: error, the typed errors of the transport (Errors).
MCPService.ListServers
ListServers(ctx context.Context, opts ...CallOption) (*Page, error)
List the MCP servers. Servers the request may see: project (id or slug) keeps the servers of that project; a request made in a project (X-Project header or an API key bound to a project) sees the servers of its project and those shared by the tenant, never those of another project (403 mcp_project_forbidden). Upstream secrets are never returned, only their references.
Route: /v1/mcp/servers (GET).
| Name | Type | Default | Required | Description |
|---|---|---|---|---|
ctx | context.Context | yes | Context of the call: cancellation and deadline. | |
opts | ...CallOption | no | Per call options (query, idempotency key, traceparent, headers). |
Returns: (*Page, error). A Page: Page is one page of a cursor paginated collection {"items": [...], "next_cursor": "..."|null}. The error is a typed error of the SDK, nil on success.
Raises: error, the typed errors of the transport (Errors).
MCPService.Rpc
Rpc(ctx context.Context, serverID string, body any, opts ...CallOption) (json.RawMessage, error)
Call an MCP server through the gateway. JSON-RPC 2.0 proxy. The body is one request or a batch (at most 50 are handled). Needs tenant_admin, developer or agent and the ReBAC relation can_invoke. Refusals are answered as JSON-RPC errors with HTTP 200, and audited. Checks, in order: valid JSON-RPC 2.0; server active; project isolation (mcp_server_project_mismatch); allowed callers (mcp_principal_not_allowed); a sleeping hosted instance is woken up; a third party application must be active and granted the server; method allowed; for tools/call: tool in allowed_tools, scope tools:invoke, DLP on the arguments; policy mcp.call; quota reservation; for resources/read: URI in allowed_resources. Then the call is forwarded with the upstream credentials; tools/list and resources/list are filtered by the allow lists, tools/call results are masked by DLP and screened for prompt injection, and the call is metered as a tool usage.
Route: /v1/mcp/gateway/{server_id} (POST).
| Name | Type | Default | Required | Description |
|---|---|---|---|---|
ctx | context.Context | yes | Context of the call: cancellation and deadline. | |
serverID | string | yes | Identifier (UUID) or name of the MCP server. | |
body | any | yes | A JSON-RPC 2.0 request (jsonrpc, id, method, params) or an array of requests. | |
opts | ...CallOption | no | Per call options (query, idempotency key, traceparent, headers). |
Returns: (json.RawMessage, error). Decoded JSON answer of the operation "Call an MCP server through the gateway". The error is a typed error of the SDK, nil on success.
Raises: error, the typed errors of the transport (Errors).
MCPService.ServerTools
ServerTools(ctx context.Context, id string, opts ...CallOption) (json.RawMessage, error)
List the tools of an MCP server. Calls tools/list on the server through the gateway and returns the tools allowed by allowed_tools. Needs the ReBAC relation can_invoke and access to the project of the server. An upstream error answers 502 upstream_error.
Route: /v1/mcp/servers/{server_id}/tools (GET).
| Name | Type | Default | Required | Description |
|---|---|---|---|---|
ctx | context.Context | yes | Context of the call: cancellation and deadline. | |
id | string | yes | Identifier (UUID) or name of the MCP server. | |
opts | ...CallOption | no | Per call options (query, idempotency key, traceparent, headers). |
Returns: (json.RawMessage, error). Decoded JSON answer of the operation "List the tools of an MCP server". The error is a typed error of the SDK, nil on success.
Raises: error, the typed errors of the transport (Errors).
MCPService.SyncHosted
SyncHosted(ctx context.Context, opts ...CallOption) (json.RawMessage, error)
Publish the MCP servers hosted by the Navin Manager. Publishes the MCP servers hosted by the Navin Manager (service mcp-host) in their project: token kept in the Credential Broker, server of the project created or updated, servers no longer hosted disabled. project (id or slug, default the request project) limits the synchronisation to one project; a project other than the request one answers 403 mcp_project_forbidden. Needs tenant_admin and a tenant (403 tenant_required).
Route: /v1/mcp/hosted/sync (POST).
| Name | Type | Default | Required | Description |
|---|---|---|---|---|
ctx | context.Context | yes | Context of the call: cancellation and deadline. | |
opts | ...CallOption | no | Per call options (query, idempotency key, traceparent, headers). |
Returns: (json.RawMessage, error). Decoded JSON answer of the operation "Publish the MCP servers hosted by the Navin Manager". The error is a typed error of the SDK, nil on success.
Raises: error, the typed errors of the transport (Errors).
Class SkillsService
SkillsService groups the endpoints of: Signed skills and Skill Loader.
SkillsService.Create
Create(ctx context.Context, body any, opts ...CallOption) (json.RawMessage, error)
Register a skill. Applies a Skill manifest: creates the skill or replaces it (a replaced skill goes back to draft, a blocked one stays blocked). The digest and the signature are verified at once: the skill becomes approved when they verify. A Git or OCI artifact needs artifact.digest (422 invalid_manifest). apply_status is created or updated. Needs tenant_admin, developer or application_owner; the caller becomes ReBAC owner. Audited as skill.apply.
Route: /v1/skills (POST).
| Name | Type | Default | Required | Description |
|---|---|---|---|---|
ctx | context.Context | yes | Context of the call: cancellation and deadline. | |
body | any | yes | Skill manifest (kind: Skill, metadata with name, version and owner, spec with description, instructions, permissions, signature and optional artifact). | |
opts | ...CallOption | no | Per call options (query, idempotency key, traceparent, headers). |
Returns: (json.RawMessage, error). Decoded JSON answer of the operation "Register a skill". The error is a typed error of the SDK, nil on success.
Raises: error, the typed errors of the transport (Errors).
SkillsService.Get
Get(ctx context.Context, name string, opts ...CallOption) (json.RawMessage, error)
Get a skill. Returns the skill with its manifest, content, digest, signature and verification. Needs the ReBAC relation viewer. 404 skill_not_found.
Route: /v1/skills/{name} (GET).
| Name | Type | Default | Required | Description |
|---|---|---|---|---|
ctx | context.Context | yes | Context of the call: cancellation and deadline. | |
name | string | yes | Name of the skill. | |
opts | ...CallOption | no | Per call options (query, idempotency key, traceparent, headers). |
Returns: (json.RawMessage, error). Decoded JSON answer of the operation "Get a skill". The error is a typed error of the SDK, nil on success.
Raises: error, the typed errors of the transport (Errors).
SkillsService.List
List(ctx context.Context, opts ...CallOption) (*Page, error)
List the skills. Skills of the tenant in name order, with version, owner, digest, verification result and status. One page only.
Route: /v1/skills (GET).
| Name | Type | Default | Required | Description |
|---|---|---|---|---|
ctx | context.Context | yes | Context of the call: cancellation and deadline. | |
opts | ...CallOption | no | Per call options (query, idempotency key, traceparent, headers). |
Returns: (*Page, error). A Page: Page is one page of a cursor paginated collection {"items": [...], "next_cursor": "..."|null}. The error is a typed error of the SDK, nil on success.
Raises: error, the typed errors of the transport (Errors).
SkillsService.Load
Load(ctx context.Context, name string, opts ...CallOption) (json.RawMessage, error)
Load a skill for an agent. Skill Loader: returns what a runtime needs to use the skill (instructions of an inline skill, artifact, entrypoint, permissions, dependencies, signer). Needs the ReBAC relation can_invoke. Refusals, each audited as skill.load denied: - 403 skill_blocked: the skill is blocked or deprecated; - 409 skill_digest_mismatch: the content no longer matches its digest; - 403 skill_unsigned: the signature does not verify; - 403 skill_not_granted: with agent, the skill is not listed in the agent manifest; - 403 skill_permission_denied: the skill asks for scopes the agent lacks, or its classification ceiling is below the agent one.
Route: /v1/skills/{name}/load (GET).
| Name | Type | Default | Required | Description |
|---|---|---|---|---|
ctx | context.Context | yes | Context of the call: cancellation and deadline. | |
name | string | yes | Name of the skill. | |
opts | ...CallOption | no | Per call options (query, idempotency key, traceparent, headers). |
Returns: (json.RawMessage, error). Decoded JSON answer of the operation "Load a skill for an agent". The error is a typed error of the SDK, nil on success.
Raises: error, the typed errors of the transport (Errors).
SkillsService.Verify
Verify(ctx context.Context, name string, opts ...CallOption) (json.RawMessage, error)
Verify a skill signature. Checks again the content digest and the signature against the trusted keys and stores the result: verified, method, signer, reason. A verified skill becomes approved, otherwise draft (a blocked skill stays blocked). Needs tenant_admin, developer, application_owner or security_officer and the ReBAC relation editor. Audited as skill.verify.
Route: /v1/skills/{name}/verify (POST).
| Name | Type | Default | Required | Description |
|---|---|---|---|---|
ctx | context.Context | yes | Context of the call: cancellation and deadline. | |
name | string | yes | Name of the skill. | |
opts | ...CallOption | no | Per call options (query, idempotency key, traceparent, headers). |
Returns: (json.RawMessage, error). Decoded JSON answer of the operation "Verify a skill signature". The error is a typed error of the SDK, nil on success.
Raises: error, the typed errors of the transport (Errors).
Class PluginsService
PluginsService groups the endpoints of: Plugins and installation.
PluginsService.Create
Create(ctx context.Context, body any, opts ...CallOption) (json.RawMessage, error)
Register a plugin. Applies a Plugin manifest: creates the plugin or updates it (back to registered, a blocked plugin stays blocked), with the signature verified and stored. Refused: 422 pack_requires_marketplace for a pack, 422 invalid_manifest when the oci_ref digest differs from artifact.digest, an allow list is missing for egress_allowlist or the limits exceed the platform maximum (4 CPU, 8Gi memory, 3600 s, 1 GPU); 409 plugin_installed while installed. Needs tenant_admin, developer or application_owner; the caller becomes ReBAC owner. Audited as plugin.apply.
Route: /v1/plugins (POST).
| Name | Type | Default | Required | Description |
|---|---|---|---|---|
ctx | context.Context | yes | Context of the call: cancellation and deadline. | |
body | any | yes | Plugin manifest (kind: Plugin, metadata, spec with description, artifact, signature and sandbox). | |
opts | ...CallOption | no | Per call options (query, idempotency key, traceparent, headers). |
Returns: (json.RawMessage, error). Decoded JSON answer of the operation "Register a plugin". The error is a typed error of the SDK, nil on success.
Raises: error, the typed errors of the transport (Errors).
PluginsService.Get
Get(ctx context.Context, name string, opts ...CallOption) (json.RawMessage, error)
Get a plugin. Returns the plugin with its manifest, verification result and rendered deployment. Needs the ReBAC relation viewer. 404 plugin_not_found.
Route: /v1/plugins/{name} (GET).
| Name | Type | Default | Required | Description |
|---|---|---|---|---|
ctx | context.Context | yes | Context of the call: cancellation and deadline. | |
name | string | yes | Name of the plugin. | |
opts | ...CallOption | no | Per call options (query, idempotency key, traceparent, headers). |
Returns: (json.RawMessage, error). Decoded JSON answer of the operation "Get a plugin". The error is a typed error of the SDK, nil on success.
Raises: error, the typed errors of the transport (Errors).
PluginsService.Install
Install(ctx context.Context, name string, opts ...CallOption) (json.RawMessage, error)
Install a plugin. Installs the plugin in its sandbox. Needs tenant_admin and the ReBAC relation owner. Steps: 1. A blocked plugin answers 403 plugin_blocked; an installed one is returned as is. 2. The signature is verified again (403 plugin_unsigned when it fails, audited as a denial). 3. The Deployment (runtime class of the sandbox, read-only root file system by default) and the NetworkPolicy are rendered, then applied when Kubernetes is configured (status: failed with the error if the apply fails). Returns the runtime status. Audited as plugin.install.
Route: /v1/plugins/{name}/install (POST).
| Name | Type | Default | Required | Description |
|---|---|---|---|---|
ctx | context.Context | yes | Context of the call: cancellation and deadline. | |
name | string | yes | Name of the plugin. | |
opts | ...CallOption | no | Per call options (query, idempotency key, traceparent, headers). |
Returns: (json.RawMessage, error). Decoded JSON answer of the operation "Install a plugin". The error is a typed error of the SDK, nil on success.
Raises: error, the typed errors of the transport (Errors).
PluginsService.List
List(ctx context.Context, opts ...CallOption) (*Page, error)
List the plugins. Plugins of the tenant in name order, with version, digest, verification and status. One page only.
Route: /v1/plugins (GET).
| Name | Type | Default | Required | Description |
|---|---|---|---|---|
ctx | context.Context | yes | Context of the call: cancellation and deadline. | |
opts | ...CallOption | no | Per call options (query, idempotency key, traceparent, headers). |
Returns: (*Page, error). A Page: Page is one page of a cursor paginated collection {"items": [...], "next_cursor": "..."|null}. The error is a typed error of the SDK, nil on success.
Raises: error, the typed errors of the transport (Errors).
PluginsService.Status
Status(ctx context.Context, name string, opts ...CallOption) (json.RawMessage, error)
Get the runtime status of a plugin. Runtime view: status, verified flag, digest, install date, runtime class, whether the objects were rendered or applied to Kubernetes, the Deployment and NetworkPolicy and the last error. Needs the ReBAC relation viewer.
Route: /v1/plugins/{name}/status (GET).
| Name | Type | Default | Required | Description |
|---|---|---|---|---|
ctx | context.Context | yes | Context of the call: cancellation and deadline. | |
name | string | yes | Name of the plugin. | |
opts | ...CallOption | no | Per call options (query, idempotency key, traceparent, headers). |
Returns: (json.RawMessage, error). Decoded JSON answer of the operation "Get the runtime status of a plugin". The error is a typed error of the SDK, nil on success.
Raises: error, the typed errors of the transport (Errors).
PluginsService.Uninstall
Uninstall(ctx context.Context, name string, opts ...CallOption) (json.RawMessage, error)
Uninstall a plugin. Deletes the Deployment and the NetworkPolicy from Kubernetes when configured (502 upstream_error on failure) and sets the plugin to uninstalled. Only an installed, installing or failed plugin (else 409 plugin_not_installed). Needs tenant_admin and the ReBAC relation owner. Audited as plugin.uninstall.
Route: /v1/plugins/{name}/uninstall (POST).
| Name | Type | Default | Required | Description |
|---|---|---|---|---|
ctx | context.Context | yes | Context of the call: cancellation and deadline. | |
name | string | yes | Name of the plugin. | |
opts | ...CallOption | no | Per call options (query, idempotency key, traceparent, headers). |
Returns: (json.RawMessage, error). Decoded JSON answer of the operation "Uninstall a plugin". The error is a typed error of the SDK, nil on success.
Raises: error, the typed errors of the transport (Errors).
Class ConnectorsService
ConnectorsService groups the endpoints of: Connectors, credentials and synchronization.
ConnectorsService.Create
Create(ctx context.Context, body any, opts ...CallOption) (json.RawMessage, error)
Register a connector. Applies a Connector manifest: creates or updates the connector (apply_status: created or updated). The URLs must be allowed by the egress policy; OAuth2 needs auth.token_url; unsigned webhooks are refused (422 invalid_manifest). Needs tenant_admin, developer or application_owner. Audited as connector.apply.
Route: /v1/connectors (POST).
| Name | Type | Default | Required | Description |
|---|---|---|---|---|
ctx | context.Context | yes | Context of the call: cancellation and deadline. | |
body | any | yes | Connector manifest (kind: Connector, metadata, spec with base URL, auth, resources, scopes, sync and webhooks). | |
opts | ...CallOption | no | Per call options (query, idempotency key, traceparent, headers). |
Returns: (json.RawMessage, error). Decoded JSON answer of the operation "Register a connector". The error is a typed error of the SDK, nil on success.
Raises: error, the typed errors of the transport (Errors).
ConnectorsService.Delete
Delete(ctx context.Context, name string, opts ...CallOption) error
Delete a connector. Deletes the connector and its credentials in the secret store. Needs tenant_admin. 404 connector_not_found. Audited as connector.delete.
Route: /v1/connectors/{name} (DELETE).
| Name | Type | Default | Required | Description |
|---|---|---|---|---|
ctx | context.Context | yes | Context of the call: cancellation and deadline. | |
name | string | yes | Name of the connector. | |
opts | ...CallOption | no | Per call options (query, idempotency key, traceparent, headers). |
Returns: error. Error of the call (a typed error of the SDK), nil on success.
Raises: error, the typed errors of the transport (Errors).
ConnectorsService.Get
Get(ctx context.Context, name string, opts ...CallOption) (json.RawMessage, error)
Get a connector. Returns the connector with its manifest, status, owner and configured credentials (kind, field names, update date). 404 connector_not_found.
Route: /v1/connectors/{name} (GET).
| Name | Type | Default | Required | Description |
|---|---|---|---|---|
ctx | context.Context | yes | Context of the call: cancellation and deadline. | |
name | string | yes | Name of the connector. | |
opts | ...CallOption | no | Per call options (query, idempotency key, traceparent, headers). |
Returns: (json.RawMessage, error). Decoded JSON answer of the operation "Get a connector". The error is a typed error of the SDK, nil on success.
Raises: error, the typed errors of the transport (Errors).
ConnectorsService.List
List(ctx context.Context, opts ...CallOption) (*Page, error)
List the connectors. Connectors of the tenant in name order, each with the kinds of credentials configured (never their values). One page only.
Route: /v1/connectors (GET).
| Name | Type | Default | Required | Description |
|---|---|---|---|---|
ctx | context.Context | yes | Context of the call: cancellation and deadline. | |
opts | ...CallOption | no | Per call options (query, idempotency key, traceparent, headers). |
Returns: (*Page, error). A Page: Page is one page of a cursor paginated collection {"items": [...], "next_cursor": "..."|null}. The error is a typed error of the SDK, nil on success.
Raises: error, the typed errors of the transport (Errors).
ConnectorsService.SetCredentials
SetCredentials(ctx context.Context, name string, body any, opts ...CallOption) (json.RawMessage, error)
Store connector credentials. Stores credentials in the secret store and returns only the kind and the field names (201). Needs tenant_admin or security_officer. Body: kind plus its fields: - oauth2_client: client_id, client_secret; - oauth2_code: code, redirect_uri, optional code_verifier; the code is exchanged at once at the token URL (needs a stored oauth2_client, else 409 credential_unavailable) and kept as oauth2_token; - api_key: api_key, optional header; - service_account: private_key or token, optional client_email, client_id; - basic: username, password; - webhook_secret: secret. Unknown kinds and missing fields answer 400 invalid_request. Audited as connector.credentials.write.
Route: /v1/connectors/{name}/credentials (POST).
| Name | Type | Default | Required | Description |
|---|---|---|---|---|
ctx | context.Context | yes | Context of the call: cancellation and deadline. | |
name | string | yes | Name of the connector. | |
body | any | yes | Credential kind and its fields. Write only: values are never returned. | |
opts | ...CallOption | no | Per call options (query, idempotency key, traceparent, headers). |
Returns: (json.RawMessage, error). Decoded JSON answer of the operation "Store connector credentials". The error is a typed error of the SDK, nil on success.
Raises: error, the typed errors of the transport (Errors).
ConnectorsService.Sync
Sync(ctx context.Context, name string, opts ...CallOption) (json.RawMessage, error)
Start a synchronisation. Queues a sync run (202) and publishes connectors.<name>.sync for the worker. The manifest must declare a sync mode (409 sync_disabled), the connector must be active (409 connector_disabled), resources must be readable (400 invalid_request) and no other run may be queued or running (409 sync_in_progress). An incremental sync starts from the cursor of the last successful run unless full. The policy connector.sync is evaluated. Needs tenant_admin, developer or agent. Audited as connector.sync.
Route: /v1/connectors/{name}/sync (POST).
| Name | Type | Default | Required | Description |
|---|---|---|---|---|
ctx | context.Context | yes | Context of the call: cancellation and deadline. | |
name | string | yes | Name of the connector. | |
opts | ...CallOption | no | Per call options (query, idempotency key, traceparent, headers). |
Returns: (json.RawMessage, error). Decoded JSON answer of the operation "Start a synchronisation". The error is a typed error of the SDK, nil on success.
Raises: error, the typed errors of the transport (Errors).
ConnectorsService.SyncRuns
SyncRuns(ctx context.Context, name string, opts ...CallOption) (*Page, error)
List the sync runs of a connector. Synchronisation runs of the connector, newest first: mode, status, resources, cursor and dates.
Route: /v1/connectors/{name}/sync-runs (GET).
| Name | Type | Default | Required | Description |
|---|---|---|---|---|
ctx | context.Context | yes | Context of the call: cancellation and deadline. | |
name | string | yes | Name of the connector. | |
opts | ...CallOption | no | Per call options (query, idempotency key, traceparent, headers). |
Returns: (*Page, error). A Page: Page is one page of a cursor paginated collection {"items": [...], "next_cursor": "..."|null}. The error is a typed error of the SDK, nil on success.
Raises: error, the typed errors of the transport (Errors).
ConnectorsService.Test
Test(ctx context.Context, name string, opts ...CallOption) (json.RawMessage, error)
Test a connector. Builds the authentication headers from the stored credentials and, when the manifest has a base URL, sends a GET to it. Returns ok, credentials, http_status, latency_ms and an error code on failure (egress_denied, upstream_unavailable, credential errors); a failed test is a 200 with ok: false. The policy connector.test is evaluated. Needs tenant_admin, developer or application_owner. Audited as connector.test.
Route: /v1/connectors/{name}/test (POST).
| Name | Type | Default | Required | Description |
|---|---|---|---|---|
ctx | context.Context | yes | Context of the call: cancellation and deadline. | |
name | string | yes | Name of the connector. | |
opts | ...CallOption | no | Per call options (query, idempotency key, traceparent, headers). |
Returns: (json.RawMessage, error). Decoded JSON answer of the operation "Test a connector". The error is a typed error of the SDK, nil on success.
Raises: error, the typed errors of the transport (Errors).
ConnectorsService.Update
Update(ctx context.Context, name string, body any, opts ...CallOption) (json.RawMessage, error)
Update a connector. Changes the status or the owner. Disabling a connector revokes its credential leases at once. Needs tenant_admin, developer or application_owner. Audited as connector.update.
Route: /v1/connectors/{name} (PATCH).
| Name | Type | Default | Required | Description |
|---|---|---|---|---|
ctx | context.Context | yes | Context of the call: cancellation and deadline. | |
name | string | yes | Name of the connector. | |
body | any | yes | Fields to change; the omitted ones are kept. | |
opts | ...CallOption | no | Per call options (query, idempotency key, traceparent, headers). |
Returns: (json.RawMessage, error). Decoded JSON answer of the operation "Update a connector". The error is a typed error of the SDK, nil on success.
Raises: error, the typed errors of the transport (Errors).
Class CredentialsService
CredentialsService groups the endpoints of: Credential Broker short lived leases.
CredentialsService.Lease
Lease(ctx context.Context, body any, opts ...CallOption) (json.RawMessage, error)
Obtain a credential lease. Issues a short lived lease on a connector instead of its secret (201): lease_id, token (shown once), scopes, expires_at, ttl_seconds. Requested scopes must be declared by the connector (403 scope_not_allowed; default: all of them); the connector must be active (409 connector_disabled). With on_behalf_of, the user must hold the relation can_invoke on the connector (403 relation_required). Needs tenant_admin, developer or agent. Audited as credential.lease.
Route: /v1/credentials/broker/lease (POST).
| Name | Type | Default | Required | Description |
|---|---|---|---|---|
ctx | context.Context | yes | Context of the call: cancellation and deadline. | |
body | any | yes | Connector, scopes, lifetime, run and user acted for. | |
opts | ...CallOption | no | Per call options (query, idempotency key, traceparent, headers). |
Returns: (json.RawMessage, error). Decoded JSON answer of the operation "Obtain a credential lease". The error is a typed error of the SDK, nil on success.
Raises: error, the typed errors of the transport (Errors).
Class WebhooksService
WebhooksService groups the endpoints of: Inbound webhooks (HMAC-SHA256 signed) and deliveries.
WebhooksService.Deliver
Deliver(ctx context.Context, connector string, body any, opts ...CallOption) (json.RawMessage, error)
Receive a provider webhook. Entry point for the provider, without platform authentication. Headers: X-EAI-Tenant (tenant slug, else 400 tenant_required), X-EAI-Signature (t=<unix seconds>,v1=<hex HMAC-SHA256 of "<t>." + raw body>; X-EAI-Timestamp may carry the time), optional X-EAI-Delivery (dedupe id). Steps: 1. The connector must exist, be active and have webhooks enabled (404 connector_not_found). 2. Signature checked with the stored webhook_secret or the manifest secret reference (401 invalid_signature); timestamp within 5 minutes (401 webhook_replay); a delivery already accepted answers 409 webhook_duplicate. 3. The JSON body is screened as untrusted content (prompt injection blocked), then published as connectors.<name>.webhook, which may start triggered runs. Answers 202 with delivery_id, event_id and triggered. Every delivery is recorded and audited as webhook.receive.
Route: /v1/webhooks/{connector} (POST).
| Name | Type | Default | Required | Description |
|---|---|---|---|---|
ctx | context.Context | yes | Context of the call: cancellation and deadline. | |
connector | string | yes | Name of the connector the provider sends to. | |
body | any | yes | Raw provider payload; the signature is verified on these exact bytes, whatever the content type. | |
opts | ...CallOption | no | Per call options (query, idempotency key, traceparent, headers). |
Returns: (json.RawMessage, error). Decoded JSON answer of the operation "Receive a provider webhook". The error is a typed error of the SDK, nil on success.
Raises: error, the typed errors of the transport (Errors).
WebhooksService.Deliveries
Deliveries(ctx context.Context, opts ...CallOption) (*Page, error)
List the webhook deliveries. Webhook deliveries received, newest first: connector, delivery id, signature validity, status (accepted, rejected, duplicate), reason, SHA-256 of the payload and published event. The payload itself is not stored here.
Route: /v1/webhooks/deliveries (GET).
| Name | Type | Default | Required | Description |
|---|---|---|---|---|
ctx | context.Context | yes | Context of the call: cancellation and deadline. | |
opts | ...CallOption | no | Per call options (query, idempotency key, traceparent, headers). |
Returns: (*Page, error). A Page: Page is one page of a cursor paginated collection {"items": [...], "next_cursor": "..."|null}. The error is a typed error of the SDK, nil on success.
Raises: error, the typed errors of the transport (Errors).
Class ChannelsService
ChannelsService groups the endpoints of: Channels (message in, run out).
ChannelsService.Create
Create(ctx context.Context, body any, opts ...CallOption) (json.RawMessage, error)
Create or update a channel. Applies a Channel manifest (apply_status: created or updated); project (id or slug, default the X-Project header) attaches it to a project, and a channel of another project is never taken over (409 channel_project_conflict). The agent_ref agent must exist (404 agent_not_found); signed_webhook needs auth.secret_ref (422 invalid_manifest). Needs tenant_admin, developer or application_owner. Audited as channel.apply.
Route: /v1/channels (POST).
| Name | Type | Default | Required | Description |
|---|---|---|---|---|
ctx | context.Context | yes | Context of the call: cancellation and deadline. | |
body | any | yes | Channel manifest (kind: Channel, metadata, spec with type, agent, auth, limits, DLP and sessions). | |
opts | ...CallOption | no | Per call options (query, idempotency key, traceparent, headers). |
Returns: (json.RawMessage, error). Decoded JSON answer of the operation "Create or update a channel". The error is a typed error of the SDK, nil on success.
Raises: error, the typed errors of the transport (Errors).
ChannelsService.Delete
Delete(ctx context.Context, name string, opts ...CallOption) error
Delete a channel. Deletes the channel. Needs tenant_admin. 404 channel_not_found. Audited as channel.delete.
Route: /v1/channels/{name} (DELETE).
| Name | Type | Default | Required | Description |
|---|---|---|---|---|
ctx | context.Context | yes | Context of the call: cancellation and deadline. | |
name | string | yes | Name of the channel. | |
opts | ...CallOption | no | Per call options (query, idempotency key, traceparent, headers). |
Returns: error. Error of the call (a typed error of the SDK), nil on success.
Raises: error, the typed errors of the transport (Errors).
ChannelsService.Get
Get(ctx context.Context, name string, opts ...CallOption) (json.RawMessage, error)
Get a channel. Returns the channel with its manifest, type, agent, status, project and preset. 404 channel_not_found.
Route: /v1/channels/{name} (GET).
| Name | Type | Default | Required | Description |
|---|---|---|---|---|
ctx | context.Context | yes | Context of the call: cancellation and deadline. | |
name | string | yes | Name of the channel. | |
opts | ...CallOption | no | Per call options (query, idempotency key, traceparent, headers). |
Returns: (json.RawMessage, error). Decoded JSON answer of the operation "Get a channel". The error is a typed error of the SDK, nil on success.
Raises: error, the typed errors of the transport (Errors).
ChannelsService.Inbound
Inbound(ctx context.Context, name string, body any, opts ...CallOption) (json.RawMessage, error)
Post an inbound message. Delivers a message from an end user (202) and returns session_id, session_created, message_id, run_id (or run_skipped when the agent is not active) and the DLP result. Needs tenant_admin, developer or agent. Steps: 1. The channel must be active (409 channel_disabled); a signed_webhook channel checks X-EAI-Signature (t=<unix seconds>,v1=<hex HMAC-SHA256 of "<t>." + raw body>, 5 minute window; 401 invalid_signature). 2. The policy channel.inbound is evaluated; size (413 message_too_large) and rate per user (429 rate_limited) are checked. 3. Inbound DLP runs (default detect; block answers 403 dlp_blocked, mask stores the masked text). 4. The open session of the user and conversation is reused, or a new one opened (429 too_many_sessions, 409 session_closed past max_session_minutes). 5. The message is added and a run of the channel agent starts with trigger channel.
Route: /v1/channels/{name}/inbound (POST).
| Name | Type | Default | Required | Description |
|---|---|---|---|---|
ctx | context.Context | yes | Context of the call: cancellation and deadline. | |
name | string | yes | Name of the channel. | |
body | any | yes | JSON message: text (1 to 1000000 characters, required), user (external user id, up to 300 characters; default the caller), conversation_id (up to 300 characters; default the user) and metadata (kept with the message). The raw bytes are used for the signature check. | |
opts | ...CallOption | no | Per call options (query, idempotency key, traceparent, headers). |
Returns: (json.RawMessage, error). Decoded JSON answer of the operation "Post an inbound message". The error is a typed error of the SDK, nil on success.
Raises: error, the typed errors of the transport (Errors).
ChannelsService.List
List(ctx context.Context, opts ...CallOption) (*Page, error)
List the channels. Channels of the tenant in name order; project (id or slug) keeps the channels of that project only (404 project_not_found). One page only.
Route: /v1/channels (GET).
| Name | Type | Default | Required | Description |
|---|---|---|---|---|
ctx | context.Context | yes | Context of the call: cancellation and deadline. | |
opts | ...CallOption | no | Per call options (query, idempotency key, traceparent, headers). |
Returns: (*Page, error). A Page: Page is one page of a cursor paginated collection {"items": [...], "next_cursor": "..."|null}. The error is a typed error of the SDK, nil on success.
Raises: error, the typed errors of the transport (Errors).
ChannelsService.Sessions
Sessions(ctx context.Context, name string, opts ...CallOption) (*Page, error)
List the sessions of a channel. Sessions opened on the channel, most recently updated first, at most 500.
Route: /v1/channels/{name}/sessions (GET).
| Name | Type | Default | Required | Description |
|---|---|---|---|---|
ctx | context.Context | yes | Context of the call: cancellation and deadline. | |
name | string | yes | Name of the channel. | |
opts | ...CallOption | no | Per call options (query, idempotency key, traceparent, headers). |
Returns: (*Page, error). A Page: Page is one page of a cursor paginated collection {"items": [...], "next_cursor": "..."|null}. The error is a typed error of the SDK, nil on success.
Raises: error, the typed errors of the transport (Errors).
ChannelsService.Update
Update(ctx context.Context, name string, body any, opts ...CallOption) (json.RawMessage, error)
Update a channel. Changes the status (active or disabled; a disabled channel refuses inbound messages) or the owner. Needs tenant_admin, developer or application_owner. Audited as channel.update.
Route: /v1/channels/{name} (PATCH).
| Name | Type | Default | Required | Description |
|---|---|---|---|---|
ctx | context.Context | yes | Context of the call: cancellation and deadline. | |
name | string | yes | Name of the channel. | |
body | any | yes | Fields to change; the omitted ones are kept. | |
opts | ...CallOption | no | Per call options (query, idempotency key, traceparent, headers). |
Returns: (json.RawMessage, error). Decoded JSON answer of the operation "Update a channel". The error is a typed error of the SDK, nil on success.
Raises: error, the typed errors of the transport (Errors).
Class PrivacyService
PrivacyService groups the endpoints of: Data classification.
PrivacyService.Classify
Classify(ctx context.Context, body any, opts ...CallOption) (json.RawMessage, error)
Classify a text or a media. With text, detects the entities with the tenant rules and returns classification, findings and engine, without changing the text. With media_id, returns the classification, findings and DLP result already computed for that media (404 not_found for an unknown media). One of the two is required (400 invalid_request). Open to any member of the tenant.
Route: /v1/privacy/classify (POST).
| Name | Type | Default | Required | Description |
|---|---|---|---|---|
ctx | context.Context | yes | Context of the call: cancellation and deadline. | |
body | any | yes | Text or media to classify, and language. | |
opts | ...CallOption | no | Per call options (query, idempotency key, traceparent, headers). |
Returns: (json.RawMessage, error). Decoded JSON answer of the operation "Classify a text or a media". The error is a typed error of the SDK, nil on success.
Raises: error, the typed errors of the transport (Errors).
Class DLPService
DLPService groups the endpoints of: Data loss prevention inspection, redaction and rules.
DLPService.CreateRule
CreateRule(ctx context.Context, body any, opts ...CallOption) (json.RawMessage, error)
Create or update a DLP rule. Creates the rule, or replaces the rule of the same name. A rule needs an entity_type or a pattern (a valid regular expression); errors answer 400 invalid_request (unknown action, invalid pattern or classification). Needs tenant_admin or security_officer. Writes the audit event dlp.rule.upsert. Answers 201 with the rule.
Route: /v1/dlp/rules (POST).
| Name | Type | Default | Required | Description |
|---|---|---|---|---|
ctx | context.Context | yes | Context of the call: cancellation and deadline. | |
body | any | yes | Name, entity type or pattern, action, classification and score of the rule. | |
opts | ...CallOption | no | Per call options (query, idempotency key, traceparent, headers). |
Returns: (json.RawMessage, error). Decoded JSON answer of the operation "Create or update a DLP rule". The error is a typed error of the SDK, nil on success.
Raises: error, the typed errors of the transport (Errors).
DLPService.Inspect
Inspect(ctx context.Context, body any, opts ...CallOption) (json.RawMessage, error)
Inspect a text for sensitive data. Runs DLP on the text with the tenant rules, in mode detect unless mode says otherwise. The answer gives text, findings (type, position, score, classification, short preview, action, rule), action (strongest action applied), classification, mode, engine (builtin or presidio), blocked and count. An unknown mode answers 400. Open to any member of the tenant. Writes the audit event dlp.inspect (counts and types only).
Route: /v1/dlp/inspect (POST).
| Name | Type | Default | Required | Description |
|---|---|---|---|---|
ctx | context.Context | yes | Context of the call: cancellation and deadline. | |
body | any | yes | Text, optional mode and language. | |
opts | ...CallOption | no | Per call options (query, idempotency key, traceparent, headers). |
Returns: (json.RawMessage, error). Decoded JSON answer of the operation "Inspect a text for sensitive data". The error is a typed error of the SDK, nil on success.
Raises: error, the typed errors of the transport (Errors).
DLPService.ListRules
ListRules(ctx context.Context, opts ...CallOption) (*Page, error)
List the DLP rules. Lists the DLP rules of the tenant ordered by name. Open to any member of the tenant. next_cursor is always null.
Route: /v1/dlp/rules (GET).
| Name | Type | Default | Required | Description |
|---|---|---|---|---|
ctx | context.Context | yes | Context of the call: cancellation and deadline. | |
opts | ...CallOption | no | Per call options (query, idempotency key, traceparent, headers). |
Returns: (*Page, error). A Page: Page is one page of a cursor paginated collection {"items": [...], "next_cursor": "..."|null}. The error is a typed error of the SDK, nil on success.
Raises: error, the typed errors of the transport (Errors).
DLPService.Redact
Redact(ctx context.Context, body any, opts ...CallOption) (json.RawMessage, error)
Redact sensitive data from a text. Same as inspect, in mode mask by default: each finding is replaced by [TYPE] (for example [EMAIL]), or tokenized or blocked when a tenant rule or mode says so; a blocked text comes back empty with blocked: true. Open to any member of the tenant. Writes the audit event dlp.redact.
Route: /v1/dlp/redact (POST).
| Name | Type | Default | Required | Description |
|---|---|---|---|---|
ctx | context.Context | yes | Context of the call: cancellation and deadline. | |
body | any | yes | Text, optional mode and language. | |
opts | ...CallOption | no | Per call options (query, idempotency key, traceparent, headers). |
Returns: (json.RawMessage, error). Decoded JSON answer of the operation "Redact sensitive data from a text". The error is a typed error of the SDK, nil on success.
Raises: error, the typed errors of the transport (Errors).
Class TokenizationService
TokenizationService groups the endpoints of: Reversible tokenization.
TokenizationService.Detokenize
Detokenize(ctx context.Context, body any, opts ...CallOption) (json.RawMessage, error)
Detokenize values. Returns the original values of tokens given in tokens or found in text.
Route: /v1/tokenization/detokenize (POST).
| Name | Type | Default | Required | Description |
|---|---|---|---|---|
ctx | context.Context | yes | Context of the call: cancellation and deadline. | |
body | any | yes | Tokens or text holding tokens, and purpose. | |
opts | ...CallOption | no | Per call options (query, idempotency key, traceparent, headers). |
Returns: (json.RawMessage, error). Decoded JSON answer of the operation "Detokenize values". The error is a typed error of the SDK, nil on success.
Raises: error, the typed errors of the transport (Errors).
TokenizationService.Tokenize
Tokenize(ctx context.Context, body any, opts ...CallOption) (json.RawMessage, error)
Tokenize values. Replaces sensitive values by deterministic tokens tok_<type>_<hex> of the tenant (the same value always gives the same token), the values being stored encrypted in the vault. With values, returns tokens; with text, detects the entities and returns the tokenized text, findings and classification. One of the two is required (400 invalid_request). Open to any member of the tenant. Writes the audit event tokenization.tokenize (count only).
Route: /v1/tokenization/tokenize (POST).
| Name | Type | Default | Required | Description |
|---|---|---|---|---|
ctx | context.Context | yes | Context of the call: cancellation and deadline. | |
body | any | yes | Values or text to tokenize. | |
opts | ...CallOption | no | Per call options (query, idempotency key, traceparent, headers). |
Returns: (json.RawMessage, error). Decoded JSON answer of the operation "Tokenize values". The error is a typed error of the SDK, nil on success.
Raises: error, the typed errors of the transport (Errors).
Class EncryptionService
EncryptionService groups the endpoints of: Envelope encryption and keys.
EncryptionService.CreateKey
CreateKey(ctx context.Context, body any, opts ...CallOption) (json.RawMessage, error)
Create an encryption key. Creates a named key with its first version; the data key is generated and wrapped by OpenBao Transit when configured, locally otherwise. The name must be lowercase letters, digits, ., _ or -, at most 63 characters (400 invalid_request); a name already used answers 409 conflict. Needs tenant_admin or security_officer. Writes the audit event encryption.key.create.
Route: /v1/encryption/keys (POST).
| Name | Type | Default | Required | Description |
|---|---|---|---|---|
ctx | context.Context | yes | Context of the call: cancellation and deadline. | |
body | any | yes | Name and purpose of the key. | |
opts | ...CallOption | no | Per call options (query, idempotency key, traceparent, headers). |
Returns: (json.RawMessage, error). Decoded JSON answer of the operation "Create an encryption key". The error is a typed error of the SDK, nil on success.
Raises: error, the typed errors of the transport (Errors).
EncryptionService.Decrypt
Decrypt(ctx context.Context, body any, opts ...CallOption) (json.RawMessage, error)
Decrypt a ciphertext. Decrypts an eaienc1 ciphertext of the tenant with the key version it names, checking the same aad as at encryption. Returns plaintext, or plaintext_base64 with as_base64 or when the data is not UTF-8 text, and key_version. Old versions keep decrypting after a rotation. Open to any member of the tenant. Writes the audit event encryption.decrypt.
Route: /v1/encryption/decrypt (POST).
| Name | Type | Default | Required | Description |
|---|---|---|---|---|
ctx | context.Context | yes | Context of the call: cancellation and deadline. | |
body | any | yes | Ciphertext, associated data and output format. | |
opts | ...CallOption | no | Per call options (query, idempotency key, traceparent, headers). |
Returns: (json.RawMessage, error). Decoded JSON answer of the operation "Decrypt a ciphertext". The error is a typed error of the SDK, nil on success.
Raises: error, the typed errors of the transport (Errors).
EncryptionService.Encrypt
Encrypt(ctx context.Context, body any, opts ...CallOption) (json.RawMessage, error)
Encrypt data with a tenant key. Encrypts plaintext (UTF-8 text) or plaintext_base64 (bytes) with the current version of the key, bound to aad. Returns ciphertext (eaienc1:...), key_id and key_version. One of the two inputs is required, and base64 must be valid (400 invalid_request); an unknown key answers 404 key_not_found. Open to any member of the tenant. Writes the audit event encryption.encrypt (size only).
Route: /v1/encryption/encrypt (POST).
| Name | Type | Default | Required | Description |
|---|---|---|---|---|
ctx | context.Context | yes | Context of the call: cancellation and deadline. | |
body | any | yes | Key, data to encrypt and associated data. | |
opts | ...CallOption | no | Per call options (query, idempotency key, traceparent, headers). |
Returns: (json.RawMessage, error). Decoded JSON answer of the operation "Encrypt data with a tenant key". The error is a typed error of the SDK, nil on success.
Raises: error, the typed errors of the transport (Errors).
EncryptionService.ListKeys
ListKeys(ctx context.Context, opts ...CallOption) (*Page, error)
List the encryption keys. Lists the encryption keys of the tenant ordered by name: id, name, backend (openbao-transit or local), purpose, current version and dates. Never the key material. Open to any member of the tenant.
Route: /v1/encryption/keys (GET).
| Name | Type | Default | Required | Description |
|---|---|---|---|---|
ctx | context.Context | yes | Context of the call: cancellation and deadline. | |
opts | ...CallOption | no | Per call options (query, idempotency key, traceparent, headers). |
Returns: (*Page, error). A Page: Page is one page of a cursor paginated collection {"items": [...], "next_cursor": "..."|null}. The error is a typed error of the SDK, nil on success.
Raises: error, the typed errors of the transport (Errors).
EncryptionService.RotateKey
RotateKey(ctx context.Context, id string, opts ...CallOption) (json.RawMessage, error)
Rotate an encryption key. Adds a new version to the key: new encryptions use it, older ciphertexts keep decrypting with their own version. Needs tenant_admin or security_officer. Answers 404 key_not_found. Writes the audit event encryption.key.rotate.
Route: /v1/encryption/keys/{key_id}/rotate (POST).
| Name | Type | Default | Required | Description |
|---|---|---|---|---|
ctx | context.Context | yes | Context of the call: cancellation and deadline. | |
id | string | yes | Identifier (UUID) or name of the key. | |
opts | ...CallOption | no | Per call options (query, idempotency key, traceparent, headers). |
Returns: (json.RawMessage, error). Decoded JSON answer of the operation "Rotate an encryption key". The error is a typed error of the SDK, nil on success.
Raises: error, the typed errors of the transport (Errors).
Class KnowledgeService
KnowledgeService groups the endpoints of: Knowledge bases (RAG ingestion and ACL filtered retrieval).
KnowledgeService.AddDocument
AddDocument(ctx context.Context, id string, body any, opts ...CallOption) (json.RawMessage, error)
Add a document. Ingests a document (201). Needs the ReBAC relation editor and write access by the ACL (403 not_permitted_acl). Steps: 1. The content (content or content_base64, one is required, else 400) is scanned by ClamAV and YARA-X (422 file_blocked, 503 file_scan_unavailable), then the text is extracted by Docling (422 unsupported_media). 2. Personal data detection may raise the classification; a source_connector must be active. 3. A document with the same uri replaces the previous version (version + 1). 4. The text is chunked, embedded and stored; the poisoning screening may put the document in quarantine (status: quarantined). 409 knowledge_base_reindexing while a reindex runs; 409 embedding_dimension_mismatch; 503 vector_store_unavailable. Audited as knowledge.document.ingest.
Route: /v1/knowledge-bases/{kb_id}/documents (POST).
| Name | Type | Default | Required | Description |
|---|---|---|---|---|
ctx | context.Context | yes | Context of the call: cancellation and deadline. | |
id | string | yes | Identifier (UUID) of the knowledge base. | |
body | any | yes | Content, title, URI, classification, readers and metadata of the document. | |
opts | ...CallOption | no | Per call options (query, idempotency key, traceparent, headers). |
Returns: (json.RawMessage, error). Decoded JSON answer of the operation "Add a document". The error is a typed error of the SDK, nil on success.
Raises: error, the typed errors of the transport (Errors).
KnowledgeService.Create
Create(ctx context.Context, body any, opts ...CallOption) (json.RawMessage, error)
Create a knowledge base. Creates a knowledge base with its embedding model (default: the platform RAG embedding model), which must be approved, have the embeddings capability and accept the classification. chunk_overlap must be lower than chunk_size (400 invalid_request); an unknown classification answers 400. A name already used in the tenant answers 409 conflict. Needs tenant_admin or developer; the caller becomes ReBAC owner. Audited as knowledge_base.create.
Route: /v1/knowledge-bases (POST).
| Name | Type | Default | Required | Description |
|---|---|---|---|---|
ctx | context.Context | yes | Context of the call: cancellation and deadline. | |
body | any | yes | Name, chunking, classification, ACL and embedding model of the knowledge base. | |
opts | ...CallOption | no | Per call options (query, idempotency key, traceparent, headers). |
Returns: (json.RawMessage, error). Decoded JSON answer of the operation "Create a knowledge base". The error is a typed error of the SDK, nil on success.
Raises: error, the typed errors of the transport (Errors).
KnowledgeService.Delete
Delete(ctx context.Context, id string, opts ...CallOption) error
Delete a knowledge base. Deletes the knowledge base, its documents and their vectors in the vector store. Needs the ReBAC relation owner, and the caller must be tenant_admin or its creator (403 forbidden). 404 not_found; 503 vector_store_unavailable. Audited as knowledge_base.delete.
Route: /v1/knowledge-bases/{kb_id} (DELETE).
| Name | Type | Default | Required | Description |
|---|---|---|---|---|
ctx | context.Context | yes | Context of the call: cancellation and deadline. | |
id | string | yes | Identifier (UUID) of the knowledge base. | |
opts | ...CallOption | no | Per call options (query, idempotency key, traceparent, headers). |
Returns: error. Error of the call (a typed error of the SDK), nil on success.
Raises: error, the typed errors of the transport (Errors).
KnowledgeService.DeleteDocument
DeleteDocument(ctx context.Context, id string, docID string, opts ...CallOption) error
Delete a document. Deletes the document and its vectors. Needs the ReBAC relation editor and write access by the ACL: tenant_admin, an identity listed in writers, or, when writers is empty, developer or agent (else 403 not_permitted_acl). 404 not_found. Audited as knowledge.document.delete.
Route: /v1/knowledge-bases/{kb_id}/documents/{doc_id} (DELETE).
| Name | Type | Default | Required | Description |
|---|---|---|---|---|
ctx | context.Context | yes | Context of the call: cancellation and deadline. | |
id | string | yes | Identifier (UUID) of the knowledge base. | |
docID | string | yes | Identifier (UUID) of the document. | |
opts | ...CallOption | no | Per call options (query, idempotency key, traceparent, headers). |
Returns: error. Error of the call (a typed error of the SDK), nil on success.
Raises: error, the typed errors of the transport (Errors).
KnowledgeService.Documents
Documents(ctx context.Context, id string, opts ...CallOption) (*Page, error)
List the documents of a knowledge base. Documents the caller may read (one of its identities in the document readers, classification within its clearance), paginated with cursor. Needs the ReBAC relation viewer and read access to the knowledge base.
Route: /v1/knowledge-bases/{kb_id}/documents (GET).
| Name | Type | Default | Required | Description |
|---|---|---|---|---|
ctx | context.Context | yes | Context of the call: cancellation and deadline. | |
id | string | yes | Identifier (UUID) of the knowledge base. | |
opts | ...CallOption | no | Per call options (query, idempotency key, traceparent, headers). |
Returns: (*Page, error). A Page: Page is one page of a cursor paginated collection {"items": [...], "next_cursor": "..."|null}. The error is a typed error of the SDK, nil on success.
Raises: error, the typed errors of the transport (Errors).
KnowledgeService.Get
Get(ctx context.Context, id string, opts ...CallOption) (json.RawMessage, error)
Get a knowledge base. Returns the knowledge base with its document count, its ingestion and retrieval pipeline, the running reindex job if any and the datasets the caller may see. Needs the ReBAC relation viewer and read access by the ACL; otherwise 404 not_found.
Route: /v1/knowledge-bases/{kb_id} (GET).
| Name | Type | Default | Required | Description |
|---|---|---|---|---|
ctx | context.Context | yes | Context of the call: cancellation and deadline. | |
id | string | yes | Identifier (UUID) of the knowledge base. | |
opts | ...CallOption | no | Per call options (query, idempotency key, traceparent, headers). |
Returns: (json.RawMessage, error). Decoded JSON answer of the operation "Get a knowledge base". The error is a typed error of the SDK, nil on success.
Raises: error, the typed errors of the transport (Errors).
KnowledgeService.List
List(ctx context.Context, opts ...CallOption) (*Page, error)
List the knowledge bases. Knowledge bases of the tenant that the caller may read by their ACL, in name order, paginated with cursor.
Route: /v1/knowledge-bases (GET).
| Name | Type | Default | Required | Description |
|---|---|---|---|---|
ctx | context.Context | yes | Context of the call: cancellation and deadline. | |
opts | ...CallOption | no | Per call options (query, idempotency key, traceparent, headers). |
Returns: (*Page, error). A Page: Page is one page of a cursor paginated collection {"items": [...], "next_cursor": "..."|null}. The error is a typed error of the SDK, nil on success.
Raises: error, the typed errors of the transport (Errors).
KnowledgeService.Query
Query(ctx context.Context, id string, body any, opts ...CallOption) (json.RawMessage, error)
Query a knowledge base. Searches the knowledge base and returns results (chunk, score, injection risk, classification, provenance), citations and a lineage_run_id. Needs the ReBAC relation can_invoke. Steps: 1. The policy knowledge.query is evaluated and a quota reservation is taken. 2. The query is embedded with the model of the knowledge base; only chunks whose readers match the caller identities and whose classification fits its clearance are searched. 3. Retrieved chunks are screened for prompt injection (dropped in block mode) and checked against active sources. 4. hybrid re-scores the candidates with keyword overlap; rerank orders them with a rerank model (a refusal is reported in warnings, never hidden). A caller outside the ACL gets an empty result, audited as a denial. Audited as knowledge.query; usage is metered.
Route: /v1/knowledge-bases/{kb_id}/query (POST).
| Name | Type | Default | Required | Description |
|---|---|---|---|---|
ctx | context.Context | yes | Context of the call: cancellation and deadline. | |
id | string | yes | Identifier (UUID) of the knowledge base. | |
body | any | yes | Query text and search options. | |
opts | ...CallOption | no | Per call options (query, idempotency key, traceparent, headers). |
Returns: (json.RawMessage, error). Decoded JSON answer of the operation "Query a knowledge base". The error is a typed error of the SDK, nil on success.
Raises: error, the typed errors of the transport (Errors).
KnowledgeService.SetAcl
SetAcl(ctx context.Context, id string, body any, opts ...CallOption) (json.RawMessage, error)
Replace the ACL of a knowledge base. Replaces the readers and writers of the knowledge base. With apply_to_documents, the documents that inherit the knowledge base ACL (no readers of their own) and their chunks get the new readers; documents_updated gives their number. Needs the ReBAC relation owner, and the caller must be tenant_admin, security_officer or the creator. Audited as knowledge_base.acl.update; the retrieval cache is invalidated.
Route: /v1/knowledge-bases/{kb_id}/acl (PUT).
| Name | Type | Default | Required | Description |
|---|---|---|---|---|
ctx | context.Context | yes | Context of the call: cancellation and deadline. | |
id | string | yes | Identifier (UUID) of the knowledge base. | |
body | any | yes | The new ACL. | |
opts | ...CallOption | no | Per call options (query, idempotency key, traceparent, headers). |
Returns: (json.RawMessage, error). Decoded JSON answer of the operation "Replace the ACL of a knowledge base". The error is a typed error of the SDK, nil on success.
Raises: error, the typed errors of the transport (Errors).
Class MemoryService
MemoryService groups the endpoints of: Agent memory.
MemoryService.Delete
Delete(ctx context.Context, id string, opts ...CallOption) error
Delete a memory item. Erases the content, the reference, the vector and the former versions of the item and marks it deleted. Allowed for a writer or owner of the item, or tenant_admin (else 403 not_permitted_acl). An item under legal hold answers 409 legal_hold (the refusal is audited); a non deletable item answers 409 conflict unless the caller is tenant_admin. 404 not_found. Audited as memory.delete.
Route: /v1/memory/{memory_id} (DELETE).
| Name | Type | Default | Required | Description |
|---|---|---|---|---|
ctx | context.Context | yes | Context of the call: cancellation and deadline. | |
id | string | yes | Identifier (UUID) of the memory item. | |
opts | ...CallOption | no | Per call options (query, idempotency key, traceparent, headers). |
Returns: error. Error of the call (a typed error of the SDK), nil on success.
Raises: error, the typed errors of the transport (Errors).
MemoryService.Get
Get(ctx context.Context, id string, opts ...CallOption) (json.RawMessage, error)
Get a memory item. Returns the item as a Memory Contract document with its history (former version numbers and dates). An expired item, or one the caller may not read by ACL or clearance, answers 404 not_found.
Route: /v1/memory/{memory_id} (GET).
| Name | Type | Default | Required | Description |
|---|---|---|---|---|
ctx | context.Context | yes | Context of the call: cancellation and deadline. | |
id | string | yes | Identifier (UUID) of the memory item. | |
opts | ...CallOption | no | Per call options (query, idempotency key, traceparent, headers). |
Returns: (json.RawMessage, error). Decoded JSON answer of the operation "Get a memory item". The error is a typed error of the SDK, nil on success.
Raises: error, the typed errors of the transport (Errors).
MemoryService.List
List(ctx context.Context, opts ...CallOption) (*Page, error)
List the memory items. Items the caller may read (listed in readers, classification within its clearance, not expired, not deleted), as Memory Contract documents, paginated with cursor.
Route: /v1/memory (GET).
| Name | Type | Default | Required | Description |
|---|---|---|---|---|
ctx | context.Context | yes | Context of the call: cancellation and deadline. | |
opts | ...CallOption | no | Per call options (query, idempotency key, traceparent, headers). |
Returns: (*Page, error). A Page: Page is one page of a cursor paginated collection {"items": [...], "next_cursor": "..."|null}. The error is a typed error of the SDK, nil on success.
Raises: error, the typed errors of the transport (Errors).
MemoryService.Search
Search(ctx context.Context, body any, opts ...CallOption) (json.RawMessage, error)
Search the memory. Scores the visible items (at most the 2000 most recently updated ones with content) and returns the best top_k with score, keyword_score and vector_score. keyword: share of query terms found; vector: cosine similarity with the query embedding (only items embedded with the current model); hybrid (default): half of each. Recalled content is screened for prompt injection; blocked items are dropped. The policy memory.search is evaluated. 400 invalid_request for an unknown mode. Audited as memory.search.
Route: /v1/memory/search (POST).
| Name | Type | Default | Required | Description |
|---|---|---|---|---|
ctx | context.Context | yes | Context of the call: cancellation and deadline. | |
body | any | yes | Query, optional scope and kind, number of results and mode. | |
opts | ...CallOption | no | Per call options (query, idempotency key, traceparent, headers). |
Returns: (json.RawMessage, error). Decoded JSON answer of the operation "Search the memory". The error is a typed error of the SDK, nil on success.
Raises: error, the typed errors of the transport (Errors).
MemoryService.Write
Write(ctx context.Context, body any, opts ...CallOption) (json.RawMessage, error)
Write a memory item. Creates an item, or a new version of memory_id (201, Memory Contract document). Steps: 1. kind and scope.type are checked (400 invalid_request); content or content_ref is required. 2. Personal data detection may raise the classification; a classification above the caller clearance answers 403 policy_denied; the policy memory.write is evaluated. 3. For an update, the caller must be a writer or owner (403 not_permitted_acl) before the content is sent to the embedding model. 4. The content is embedded and stored. A new item defaults to the caller as reader, writer and owner, and to the user scope of the caller. Audited as memory.create or memory.update.
Route: /v1/memory (POST).
| Name | Type | Default | Required | Description |
|---|---|---|---|---|
ctx | context.Context | yes | Context of the call: cancellation and deadline. | |
body | any | yes | The memory item to write. | |
opts | ...CallOption | no | Per call options (query, idempotency key, traceparent, headers). |
Returns: (json.RawMessage, error). Decoded JSON answer of the operation "Write a memory item". The error is a typed error of the SDK, nil on success.
Raises: error, the typed errors of the transport (Errors).
Class RetentionService
RetentionService groups the endpoints of: Retention policies, erasure and legal hold.
RetentionService.CreatePolicy
CreatePolicy(ctx context.Context, body any, opts ...CallOption) (json.RawMessage, error)
Create or update a retention policy. Sets the retention policy of one resource type, replacing the existing one. Needs tenant_admin, security_officer or data_steward. An unknown resource type or an action other than erase or archive answers 400 invalid_request. The policy takes effect at the next retention run. Writes the audit event retention.policy.upsert. Answers 201 with the policy.
Route: /v1/retention/policies (POST).
| Name | Type | Default | Required | Description |
|---|---|---|---|---|
ctx | context.Context | yes | Context of the call: cancellation and deadline. | |
body | any | yes | Resource type, lifetime and action of the policy. | |
opts | ...CallOption | no | Per call options (query, idempotency key, traceparent, headers). |
Returns: (json.RawMessage, error). Decoded JSON answer of the operation "Create or update a retention policy". The error is a typed error of the SDK, nil on success.
Raises: error, the typed errors of the transport (Errors).
RetentionService.Erase
Erase(ctx context.Context, body any, opts ...CallOption) (json.RawMessage, error)
Erase a data subject. Deletes the data held on one subject, in one transaction. Needs tenant_admin, security_officer or data_steward.
Route: /v1/retention/erase (POST).
| Name | Type | Default | Required | Description |
|---|---|---|---|---|
ctx | context.Context | yes | Context of the call: cancellation and deadline. | |
body | any | yes | Subject, scope and reason of the erasure. | |
opts | ...CallOption | no | Per call options (query, idempotency key, traceparent, headers). |
Returns: (json.RawMessage, error). Decoded JSON answer of the operation "Erase a data subject". The error is a typed error of the SDK, nil on success.
Raises: error, the typed errors of the transport (Errors).
RetentionService.LegalHold
LegalHold(ctx context.Context, body any, opts ...CallOption) (json.RawMessage, error)
Place or release a legal hold. Without hold_id, places a new hold on a subject (subject_id) or on one resource (resource_type and resource_id); reason is required (400 invalid_request otherwise). With hold_id, activates or releases that hold with active (404 not_found for an unknown hold).
Route: /v1/retention/legal-hold (POST).
| Name | Type | Default | Required | Description |
|---|---|---|---|---|
ctx | context.Context | yes | Context of the call: cancellation and deadline. | |
body | any | yes | New hold, or the identifier of a hold to activate or release. | |
opts | ...CallOption | no | Per call options (query, idempotency key, traceparent, headers). |
Returns: (json.RawMessage, error). Decoded JSON answer of the operation "Place or release a legal hold". The error is a typed error of the SDK, nil on success.
Raises: error, the typed errors of the transport (Errors).
RetentionService.ListPolicies
ListPolicies(ctx context.Context, opts ...CallOption) (*Page, error)
List the retention policies. Returns the retention policies of the tenant ordered by resource type in items, and the active legal holds in legal_holds. Open to any member of the tenant. next_cursor is always null.
Route: /v1/retention/policies (GET).
| Name | Type | Default | Required | Description |
|---|---|---|---|---|
ctx | context.Context | yes | Context of the call: cancellation and deadline. | |
opts | ...CallOption | no | Per call options (query, idempotency key, traceparent, headers). |
Returns: (*Page, error). A Page: Page is one page of a cursor paginated collection {"items": [...], "next_cursor": "..."|null}. The error is a typed error of the SDK, nil on success.
Raises: error, the typed errors of the transport (Errors).
RetentionService.Run
Run(ctx context.Context, body any, opts ...CallOption) (json.RawMessage, error)
Run the retention policies. Applies the enabled policies now, to every resource type or to resource_types. Memory items and media past their own expiry are purged even without a policy; realtime transcripts and recordings follow the retention period of the participant consent. Items under legal hold are skipped.
Route: /v1/retention/run (POST).
| Name | Type | Default | Required | Description |
|---|---|---|---|---|
ctx | context.Context | yes | Context of the call: cancellation and deadline. | |
body | any | yes | Optional simulation flag and resource types. An empty body runs every policy for real. | |
opts | ...CallOption | no | Per call options (query, idempotency key, traceparent, headers). |
Returns: (json.RawMessage, error). Decoded JSON answer of the operation "Run the retention policies". The error is a typed error of the SDK, nil on success.
Raises: error, the typed errors of the transport (Errors).
Class LineageService
LineageService groups the endpoints of: OpenLineage events and graph.
LineageService.Dataset
Dataset(ctx context.Context, id string, opts ...CallOption) (json.RawMessage, error)
Get the lineage of a dataset. Returns the dataset node, the jobs that produce it (produced_by), the jobs that consume it (consumed_by) and its upstream and downstream graphs up to depth hops. Open to any member of the tenant. Answers 404 not_found for an unknown dataset.
Route: /v1/lineage/datasets/{dataset_id} (GET).
| Name | Type | Default | Required | Description |
|---|---|---|---|---|
ctx | context.Context | yes | Context of the call: cancellation and deadline. | |
id | string | yes | Dataset key, dataset:<namespace>:<name> or <namespace>:<name> (the prefix is added), URL encoded. | |
opts | ...CallOption | no | Per call options (query, idempotency key, traceparent, headers). |
Returns: (json.RawMessage, error). Decoded JSON answer of the operation "Get the lineage of a dataset". The error is a typed error of the SDK, nil on success.
Raises: error, the typed errors of the transport (Errors).
LineageService.Emit
Emit(ctx context.Context, body any, opts ...CallOption) (json.RawMessage, error)
Send OpenLineage events. Accepts one OpenLineage RunEvent or {"events": [RunEvent, ...]}, in one transaction. Each event needs run.runId and job.namespace and job.name; eventType is one of START, RUNNING, COMPLETE, ABORT, FAIL or OTHER (default; any other answers 400); eventTime defaults to the reception time.
Route: /v1/lineage/events (POST).
| Name | Type | Default | Required | Description |
|---|---|---|---|---|
ctx | context.Context | yes | Context of the call: cancellation and deadline. | |
body | any | yes | One OpenLineage RunEvent, or an object events holding a list of them. | |
opts | ...CallOption | no | Per call options (query, idempotency key, traceparent, headers). |
Returns: (json.RawMessage, error). Decoded JSON answer of the operation "Send OpenLineage events". The error is a typed error of the SDK, nil on success.
Raises: error, the typed errors of the transport (Errors).
LineageService.Graph
Graph(ctx context.Context, opts ...CallOption) (json.RawMessage, error)
Get the lineage graph. Returns nodes and edges. With node, the graph is walked from that node in direction up to depth hops (404 not_found for an unknown node). Without node, returns up to limit job and dataset nodes ordered by key, and the edges between them. A direction other than both, upstream or downstream answers 400 invalid_request. Open to any member of the tenant.
Route: /v1/lineage/graph (GET).
| Name | Type | Default | Required | Description |
|---|---|---|---|---|
ctx | context.Context | yes | Context of the call: cancellation and deadline. | |
opts | ...CallOption | no | Per call options (query, idempotency key, traceparent, headers). |
Returns: (json.RawMessage, error). Decoded JSON answer of the operation "Get the lineage graph". The error is a typed error of the SDK, nil on success.
Raises: error, the typed errors of the transport (Errors).
Class PromptsService
PromptsService groups the endpoints of: Prompt registry, versions and rendering.
PromptsService.Create
Create(ctx context.Context, body any, opts ...CallOption) (json.RawMessage, error)
Publish a prompt version. Creates a prompt, or publishes a new version when the name exists; identical templates and variables are not duplicated (the current version is returned). The name is lowercase letters, digits, ., _, - (1 to 128 characters, 400 invalid_request otherwise). An unbalanced placeholder, an unknown variable type or a placeholder not declared in variables answers 422 template_error. Needs tenant_admin or developer. Audited as prompt.publish.
Route: /v1/prompts (POST).
| Name | Type | Default | Required | Description |
|---|---|---|---|---|
ctx | context.Context | yes | Context of the call: cancellation and deadline. | |
body | any | yes | Name, template, description, variables and model hint. | |
opts | ...CallOption | no | Per call options (query, idempotency key, traceparent, headers). |
Returns: (json.RawMessage, error). Decoded JSON answer of the operation "Publish a prompt version". The error is a typed error of the SDK, nil on success.
Raises: error, the typed errors of the transport (Errors).
PromptsService.List
List(ctx context.Context, opts ...CallOption) (*Page, error)
List the prompts. Prompts of the tenant in name order with their latest version number, paginated with cursor.
Route: /v1/prompts (GET).
| Name | Type | Default | Required | Description |
|---|---|---|---|---|
ctx | context.Context | yes | Context of the call: cancellation and deadline. | |
opts | ...CallOption | no | Per call options (query, idempotency key, traceparent, headers). |
Returns: (*Page, error). A Page: Page is one page of a cursor paginated collection {"items": [...], "next_cursor": "..."|null}. The error is a typed error of the SDK, nil on success.
Raises: error, the typed errors of the transport (Errors).
PromptsService.Render
Render(ctx context.Context, name string, body any, opts ...CallOption) (json.RawMessage, error)
Render a prompt. Fills the template of a version (default: the latest) with the given values and returns text, chars and estimated_tokens (characters divided by 4). Missing required values, wrong types, values outside enum, values over max_length and, with strict, unknown variables answer 422 missing_variables with one entry per problem. 404 not_found for an unknown prompt or version. Nothing is stored.
Route: /v1/prompts/{name}/render (POST).
| Name | Type | Default | Required | Description |
|---|---|---|---|---|
ctx | context.Context | yes | Context of the call: cancellation and deadline. | |
name | string | yes | Name of the prompt. | |
body | any | yes | Values of the variables, version and strict mode. | |
opts | ...CallOption | no | Per call options (query, idempotency key, traceparent, headers). |
Returns: (json.RawMessage, error). Decoded JSON answer of the operation "Render a prompt". The error is a typed error of the SDK, nil on success.
Raises: error, the typed errors of the transport (Errors).
PromptsService.Versions
Versions(ctx context.Context, name string, opts ...CallOption) (*Page, error)
List the versions of a prompt. The prompt and every version, newest first, with template, variables, model hint, digest and author. 404 not_found.
Route: /v1/prompts/{name}/versions (GET).
| Name | Type | Default | Required | Description |
|---|---|---|---|---|
ctx | context.Context | yes | Context of the call: cancellation and deadline. | |
name | string | yes | Name of the prompt. | |
opts | ...CallOption | no | Per call options (query, idempotency key, traceparent, headers). |
Returns: (*Page, error). A Page: Page is one page of a cursor paginated collection {"items": [...], "next_cursor": "..."|null}. The error is a typed error of the SDK, nil on success.
Raises: error, the typed errors of the transport (Errors).
Class MediaService
MediaService groups the endpoints of: Media upload, scan and storage.
MediaService.Delete
Delete(ctx context.Context, id string, opts ...CallOption) error
Delete a media. Deletes the media and its stored content. Allowed for its creator, tenant_admin or security_officer (403 forbidden). A media under legal hold answers 409 legal_hold. Audited as media.delete.
Route: /v1/media/{media_id} (DELETE).
| Name | Type | Default | Required | Description |
|---|---|---|---|---|
ctx | context.Context | yes | Context of the call: cancellation and deadline. | |
id | string | yes | Identifier (UUID) of the media. | |
opts | ...CallOption | no | Per call options (query, idempotency key, traceparent, headers). |
Returns: error. Error of the call (a typed error of the SDK), nil on success.
Raises: error, the typed errors of the transport (Errors).
MediaService.Get
Get(ctx context.Context, id string, opts ...CallOption) (json.RawMessage, error)
Get a media. Returns the Multimodal Contract document of the media. With include_content=true the answer is {media, content_base64} with the decrypted content; this needs a clearance at least equal to the media classification (403 policy_denied) and is audited as media.read.
Route: /v1/media/{media_id} (GET).
| Name | Type | Default | Required | Description |
|---|---|---|---|---|
ctx | context.Context | yes | Context of the call: cancellation and deadline. | |
id | string | yes | Identifier (UUID) of the media. | |
opts | ...CallOption | no | Per call options (query, idempotency key, traceparent, headers). |
Returns: (json.RawMessage, error). Decoded JSON answer of the operation "Get a media". The error is a typed error of the SDK, nil on success.
Raises: error, the typed errors of the transport (Errors).
MediaService.Upload
Upload(ctx context.Context, body any, opts ...CallOption) (json.RawMessage, error)
Upload a media. Stores a media (201) from JSON {content_base64, mime_type, filename?, operation?, dlp_mode?, retention_days?, classification?} or multipart/form-data with a file part and the same fields. Any tenant principal may call it. Steps: 1. Size checked against the platform maximum (50 MiB unless configured; 413 media_too_large). 2. File scan by ClamAV and YARA-X (422 file_blocked, 503 file_scan_unavailable). 3. Text extraction and DLP with dlp_mode (default detect; block answers 422 dlp_blocked when personal data is found); the classification is raised accordingly. 4. The content is encrypted with a tenant key and stored. Returns the Multimodal Contract document.
Route: /v1/media (POST).
| Name | Type | Default | Required | Description |
|---|---|---|---|---|
ctx | context.Context | yes | Context of the call: cancellation and deadline. | |
body | any | yes | The file (JSON with base64 content, or multipart with a file part) and its options: operation the media is meant for, dlp_mode (detect, mask, tokenize, block), retention_days (0 or more), classification. | |
opts | ...CallOption | no | Per call options (query, idempotency key, traceparent, headers). |
Returns: (json.RawMessage, error). Decoded JSON answer of the operation "Upload a media". The error is a typed error of the SDK, nil on success.
Raises: error, the typed errors of the transport (Errors).
Class MultimodalService
MultimodalService groups the endpoints of: Vision, image, video, speech and multimodal DLP jobs.
MultimodalService.Diarize
Diarize(ctx context.Context, body any, opts ...CallOption) (json.RawMessage, error)
Diarize an audio. Starts a diarization job (who spoke when) on an audio media or inline audio (201, the job). Only min_speakers and max_speakers apply here (word_timestamps answers 422 parameter_unsupported); min_speakers must not exceed max_speakers (422 parameter_invalid); an option the configured provider cannot honour answers 422 parameter_unsupported. Needs tenant_admin, developer or agent.
Route: /v1/multimodal/diarize (POST).
| Name | Type | Default | Required | Description |
|---|---|---|---|---|
ctx | context.Context | yes | Context of the call: cancellation and deadline. | |
body | any | yes | Audio input and speaker bounds. | |
opts | ...CallOption | no | Per call options (query, idempotency key, traceparent, headers). |
Returns: (json.RawMessage, error). Decoded JSON answer of the operation "Diarize an audio". The error is a typed error of the SDK, nil on success.
Raises: error, the typed errors of the transport (Errors).
MultimodalService.Dlp
Dlp(ctx context.Context, body any, opts ...CallOption) (json.RawMessage, error)
Run the DLP on a text or a media. Inspects text, the extracted text of a stored media, or inline content (scanned first), with the tenant DLP rules. Returns source, extracted_text_chars, the processed text, findings, action and classification. Nothing is stored. Any tenant principal may call it. Audited as multimodal.dlp.
Route: /v1/multimodal/dlp (POST).
| Name | Type | Default | Required | Description |
|---|---|---|---|---|
ctx | context.Context | yes | Context of the call: cancellation and deadline. | |
body | any | yes | Text, stored media or inline content, and the DLP mode. | |
opts | ...CallOption | no | Per call options (query, idempotency key, traceparent, headers). |
Returns: (json.RawMessage, error). Decoded JSON answer of the operation "Run the DLP on a text or a media". The error is a typed error of the SDK, nil on success.
Raises: error, the typed errors of the transport (Errors).
MultimodalService.EditImage
EditImage(ctx context.Context, body any, opts ...CallOption) (json.RawMessage, error)
Edit an image. Starts an image edition job from an image media or inline image and a prompt (201, the job). The input must be an image (422 unsupported_media). Needs tenant_admin, developer or agent.
Route: /v1/multimodal/images/edit (POST).
| Name | Type | Default | Required | Description |
|---|---|---|---|---|
ctx | context.Context | yes | Context of the call: cancellation and deadline. | |
body | any | yes | Input image, prompt, number of images, size and model. | |
opts | ...CallOption | no | Per call options (query, idempotency key, traceparent, headers). |
Returns: (json.RawMessage, error). Decoded JSON answer of the operation "Edit an image". The error is a typed error of the SDK, nil on success.
Raises: error, the typed errors of the transport (Errors).
MultimodalService.GenerateImage
GenerateImage(ctx context.Context, body any, opts ...CallOption) (json.RawMessage, error)
Generate images. Starts an image generation job (201, the job). The prompt is inspected by the DLP in block mode first: personal data answers 422 dlp_blocked. Usage is counted per image. Needs tenant_admin, developer or agent.
Route: /v1/multimodal/images/generate (POST).
| Name | Type | Default | Required | Description |
|---|---|---|---|---|
ctx | context.Context | yes | Context of the call: cancellation and deadline. | |
body | any | yes | Prompt, number of images, size and model. | |
opts | ...CallOption | no | Per call options (query, idempotency key, traceparent, headers). |
Returns: (json.RawMessage, error). Decoded JSON answer of the operation "Generate images". The error is a typed error of the SDK, nil on success.
Raises: error, the typed errors of the transport (Errors).
MultimodalService.GenerateVideo
GenerateVideo(ctx context.Context, body any, opts ...CallOption) (json.RawMessage, error)
Generate a video. Starts a video generation job and answers 202 with the job; follow it with GET /v1/multimodal/jobs/{job_id}. Usage is counted in video seconds. Needs tenant_admin, developer or agent.
Route: /v1/multimodal/video/generate (POST).
| Name | Type | Default | Required | Description |
|---|---|---|---|---|
ctx | context.Context | yes | Context of the call: cancellation and deadline. | |
body | any | yes | Prompt, duration, size and model. | |
opts | ...CallOption | no | Per call options (query, idempotency key, traceparent, headers). |
Returns: (json.RawMessage, error). Decoded JSON answer of the operation "Generate a video". The error is a typed error of the SDK, nil on success.
Raises: error, the typed errors of the transport (Errors).
MultimodalService.Job
Job(ctx context.Context, id string, opts ...CallOption) (json.RawMessage, error)
Get a multimodal job. Returns the job: operation, status, input parameters, output, error, adapter, units and cost. 404 not_found.
Route: /v1/multimodal/jobs/{job_id} (GET).
| Name | Type | Default | Required | Description |
|---|---|---|---|---|
ctx | context.Context | yes | Context of the call: cancellation and deadline. | |
id | string | yes | Identifier (UUID) of the job. | |
opts | ...CallOption | no | Per call options (query, idempotency key, traceparent, headers). |
Returns: (json.RawMessage, error). Decoded JSON answer of the operation "Get a multimodal job". The error is a typed error of the SDK, nil on success.
Raises: error, the typed errors of the transport (Errors).
MultimodalService.Jobs
Jobs(ctx context.Context, opts ...CallOption) (*Page, error)
List the multimodal jobs. Jobs of the tenant, newest first, paginated with cursor, optionally filtered by status and operation.
Route: /v1/multimodal/jobs (GET).
| Name | Type | Default | Required | Description |
|---|---|---|---|---|
ctx | context.Context | yes | Context of the call: cancellation and deadline. | |
opts | ...CallOption | no | Per call options (query, idempotency key, traceparent, headers). |
Returns: (*Page, error). A Page: Page is one page of a cursor paginated collection {"items": [...], "next_cursor": "..."|null}. The error is a typed error of the SDK, nil on success.
Raises: error, the typed errors of the transport (Errors).
MultimodalService.ProcessVideo
ProcessVideo(ctx context.Context, body any, opts ...CallOption) (json.RawMessage, error)
Process a video. Extracts frames and/or the audio track of a video media or inline video (201, the job; queued when ffmpeg is not available). operations accepts frames and audio only (400 invalid_request). Needs tenant_admin, developer or agent.
Route: /v1/multimodal/video/process (POST).
| Name | Type | Default | Required | Description |
|---|---|---|---|---|
ctx | context.Context | yes | Context of the call: cancellation and deadline. | |
body | any | yes | Input video, operations, frame rate and audio sample rate. | |
opts | ...CallOption | no | Per call options (query, idempotency key, traceparent, headers). |
Returns: (json.RawMessage, error). Decoded JSON answer of the operation "Process a video". The error is a typed error of the SDK, nil on success.
Raises: error, the typed errors of the transport (Errors).
MultimodalService.Stt
Stt(ctx context.Context, body any, opts ...CallOption) (json.RawMessage, error)
Transcribe speech to text. Starts a speech to text job on an audio media or inline audio (201, the job). The transcript goes through the DLP with dlp_mode. Only word_timestamps applies here (speaker bounds answer 422 parameter_unsupported). Usage is counted in audio seconds (duration_seconds, or read from a WAV header). Needs tenant_admin, developer or agent.
Route: /v1/multimodal/stt (POST).
| Name | Type | Default | Required | Description |
|---|---|---|---|---|
ctx | context.Context | yes | Context of the call: cancellation and deadline. | |
body | any | yes | Audio input, language, model, DLP mode and options. | |
opts | ...CallOption | no | Per call options (query, idempotency key, traceparent, headers). |
Returns: (json.RawMessage, error). Decoded JSON answer of the operation "Transcribe speech to text". The error is a typed error of the SDK, nil on success.
Raises: error, the typed errors of the transport (Errors).
MultimodalService.Tts
Tts(ctx context.Context, body any, opts ...CallOption) (json.RawMessage, error)
Synthesize speech from text. Starts a text to speech job (201, the job). The text is inspected by the DLP with dlp_mode (default block: personal data answers 422 dlp_blocked; mask speaks the masked text). Usage is counted in characters. Needs tenant_admin, developer or agent.
Route: /v1/multimodal/tts (POST).
| Name | Type | Default | Required | Description |
|---|---|---|---|---|
ctx | context.Context | yes | Context of the call: cancellation and deadline. | |
body | any | yes | Text, voice, model and DLP mode. | |
opts | ...CallOption | no | Per call options (query, idempotency key, traceparent, headers). |
Returns: (json.RawMessage, error). Decoded JSON answer of the operation "Synthesize speech from text". The error is a typed error of the SDK, nil on success.
Raises: error, the typed errors of the transport (Errors).
MultimodalService.Vision
Vision(ctx context.Context, body any, opts ...CallOption) (json.RawMessage, error)
Understand an image. Starts a vision understanding job on an image media or inline image with a prompt (201, the job). The answer goes through the DLP with dlp_mode. detail answers 422 parameter_unsupported when the configured provider cannot honour it; a non image input answers 422 unsupported_media. Needs tenant_admin, developer or agent.
Route: /v1/multimodal/vision (POST).
| Name | Type | Default | Required | Description |
|---|---|---|---|---|
ctx | context.Context | yes | Context of the call: cancellation and deadline. | |
body | any | yes | Input image, prompt, model, DLP mode and detail level. | |
opts | ...CallOption | no | Per call options (query, idempotency key, traceparent, headers). |
Returns: (json.RawMessage, error). Decoded JSON answer of the operation "Understand an image". The error is a typed error of the SDK, nil on success.
Raises: error, the typed errors of the transport (Errors).
Class RealtimeService
RealtimeService groups the endpoints of: Realtime voice sessions (LiveKit) and WebSocket events.
RealtimeService.CreateSession
CreateSession(ctx context.Context, body any, opts ...CallOption) (json.RawMessage, error)
Open a realtime session. Opens a session (201) and returns it with session_id, livekit (url, token, room, configured) and the WebSocket access (ws_url, ws_token, ws_token_expires_at). Needs tenant_admin, developer or agent. Checks: pipeline is echo or stt (400 invalid_request); config.vad and config.dlp_mode are valid (422 parameter_invalid); an agent caller acts for on_behalf_of, a user may only open a session for itself (403 identity_mismatch); LiveKit credentials are configured; the policy realtime.session.create is evaluated. The room defaults to a name derived from the tenant and the session. Audited as realtime.session.create.
Route: /v1/realtime/sessions (POST).
| Name | Type | Default | Required | Description |
|---|---|---|---|---|
ctx | context.Context | yes | Context of the call: cancellation and deadline. | |
body | any | yes | Room, pipeline, token lifetime, configuration, agent and user acted for. | |
opts | ...CallOption | no | Per call options (query, idempotency key, traceparent, headers). |
Returns: (json.RawMessage, error). Decoded JSON answer of the operation "Open a realtime session". The error is a typed error of the SDK, nil on success.
Raises: error, the typed errors of the transport (Errors).
RealtimeService.EndSession
EndSession(ctx context.Context, id string, opts ...CallOption) (json.RawMessage, error)
End a realtime session. Ends the session and records its usage event (voice_live: audio seconds, input and output tokens, measured cost). Ending a session already ended returns it unchanged. Needs tenant_admin, developer or agent. Audited as realtime.session.end.
Route: /v1/realtime/sessions/{session_id}/end (POST).
| Name | Type | Default | Required | Description |
|---|---|---|---|---|
ctx | context.Context | yes | Context of the call: cancellation and deadline. | |
id | string | yes | Identifier (UUID) of the realtime session. | |
opts | ...CallOption | no | Per call options (query, idempotency key, traceparent, headers). |
Returns: (json.RawMessage, error). Decoded JSON answer of the operation "End a realtime session". The error is a typed error of the SDK, nil on success.
Raises: error, the typed errors of the transport (Errors).
Class EvaluationsService
EvaluationsService groups the endpoints of: Evaluation suites, runs and promotion gates.
EvaluationsService.CheckGate
CheckGate(ctx context.Context, body any, opts ...CallOption) (json.RawMessage, error)
Check the quality gate of a target. Checks that the latest finished run of every blocking suite of the target (for target.version when given, and limited to suite_ids when given) has passed. With run_missing: true, a suite without any run is run now; otherwise it counts as missing.
Route: /v1/evaluations/gates/check (POST).
| Name | Type | Default | Required | Description |
|---|---|---|---|---|
ctx | context.Context | yes | Context of the call: cancellation and deadline. | |
body | any | yes | Target, optional suites and whether to run missing suites. | |
opts | ...CallOption | no | Per call options (query, idempotency key, traceparent, headers). |
Returns: (json.RawMessage, error). Decoded JSON answer of the operation "Check the quality gate of a target". The error is a typed error of the SDK, nil on success.
Raises: error, the typed errors of the transport (Errors).
EvaluationsService.CreateRun
CreateRun(ctx context.Context, body any, opts ...CallOption) (json.RawMessage, error)
Run an evaluation suite. Runs a suite now and returns the finished run (201). Needs tenant_admin, developer, security_officer or ai_governance_officer or agent.
Route: /v1/evaluations/runs (POST).
| Name | Type | Default | Required | Description |
|---|---|---|---|---|
ctx | context.Context | yes | Context of the call: cancellation and deadline. | |
body | any | yes | Suite, optional target, precomputed outputs and trigger. | |
opts | ...CallOption | no | Per call options (query, idempotency key, traceparent, headers). |
Returns: (json.RawMessage, error). Decoded JSON answer of the operation "Run an evaluation suite". The error is a typed error of the SDK, nil on success.
Raises: error, the typed errors of the transport (Errors).
EvaluationsService.CreateSuite
CreateSuite(ctx context.Context, body any, opts ...CallOption) (json.RawMessage, error)
Create an evaluation suite. Creates a suite. Needs tenant_admin, developer, security_officer or ai_governance_officer. Errors 400 invalid_request: target type not in model, agent, prompt, rag_pipeline, skill or tool, unknown engine or kind, comparator other than gte or lte, or, for the custom engine, a metric other than exact_match, contains, not_contains, json_valid, faithfulness, latency or refusal. A name already used answers 409 conflict. The dataset gets its size and a SHA-256 digest of the cases. Writes the audit event evaluation.suite.create.
Route: /v1/evaluations/suites (POST).
| Name | Type | Default | Required | Description |
|---|---|---|---|---|
ctx | context.Context | yes | Context of the call: cancellation and deadline. | |
body | any | yes | Name, target, engine, kind, dataset, cases, metrics and gate options. | |
opts | ...CallOption | no | Per call options (query, idempotency key, traceparent, headers). |
Returns: (json.RawMessage, error). Decoded JSON answer of the operation "Create an evaluation suite". The error is a typed error of the SDK, nil on success.
Raises: error, the typed errors of the transport (Errors).
EvaluationsService.GetRun
GetRun(ctx context.Context, id string, opts ...CallOption) (json.RawMessage, error)
Get an evaluation run. Returns one evaluation run with its results per metric and per case. Open to any member of the tenant. Answers 404 not_found.
Route: /v1/evaluations/runs/{run_id} (GET).
| Name | Type | Default | Required | Description |
|---|---|---|---|---|
ctx | context.Context | yes | Context of the call: cancellation and deadline. | |
id | string | yes | Identifier (UUID) of the evaluation run. | |
opts | ...CallOption | no | Per call options (query, idempotency key, traceparent, headers). |
Returns: (json.RawMessage, error). Decoded JSON answer of the operation "Get an evaluation run". The error is a typed error of the SDK, nil on success.
Raises: error, the typed errors of the transport (Errors).
EvaluationsService.GetSuite
GetSuite(ctx context.Context, id string, opts ...CallOption) (json.RawMessage, error)
Get an evaluation suite. Returns one suite with its full list of cases and run_on_promotion. Open to any member of the tenant. Answers 404 not_found.
Route: /v1/evaluations/suites/{suite_id} (GET).
| Name | Type | Default | Required | Description |
|---|---|---|---|---|
ctx | context.Context | yes | Context of the call: cancellation and deadline. | |
id | string | yes | Identifier (UUID) of the suite. | |
opts | ...CallOption | no | Per call options (query, idempotency key, traceparent, headers). |
Returns: (json.RawMessage, error). Decoded JSON answer of the operation "Get an evaluation suite". The error is a typed error of the SDK, nil on success.
Raises: error, the typed errors of the transport (Errors).
EvaluationsService.ListRuns
ListRuns(ctx context.Context, opts ...CallOption) (*Page, error)
List the evaluation runs. Lists the evaluation runs of the tenant, newest identifier first, paginated, optionally filtered by suite and status. Each item follows the Evaluation Contract (target, engine, dataset, metrics, results, status, cost) with run_id, suite_id, trigger, case_results and error. Open to any member of the tenant.
Route: /v1/evaluations/runs (GET).
| Name | Type | Default | Required | Description |
|---|---|---|---|---|
ctx | context.Context | yes | Context of the call: cancellation and deadline. | |
opts | ...CallOption | no | Per call options (query, idempotency key, traceparent, headers). |
Returns: (*Page, error). A Page: Page is one page of a cursor paginated collection {"items": [...], "next_cursor": "..."|null}. The error is a typed error of the SDK, nil on success.
Raises: error, the typed errors of the transport (Errors).
EvaluationsService.ListSuites
ListSuites(ctx context.Context, opts ...CallOption) (*Page, error)
List the evaluation suites. Lists the suites of the tenant ordered by name, paginated, as Evaluation Contract documents; cases gives the number of cases. Open to any member of the tenant.
Route: /v1/evaluations/suites (GET).
| Name | Type | Default | Required | Description |
|---|---|---|---|---|
ctx | context.Context | yes | Context of the call: cancellation and deadline. | |
opts | ...CallOption | no | Per call options (query, idempotency key, traceparent, headers). |
Returns: (*Page, error). A Page: Page is one page of a cursor paginated collection {"items": [...], "next_cursor": "..."|null}. The error is a typed error of the SDK, nil on success.
Raises: error, the typed errors of the transport (Errors).
Class RedTeamService
RedTeamService groups the endpoints of: Red team runs.
RedTeamService.CreateRun
CreateRun(ctx context.Context, body any, opts ...CallOption) (json.RawMessage, error)
Run a red team campaign. Sends adversarial probes to the target and stores the findings. Needs tenant_admin, developer, security_officer or ai_governance_officer.
Route: /v1/redteam/runs (POST).
| Name | Type | Default | Required | Description |
|---|---|---|---|---|
ctx | context.Context | yes | Context of the call: cancellation and deadline. | |
body | any | yes | Target, engine, probes and accepted attack success rate. | |
opts | ...CallOption | no | Per call options (query, idempotency key, traceparent, headers). |
Returns: (json.RawMessage, error). Decoded JSON answer of the operation "Run a red team campaign". The error is a typed error of the SDK, nil on success.
Raises: error, the typed errors of the transport (Errors).
RedTeamService.GetRun
GetRun(ctx context.Context, id string, opts ...CallOption) (json.RawMessage, error)
Get a red team run. Returns one red team run: target, engine, probes, status, summary (total, vulnerable, attack success rate, threshold, per category) and findings. Open to any member of the tenant. Answers 404 not_found.
Route: /v1/redteam/runs/{run_id} (GET).
| Name | Type | Default | Required | Description |
|---|---|---|---|---|
ctx | context.Context | yes | Context of the call: cancellation and deadline. | |
id | string | yes | Identifier (UUID) of the red team run. | |
opts | ...CallOption | no | Per call options (query, idempotency key, traceparent, headers). |
Returns: (json.RawMessage, error). Decoded JSON answer of the operation "Get a red team run". The error is a typed error of the SDK, nil on success.
Raises: error, the typed errors of the transport (Errors).
RedTeamService.ListRuns
ListRuns(ctx context.Context, opts ...CallOption) (*Page, error)
List the red team runs. Lists the red team runs of the tenant, newest identifier first, paginated, and probes: the builtin probes (id and category), the garak probe families and whether garak is installed. Open to any member of the tenant.
Route: /v1/redteam/runs (GET).
| Name | Type | Default | Required | Description |
|---|---|---|---|---|
ctx | context.Context | yes | Context of the call: cancellation and deadline. | |
opts | ...CallOption | no | Per call options (query, idempotency key, traceparent, headers). |
Returns: (*Page, error). A Page: Page is one page of a cursor paginated collection {"items": [...], "next_cursor": "..."|null}. The error is a typed error of the SDK, nil on success.
Raises: error, the typed errors of the transport (Errors).
Class AuditService
AuditService groups the endpoints of: Hash chained audit trail, verification, export and correlations.
AuditService.Correlations
Correlations(ctx context.Context, opts ...CallOption) (json.RawMessage, error)
Correlate events by trace, run or session. With trace_id, run_id or session_id (the first given wins), returns everything that shares that key: audit_events, LLM usage_events, runs, telemetry spans, multimodal_jobs (up to 1000 of each, 200 for runs and jobs), the trace_ids met and counts.
Route: /v1/audit/correlations (GET).
| Name | Type | Default | Required | Description |
|---|---|---|---|---|
ctx | context.Context | yes | Context of the call: cancellation and deadline. | |
opts | ...CallOption | no | Per call options (query, idempotency key, traceparent, headers). |
Returns: (json.RawMessage, error). Decoded JSON answer of the operation "Correlate events by trace, run or session". The error is a typed error of the SDK, nil on success.
Raises: error, the typed errors of the transport (Errors).
AuditService.Event
Event(ctx context.Context, id string, opts ...CallOption) (json.RawMessage, error)
Get an audit event. Returns one audit event with its sequence, hashes, actor, resource, decision and evidence. Needs auditor, security_officer or tenant_admin. The read is recorded in the evidence access log. Answers 404 not_found.
Route: /v1/audit/events/{event_id} (GET).
| Name | Type | Default | Required | Description |
|---|---|---|---|---|
ctx | context.Context | yes | Context of the call: cancellation and deadline. | |
id | string | yes | Identifier (UUID) of the audit event. | |
opts | ...CallOption | no | Per call options (query, idempotency key, traceparent, headers). |
Returns: (json.RawMessage, error). Decoded JSON answer of the operation "Get an audit event". The error is a typed error of the SDK, nil on success.
Raises: error, the typed errors of the transport (Errors).
AuditService.Events
Events(ctx context.Context, opts ...CallOption) (*Page, error)
Search the audit events. Searches the audit events of the tenant, newest first (highest sequence first), paginated. All filters combine. Needs auditor, security_officer or tenant_admin. The search itself is recorded in the evidence access log (who, which query, how many results).
Route: /v1/audit/events (GET).
| Name | Type | Default | Required | Description |
|---|---|---|---|---|
ctx | context.Context | yes | Context of the call: cancellation and deadline. | |
opts | ...CallOption | no | Per call options (query, idempotency key, traceparent, headers). |
Returns: (*Page, error). A Page: Page is one page of a cursor paginated collection {"items": [...], "next_cursor": "..."|null}. The error is a typed error of the SDK, nil on success.
Raises: error, the typed errors of the transport (Errors).
AuditService.Export
Export(ctx context.Context, body any, opts ...CallOption) (json.RawMessage, error)
Export the audit trail. Writes the events of the period (bounds included) to write once storage, as NDJSON or CSV, with a manifest. Needs auditor, security_officer or tenant_admin.
Route: /v1/audit/export (POST).
| Name | Type | Default | Required | Description |
|---|---|---|---|---|
ctx | context.Context | yes | Context of the call: cancellation and deadline. | |
body | any | yes | Period, retention and format of the export. An empty body exports everything as NDJSON kept 365 days. | |
opts | ...CallOption | no | Per call options (query, idempotency key, traceparent, headers). |
Returns: (json.RawMessage, error). Decoded JSON answer of the operation "Export the audit trail". The error is a typed error of the SDK, nil on success.
Raises: error, the typed errors of the transport (Errors).
AuditService.Record
Record(ctx context.Context, body any, opts ...CallOption) (json.RawMessage, error)
Record an application audit event. Appends an application event to the tenant hash chain. The actor comes from the authentication; the sequence, the hashes and occurred_at from the server; the client details are kept under evidence.details.attributes, next to stream: sdk. The event is sealed and exported to the outbox and the SIEM like the platform events.
Route: /v1/audit/events (POST).
| Name | Type | Default | Required | Description |
|---|---|---|---|---|
ctx | context.Context | yes | Context of the call: cancellation and deadline. | |
body | any | yes | The application event. Fields other than those of the schema are refused. | |
opts | ...CallOption | no | Per call options (query, idempotency key, traceparent, headers). |
Returns: (json.RawMessage, error). Decoded JSON answer of the operation "Record an application audit event". The error is a typed error of the SDK, nil on success.
Raises: error, the typed errors of the transport (Errors).
AuditService.Verify
Verify(ctx context.Context, opts ...CallOption) (json.RawMessage, error)
Verify the audit chain. Recomputes the hash chain of the tenant from the first event and returns tenant_id, valid, count, last_hash, broken_at, reason and verified_at. When the chain is broken, broken_at is the sequence of the first faulty event and reason says why: sequence gap, prev_hash mismatch or hash mismatch. Needs auditor, security_officer or tenant_admin. The verification is recorded in the evidence access log.
Route: /v1/audit/verify (GET).
| Name | Type | Default | Required | Description |
|---|---|---|---|---|
ctx | context.Context | yes | Context of the call: cancellation and deadline. | |
opts | ...CallOption | no | Per call options (query, idempotency key, traceparent, headers). |
Returns: (json.RawMessage, error). Decoded JSON answer of the operation "Verify the audit chain". The error is a typed error of the SDK, nil on success.
Raises: error, the typed errors of the transport (Errors).
Class TelemetryService
TelemetryService groups the endpoints of: Telemetry spans, overview and traces.
TelemetryService.IngestSpans
IngestSpans(ctx context.Context, body any, opts ...CallOption) (json.RawMessage, error)
Ingest telemetry spans. Accepts up to 5000 spans and answers 202 with the number accepted, the number stored (a span already known for the same trace and span id is skipped) and the result of each exporter (ok or error). Requires a tenant principal with tenant_admin, developer or agent (403 forbidden).
Route: /v1/telemetry/spans (POST).
| Name | Type | Default | Required | Description |
|---|---|---|---|---|
ctx | context.Context | yes | Context of the call: cancellation and deadline. | |
body | any | yes | OTLP JSON export request (resourceSpans) or {spans: [...]} where each span has trace_id, span_id, optional parent_span_id, name, service, start_time, end_time (ISO 8601 or startTimeUnixNano / endTimeUnixNano), status, attributes, optional cost {amount, currency}, run_id and session_id. | |
opts | ...CallOption | no | Per call options (query, idempotency key, traceparent, headers). |
Returns: (json.RawMessage, error). Decoded JSON answer of the operation "Ingest telemetry spans". The error is a typed error of the SDK, nil on success.
Raises: error, the typed errors of the transport (Errors).
TelemetryService.Overview
Overview(ctx context.Context, opts ...CallOption) (json.RawMessage, error)
Read the telemetry overview. Dashboard of the tenant over the last days days: number of requests (root spans), errors, error rate, p50 and p95 latency in milliseconds, total cost, and per day requests, errors and cost (span costs plus the measured or estimated cost of the LLM usage events). Also says which exporters (Opik, OpenTelemetry, ClickHouse) are configured. The total cost is labelled USD. Requires a tenant principal (403 tenant_required).
Route: /v1/telemetry/overview (GET).
| Name | Type | Default | Required | Description |
|---|---|---|---|---|
ctx | context.Context | yes | Context of the call: cancellation and deadline. | |
opts | ...CallOption | no | Per call options (query, idempotency key, traceparent, headers). |
Returns: (json.RawMessage, error). Decoded JSON answer of the operation "Read the telemetry overview". The error is a typed error of the SDK, nil on success.
Raises: error, the typed errors of the transport (Errors).
TelemetryService.SLO
SLO(ctx context.Context, opts ...CallOption) (json.RawMessage, error)
Read the SLO error budgets. For each service, over the last window_minutes minutes: requests, errors (5xx), requests over the latency target, the latency target and where it comes from (database or settings), and for availability and latency the target, bad ratio, remaining budget and burn rate. Counts are those of the replica that answers. Requires platform_admin, tenant_admin, auditor, viewer or support_engineer (403 forbidden). A platform administrator reads the whole platform or one tenant; anyone else reads only its own tenant (403 slo_scope_forbidden for another one). A window outside 1 to EAI_SLO_RETENTION_MINUTES answers 422 slo_window_invalid. Each read is audited (telemetry.slo.read).
Route: /v1/telemetry/slo (GET).
| Name | Type | Default | Required | Description |
|---|---|---|---|---|
ctx | context.Context | yes | Context of the call: cancellation and deadline. | |
opts | ...CallOption | no | Per call options (query, idempotency key, traceparent, headers). |
Returns: (json.RawMessage, error). Decoded JSON answer of the operation "Read the SLO error budgets". The error is a typed error of the SDK, nil on success.
Raises: error, the typed errors of the transport (Errors).
TelemetryService.SetSLOTarget
SetSLOTarget(ctx context.Context, service string, body any, opts ...CallOption) (json.RawMessage, error)
Set the objectives of a service. Objectives of one platform service, written in the database where they override the EAI_SLO_* defaults for every replica within 30 seconds. Platform administrator only (403 forbidden). An unknown service answers 404 slo_service_unknown. The change, with the values before and after and the reason, is audited (telemetry.slo.target.update); the answer gives the stored objectives with their version.
Route: /v1/telemetry/slo/targets/{service} (PUT).
| Name | Type | Default | Required | Description |
|---|---|---|---|---|
ctx | context.Context | yes | Context of the call: cancellation and deadline. | |
service | string | yes | Service whose objectives are set: control_plane_api, model_gateway, tool_gateway or realtime. | |
body | any | yes | New availability and latency objectives of the service. | |
opts | ...CallOption | no | Per call options (query, idempotency key, traceparent, headers). |
Returns: (json.RawMessage, error). Decoded JSON answer of the operation "Set the objectives of a service". The error is a typed error of the SDK, nil on success.
Raises: error, the typed errors of the transport (Errors).
TelemetryService.Trace
Trace(ctx context.Context, traceID string, opts ...CallOption) (json.RawMessage, error)
Get one trace. Every span of the trace in start order (with cost when known), the span count, total duration in milliseconds, error count, the audit events that carry this trace id, and a link to the trace in Opik when Opik is configured. Requires a tenant principal (403 tenant_required). A malformed id answers 400 invalid_request; a trace without span nor audit event answers 404 not_found.
Route: /v1/telemetry/traces/{trace_id} (GET).
| Name | Type | Default | Required | Description |
|---|---|---|---|---|
ctx | context.Context | yes | Context of the call: cancellation and deadline. | |
traceID | string | yes | Trace identifier: 32 hexadecimal characters (W3C trace context), case insensitive. | |
opts | ...CallOption | no | Per call options (query, idempotency key, traceparent, headers). |
Returns: (json.RawMessage, error). Decoded JSON answer of the operation "Get one trace". The error is a typed error of the SDK, nil on success.
Raises: error, the typed errors of the transport (Errors).
Class FinOpsService
FinOpsService groups the endpoints of: FinOps: price cards, FX, usage, estimation, GPU allocation, reconciliation and alerts.
FinOpsService.Alerts
Alerts(ctx context.Context, opts ...CallOption) (json.RawMessage, error)
List the FinOps alerts. Budget, quota and billing variance alerts of the tenant, newest first, with their message in the language of the request. One page only. Requires a reader role and a tenant principal.
Route: /v1/finops/alerts (GET).
| Name | Type | Default | Required | Description |
|---|---|---|---|---|
ctx | context.Context | yes | Context of the call: cancellation and deadline. | |
opts | ...CallOption | no | Per call options (query, idempotency key, traceparent, headers). |
Returns: (json.RawMessage, error). Decoded JSON answer of the operation "List the FinOps alerts". The error is a typed error of the SDK, nil on success.
Raises: error, the typed errors of the transport (Errors).
FinOpsService.CreateAllocationPolicy
CreateAllocationPolicy(ctx context.Context, body any, opts ...CallOption) (json.RawMessage, error)
Create a GPU allocation policy. Creates a policy that prices the GPU samples of the matching deployments and answers 201. The most specific deployment pattern wins. Cost of one sample of s seconds at P watts: GPU s / 3600 * gpu_hourly_cost, energy P * s / 3600 / 1000 * energy_kwh_price * pue, storage storage_gb * storage_gb_month_price * (s / 3600) / 730, total multiplied by 1 + overhead_pct / 100. Audited. Requires platform_admin.
Route: /v1/finops/allocation-policies (POST).
| Name | Type | Default | Required | Description |
|---|---|---|---|---|
ctx | context.Context | yes | Context of the call: cancellation and deadline. | |
body | any | yes | The new allocation policy. | |
opts | ...CallOption | no | Per call options (query, idempotency key, traceparent, headers). |
Returns: (json.RawMessage, error). Decoded JSON answer of the operation "Create a GPU allocation policy". The error is a typed error of the SDK, nil on success.
Raises: error, the typed errors of the transport (Errors).
FinOpsService.CreatePriceCard
CreatePriceCard(ctx context.Context, body any, opts ...CallOption) (json.RawMessage, error)
Create a price card. Creates a price card for the tenant (or a global one for a platform administrator without tenant) and answers 201. The card in force for the same provider, model pattern, region and usage type is closed at the new start date; a card starting later in the new validity answers 409 conflict. Unknown price keys, negative prices or a card without any price answer 422 price_card_invalid. Audited. Requires finops or tenant_admin (platform_admin for a global card).
Route: /v1/finops/price-cards (POST).
| Name | Type | Default | Required | Description |
|---|---|---|---|---|
ctx | context.Context | yes | Context of the call: cancellation and deadline. | |
body | any | yes | The new price card. | |
opts | ...CallOption | no | Per call options (query, idempotency key, traceparent, headers). |
Returns: (json.RawMessage, error). Decoded JSON answer of the operation "Create a price card". The error is a typed error of the SDK, nil on success.
Raises: error, the typed errors of the transport (Errors).
FinOpsService.Estimate
Estimate(ctx context.Context, body any, opts ...CallOption) (json.RawMessage, error)
Estimate the cost of a call. Prices a planned call with the price card in force (most specific model pattern and region first), converts it to the tenant currency and checks it against the matching quotas, without reserving anything. Reasoning tokens are added according to the billing mode of the card. No card answers 404 price_card_not_found; a missing FX rate 422 fx_rate_missing. Requires a usage or reader role and a tenant principal.
Route: /v1/finops/estimate (POST).
| Name | Type | Default | Required | Description |
|---|---|---|---|---|
ctx | context.Context | yes | Context of the call: cancellation and deadline. | |
body | any | yes | The planned call to price. | |
opts | ...CallOption | no | Per call options (query, idempotency key, traceparent, headers). |
Returns: (json.RawMessage, error). Decoded JSON answer of the operation "Estimate the cost of a call". The error is a typed error of the SDK, nil on success.
Raises: error, the typed errors of the transport (Errors).
FinOpsService.FxRates
FxRates(ctx context.Context, opts ...CallOption) (json.RawMessage, error)
List the FX rates. Exchange rates (global ones and those of the tenant) by base, quote and newest date first, with their source. Requires a reader role.
Route: /v1/finops/fx-rates (GET).
| Name | Type | Default | Required | Description |
|---|---|---|---|---|
ctx | context.Context | yes | Context of the call: cancellation and deadline. | |
opts | ...CallOption | no | Per call options (query, idempotency key, traceparent, headers). |
Returns: (json.RawMessage, error). Decoded JSON answer of the operation "List the FX rates". The error is a typed error of the SDK, nil on success.
Raises: error, the typed errors of the transport (Errors).
FinOpsService.GetPriceCard
GetPriceCard(ctx context.Context, id string, opts ...CallOption) (json.RawMessage, error)
Get a price card. One price card with its prices, tiers, validity and status. Unknown id: 404 not_found. Requires a reader role.
Route: /v1/finops/price-cards/{card_id} (GET).
| Name | Type | Default | Required | Description |
|---|---|---|---|---|
ctx | context.Context | yes | Context of the call: cancellation and deadline. | |
id | string | yes | Identifier (UUID) of the price card. | |
opts | ...CallOption | no | Per call options (query, idempotency key, traceparent, headers). |
Returns: (json.RawMessage, error). Decoded JSON answer of the operation "Get a price card". The error is a typed error of the SDK, nil on success.
Raises: error, the typed errors of the transport (Errors).
FinOpsService.GpuAllocation
GpuAllocation(ctx context.Context, opts ...CallOption) (json.RawMessage, error)
Read the GPU cost allocation. Cost of the local GPU deployments over the window, computed from the GPU samples and the allocation policies, and shared between tenants in proportion to the GPU seconds of their usage events on each deployment. A tenant sees its own share; a platform administrator without tenant sees every tenant. Requires a reader role.
Route: /v1/finops/gpu/allocation (GET).
| Name | Type | Default | Required | Description |
|---|---|---|---|---|
ctx | context.Context | yes | Context of the call: cancellation and deadline. | |
opts | ...CallOption | no | Per call options (query, idempotency key, traceparent, headers). |
Returns: (json.RawMessage, error). Decoded JSON answer of the operation "Read the GPU cost allocation". The error is a typed error of the SDK, nil on success.
Raises: error, the typed errors of the transport (Errors).
FinOpsService.GpuSamples
GpuSamples(ctx context.Context, body any, opts ...CallOption) (json.RawMessage, error)
Ingest GPU samples. Stores GPU utilization samples (typically from DCGM), 1 to 10000 per call, used for the GPU cost allocation. One audit event per batch. Requires platform_admin.
Route: /v1/finops/gpu/samples (POST).
| Name | Type | Default | Required | Description |
|---|---|---|---|---|
ctx | context.Context | yes | Context of the call: cancellation and deadline. | |
body | any | yes | Batch of GPU samples. | |
opts | ...CallOption | no | Per call options (query, idempotency key, traceparent, headers). |
Returns: (json.RawMessage, error). Decoded JSON answer of the operation "Ingest GPU samples". The error is a typed error of the SDK, nil on success.
Raises: error, the typed errors of the transport (Errors).
FinOpsService.ImportReconciliation
ImportReconciliation(ctx context.Context, body any, opts ...CallOption) (json.RawMessage, error)
Import a billing export. Parses a billing export of a provider, converts every line to the tenant currency and stores it, then answers 201 with the import (line count, total, period). An export that cannot be read answers 422 import_invalid with the reason. Run the reconciliation afterwards. Audited. Requires finops or tenant_admin, and a tenant principal.
Route: /v1/finops/reconciliation/imports (POST).
| Name | Type | Default | Required | Description |
|---|---|---|---|---|
ctx | context.Context | yes | Context of the call: cancellation and deadline. | |
body | any | yes | The billing export and its format. | |
opts | ...CallOption | no | Per call options (query, idempotency key, traceparent, headers). |
Returns: (json.RawMessage, error). Decoded JSON answer of the operation "Import a billing export". The error is a typed error of the SDK, nil on success.
Raises: error, the typed errors of the transport (Errors).
FinOpsService.IngestUsage
IngestUsage(ctx context.Context, body any, opts ...CallOption) (json.RawMessage, error)
Ingest a usage event. Validates a Usage Event v1, prices it (measured cost in the tenant currency) and stores it; answers 201, or 200 with duplicate: true when the same event_id was already stored. An invalid event answers 422 usage_event_invalid with the errors; an event of another tenant 403 usage_tenant_mismatch. One audit event per call, never the payload. Requires finops, tenant_admin, agent or developer, and a tenant principal.
Route: /v1/finops/usage (POST).
| Name | Type | Default | Required | Description |
|---|---|---|---|---|
ctx | context.Context | yes | Context of the call: cancellation and deadline. | |
body | any | yes | One Usage Event v1 (event_id, tenant_id, occurred_at, usage_type, units, pricing, scope identifiers...), as defined by the contract. | |
opts | ...CallOption | no | Per call options (query, idempotency key, traceparent, headers). |
Returns: (json.RawMessage, error). Decoded JSON answer of the operation "Ingest a usage event". The error is a typed error of the SDK, nil on success.
Raises: error, the typed errors of the transport (Errors).
FinOpsService.IngestUsageBatch
IngestUsageBatch(ctx context.Context, body any, opts ...CallOption) (json.RawMessage, error)
Ingest usage events in batch. Ingests up to 1000 usage events, each in its own savepoint: the answer lists every event as created, duplicate or error (with code, message and details) and the counts. More than 1000 events answer 413 batch_too_large; a body without an events list 422 validation_error. One audit event per batch. Requires finops, tenant_admin, agent or developer, and a tenant principal.
Route: /v1/finops/usage/batch (POST).
| Name | Type | Default | Required | Description |
|---|---|---|---|---|
ctx | context.Context | yes | Context of the call: cancellation and deadline. | |
body | any | yes | {events: [...]}: a list of Usage Event v1 objects. | |
opts | ...CallOption | no | Per call options (query, idempotency key, traceparent, headers). |
Returns: (json.RawMessage, error). Decoded JSON answer of the operation "Ingest usage events in batch". The error is a typed error of the SDK, nil on success.
Raises: error, the typed errors of the transport (Errors).
FinOpsService.ListAllocationPolicies
ListAllocationPolicies(ctx context.Context, opts ...CallOption) (*Page, error)
List the GPU allocation policies. Policies that turn GPU samples into a cost (GPU hourly cost, energy, PUE, storage and overhead) per deployment pattern and GPU model. Requires a reader role.
Route: /v1/finops/allocation-policies (GET).
| Name | Type | Default | Required | Description |
|---|---|---|---|---|
ctx | context.Context | yes | Context of the call: cancellation and deadline. | |
opts | ...CallOption | no | Per call options (query, idempotency key, traceparent, headers). |
Returns: (*Page, error). A Page: Page is one page of a cursor paginated collection {"items": [...], "next_cursor": "..."|null}. The error is a typed error of the SDK, nil on success.
Raises: error, the typed errors of the transport (Errors).
FinOpsService.ListPriceCards
ListPriceCards(ctx context.Context, opts ...CallOption) (*Page, error)
List the price cards. Price cards visible to the caller (global and tenant ones), by provider, model pattern and start date. Only active cards unless include_retired or at is given. One page only. Requires a reader role.
Route: /v1/finops/price-cards (GET).
| Name | Type | Default | Required | Description |
|---|---|---|---|---|
ctx | context.Context | yes | Context of the call: cancellation and deadline. | |
opts | ...CallOption | no | Per call options (query, idempotency key, traceparent, headers). |
Returns: (*Page, error). A Page: Page is one page of a cursor paginated collection {"items": [...], "next_cursor": "..."|null}. The error is a typed error of the SDK, nil on success.
Raises: error, the typed errors of the transport (Errors).
FinOpsService.ListUsage
ListUsage(ctx context.Context, opts ...CallOption) (*Page, error)
List the usage events. Usage events of the tenant with their units and their estimated, measured and billed costs, filtered and paginated. Requires a reader role and a tenant principal.
Route: /v1/finops/usage (GET).
| Name | Type | Default | Required | Description |
|---|---|---|---|---|
ctx | context.Context | yes | Context of the call: cancellation and deadline. | |
opts | ...CallOption | no | Per call options (query, idempotency key, traceparent, headers). |
Returns: (*Page, error). A Page: Page is one page of a cursor paginated collection {"items": [...], "next_cursor": "..."|null}. The error is a typed error of the SDK, nil on success.
Raises: error, the typed errors of the transport (Errors).
FinOpsService.ReconciliationImports
ReconciliationImports(ctx context.Context, opts ...CallOption) (*Page, error)
List the billing imports. Billing exports imported by the tenant, with source, provider, file name, number of lines, total amount, currency and period. Requires a reader role and a tenant principal.
Route: /v1/finops/reconciliation/imports (GET).
| Name | Type | Default | Required | Description |
|---|---|---|---|---|
ctx | context.Context | yes | Context of the call: cancellation and deadline. | |
opts | ...CallOption | no | Per call options (query, idempotency key, traceparent, headers). |
Returns: (*Page, error). A Page: Page is one page of a cursor paginated collection {"items": [...], "next_cursor": "..."|null}. The error is a typed error of the SDK, nil on success.
Raises: error, the typed errors of the transport (Errors).
FinOpsService.ReconciliationReport
ReconciliationReport(ctx context.Context, opts ...CallOption) (json.RawMessage, error)
Read the reconciliation report. Measured against billed cost over the period, with the variance, the unmatched billing lines and the last 100 variance alerts. A from after to answers 422 validation_error. Requires a reader role and a tenant principal.
Route: /v1/finops/reconciliation/report (GET).
| Name | Type | Default | Required | Description |
|---|---|---|---|---|
ctx | context.Context | yes | Context of the call: cancellation and deadline. | |
opts | ...CallOption | no | Per call options (query, idempotency key, traceparent, headers). |
Returns: (json.RawMessage, error). Decoded JSON answer of the operation "Read the reconciliation report". The error is a typed error of the SDK, nil on success.
Raises: error, the typed errors of the transport (Errors).
FinOpsService.RetirePriceCard
RetirePriceCard(ctx context.Context, id string, opts ...CallOption) (json.RawMessage, error)
Retire a price card. Marks the card retired and ends its validity at at (default now) when it was still open after that date. Past usage keeps the price it was costed with. Unknown id: 404 not_found. Audited. Requires finops or tenant_admin.
Route: /v1/finops/price-cards/{card_id}/retire (POST).
| Name | Type | Default | Required | Description |
|---|---|---|---|---|
ctx | context.Context | yes | Context of the call: cancellation and deadline. | |
id | string | yes | Identifier (UUID) of the price card. | |
opts | ...CallOption | no | Per call options (query, idempotency key, traceparent, headers). |
Returns: (json.RawMessage, error). Decoded JSON answer of the operation "Retire a price card". The error is a typed error of the SDK, nil on success.
Raises: error, the typed errors of the transport (Errors).
FinOpsService.RunReconciliation
RunReconciliation(ctx context.Context, body any, opts ...CallOption) (json.RawMessage, error)
Run the billing reconciliation. Allocates the imported billed lines of the period to the usage events: a line with a provider_request_id goes to that event, other lines are split pro rata of the measured cost of the events of the same provider, model and day (evenly when nothing was measured); lines without candidate event are reported as unmatched. Variance alerts are raised over the tenant threshold. Audited. Requires finops or tenant_admin, and a tenant principal.
Route: /v1/finops/reconciliation/run (POST).
| Name | Type | Default | Required | Description |
|---|---|---|---|---|
ctx | context.Context | yes | Context of the call: cancellation and deadline. | |
body | any | yes | Period to reconcile; the body may be omitted. | |
opts | ...CallOption | no | Per call options (query, idempotency key, traceparent, headers). |
Returns: (json.RawMessage, error). Decoded JSON answer of the operation "Run the billing reconciliation". The error is a typed error of the SDK, nil on success.
Raises: error, the typed errors of the transport (Errors).
FinOpsService.SetFxRates
SetFxRates(ctx context.Context, body any, opts ...CallOption) (json.RawMessage, error)
Set FX rates. Adds or replaces 1 to 1000 exchange rates (same base, quote and date: replaced) for the tenant, or global rates for a platform administrator without tenant, and answers the number updated with the full list. Conversions go through USD as pivot when no direct rate exists. Audited. Requires finops or tenant_admin (platform_admin for global rates).
Route: /v1/finops/fx-rates (PUT).
| Name | Type | Default | Required | Description |
|---|---|---|---|---|
ctx | context.Context | yes | Context of the call: cancellation and deadline. | |
body | any | yes | The rates to store. | |
opts | ...CallOption | no | Per call options (query, idempotency key, traceparent, headers). |
Returns: (json.RawMessage, error). Decoded JSON answer of the operation "Set FX rates". The error is a typed error of the SDK, nil on success.
Raises: error, the typed errors of the transport (Errors).
FinOpsService.Summary
Summary(ctx context.Context, opts ...CallOption) (json.RawMessage, error)
Summarize the spend. Usage events of the tenant grouped by one dimension, per currency: number of events, tokens, GPU seconds, estimated, measured and billed amounts (billed is null when nothing was reconciled). An unknown grouping answers 400 finops_group_by_invalid. Requires a reader role and a tenant principal.
Route: /v1/finops/summary (GET).
| Name | Type | Default | Required | Description |
|---|---|---|---|---|
ctx | context.Context | yes | Context of the call: cancellation and deadline. | |
opts | ...CallOption | no | Per call options (query, idempotency key, traceparent, headers). |
Returns: (json.RawMessage, error). Decoded JSON answer of the operation "Summarize the spend". The error is a typed error of the SDK, nil on success.
Raises: error, the typed errors of the transport (Errors).
Class QuotasService
QuotasService groups the endpoints of: Quotas, reservations (reserve, commit, release) and usage.
QuotasService.Commit
Commit(ctx context.Context, id string, body any, opts ...CallOption) (json.RawMessage, error)
Commit a reservation. Replaces the reserved amount by the measured one on every quota window of the reservation and checks the alert thresholds. A closed reservation answers 409 reservation_closed; an unknown one 404 reservation_not_found. Audited. Requires finops, tenant_admin, agent or developer, and a tenant principal.
Route: /v1/quotas/{reservation_id}/commit (POST).
| Name | Type | Default | Required | Description |
|---|---|---|---|---|
ctx | context.Context | yes | Context of the call: cancellation and deadline. | |
id | string | yes | Identifier (UUID) of the reservation returned by POST /v1/quotas/reserve. | |
body | any | yes | Measured cost and tokens of the call. | |
opts | ...CallOption | no | Per call options (query, idempotency key, traceparent, headers). |
Returns: (json.RawMessage, error). Decoded JSON answer of the operation "Commit a reservation". The error is a typed error of the SDK, nil on success.
Raises: error, the typed errors of the transport (Errors).
QuotasService.Create
Create(ctx context.Context, body any, opts ...CallOption) (json.RawMessage, error)
Create a quota. Creates a quota of the tenant and answers 201. A cost or token limit is required, and scope_value is required unless scope_type is tenant (422 validation_error). Without currency, the tenant currency applies. Audited. Requires finops or tenant_admin, and a tenant principal.
Route: /v1/quotas (POST).
| Name | Type | Default | Required | Description |
|---|---|---|---|---|
ctx | context.Context | yes | Context of the call: cancellation and deadline. | |
body | any | yes | The new quota. | |
opts | ...CallOption | no | Per call options (query, idempotency key, traceparent, headers). |
Returns: (json.RawMessage, error). Decoded JSON answer of the operation "Create a quota". The error is a typed error of the SDK, nil on success.
Raises: error, the typed errors of the transport (Errors).
QuotasService.Delete
Delete(ctx context.Context, id string, opts ...CallOption) error
Delete a quota. Deletes a quota of the tenant and answers 204. Unknown id: 404 quota_not_found. Audited (finops.quota.delete). Requires finops or tenant_admin.
Route: /v1/quotas/{quota_id} (DELETE).
| Name | Type | Default | Required | Description |
|---|---|---|---|---|
ctx | context.Context | yes | Context of the call: cancellation and deadline. | |
id | string | yes | Identifier (UUID) of the quota. | |
opts | ...CallOption | no | Per call options (query, idempotency key, traceparent, headers). |
Returns: error. Error of the call (a typed error of the SDK), nil on success.
Raises: error, the typed errors of the transport (Errors).
QuotasService.List
List(ctx context.Context, opts ...CallOption) (*Page, error)
List the quotas. Quotas of the tenant by name, including those mirrored from the LLM projects (llm-project:...). One page only. Requires a reader role and a tenant principal.
Route: /v1/quotas (GET).
| Name | Type | Default | Required | Description |
|---|---|---|---|---|
ctx | context.Context | yes | Context of the call: cancellation and deadline. | |
opts | ...CallOption | no | Per call options (query, idempotency key, traceparent, headers). |
Returns: (*Page, error). A Page: Page is one page of a cursor paginated collection {"items": [...], "next_cursor": "..."|null}. The error is a typed error of the SDK, nil on success.
Raises: error, the typed errors of the transport (Errors).
QuotasService.Release
Release(ctx context.Context, id string, body any, opts ...CallOption) (json.RawMessage, error)
Release a reservation. Gives the reserved amount back to every quota window of the reservation without consuming anything (the call failed or was not made). A closed reservation answers 409 reservation_closed; an unknown one 404 reservation_not_found. Audited. Requires finops, tenant_admin, agent or developer, and a tenant principal.
Route: /v1/quotas/{reservation_id}/release (POST).
| Name | Type | Default | Required | Description |
|---|---|---|---|---|
ctx | context.Context | yes | Context of the call: cancellation and deadline. | |
id | string | yes | Identifier (UUID) of the reservation. | |
body | any | yes | Request body, serialized as JSON. | |
opts | ...CallOption | no | Per call options (query, idempotency key, traceparent, headers). |
Returns: (json.RawMessage, error). Decoded JSON answer of the operation "Release a reservation". The error is a typed error of the SDK, nil on success.
Raises: error, the typed errors of the transport (Errors).
QuotasService.Replace
Replace(ctx context.Context, id string, body any, opts ...CallOption) (json.RawMessage, error)
Replace a quota. Replaces every field of a quota (same rules as on creation; without currency, the current one is kept). Unknown id: 404 quota_not_found. Audited. Requires finops or tenant_admin, and a tenant principal.
Route: /v1/quotas/{quota_id} (PUT).
| Name | Type | Default | Required | Description |
|---|---|---|---|---|
ctx | context.Context | yes | Context of the call: cancellation and deadline. | |
id | string | yes | Identifier (UUID) of the quota. | |
body | any | yes | The complete quota. | |
opts | ...CallOption | no | Per call options (query, idempotency key, traceparent, headers). |
Returns: (json.RawMessage, error). Decoded JSON answer of the operation "Replace a quota". The error is a typed error of the SDK, nil on success.
Raises: error, the typed errors of the transport (Errors).
QuotasService.ReserveRaw
ReserveRaw(ctx context.Context, body any, opts ...CallOption) (json.RawMessage, error)
Reserve cost and tokens. Reserves an amount on every enabled quota matching the scope (tenant quotas always match; a user principal adds its own user scope) and answers 201 with the reservation, its items per quota and window, the soft quotas exceeded and its expiry. A hard quota that would be exceeded answers 429 quota_exceeded with Retry-After: 60, and nothing is reserved. Expired reservations are released first. Audited. Requires finops, tenant_admin, agent or developer, and a tenant principal.
Route: /v1/quotas/reserve (POST).
| Name | Type | Default | Required | Description |
|---|---|---|---|---|
ctx | context.Context | yes | Context of the call: cancellation and deadline. | |
body | any | yes | Amount, scope and lifetime of the reservation. | |
opts | ...CallOption | no | Per call options (query, idempotency key, traceparent, headers). |
Returns: (json.RawMessage, error). Decoded JSON answer of the operation "Reserve cost and tokens". The error is a typed error of the SDK, nil on success.
Raises: error, the typed errors of the transport (Errors).
QuotasService.Usage
Usage(ctx context.Context, opts ...CallOption) (json.RawMessage, error)
Read the quota consumption. Each quota of the tenant with its current window and the cost and tokens used and reserved in it. Run quotas need run to find their window. Requires a reader role and a tenant principal.
Route: /v1/quotas/usage (GET).
| Name | Type | Default | Required | Description |
|---|---|---|---|---|
ctx | context.Context | yes | Context of the call: cancellation and deadline. | |
opts | ...CallOption | no | Per call options (query, idempotency key, traceparent, headers). |
Returns: (json.RawMessage, error). Decoded JSON answer of the operation "Read the quota consumption". The error is a typed error of the SDK, nil on success.
Raises: error, the typed errors of the transport (Errors).