Skip to content

Builds (validate and deploy)

5 calls. Every request needs the Authorization header: see the overview.

GET /builds

The build history, newest first: await it for the first page, or iterate every build.

Who can call it: Admins and members, with an API key or a portal session. Try it in the API playground.

Query parameters

NameTypeRequiredDescription
namespacestring[]Namespace names (exact, case-sensitive), repeatable or comma-separated: ?namespace=a&namespace=b or ?namespace=a,b. At most 50. Ignored when listing one namespace’s builds.
outcomestringOnly builds that ended this way: Succeeded, Failed or Rejected (case-insensitive).
isDeploybooleanTrue: deploys only; false: validations only. Omitted: both.
cursorstringThe nextCursor of the previous page.
limitintegerHow many builds to return: 1 to 200, default 50.

Response: BuildRecordPage (200)

curl -X GET "https://api.maitento.com/builds" \
-H "Authorization: $MAITENTO_AUTH"
DELETE /builds/by-id/{id}

Deletes a build record (Tenant.Admin).

Who can call it: Tenant admins only, with an API key or a portal session. Try it in the API playground.

Path parameters

NameTypeRequiredDescription
iduuidyes

Response: no body (204)

curl -X DELETE "https://api.maitento.com/builds/by-id/<id>" \
-H "Authorization: $MAITENTO_AUTH"
GET /builds/by-id/{id}

One build: manifest, sources, log, what it deployed. Throws NotFoundError when there is none.

Who can call it: Admins and members, with an API key or a portal session. Try it in the API playground.

Path parameters

NameTypeRequiredDescription
iduuidyes

Response: BuildRecord (200)

curl -X GET "https://api.maitento.com/builds/by-id/<id>" \
-H "Authorization: $MAITENTO_AUTH"
PUT /namespaces/{namespaceName}/build

Compiles and deploys the project into the namespace (creating the namespace if needed): each changed definition gets a new version. Throws BuildFailedError when the sources do not compile (nothing is deployed). Never retried.

Who can call it: Admins and members, with an API key or a portal session. Try it in the API playground.

Path parameters

NameTypeRequiredDescription
namespaceNamestringyes

Request body: BuildRequest

FieldTypeRequiredDescription
isDeploybooleanyesTrue to deploy the definitions if the build succeeds; false only to validate them.
agentsBuildRequestItem[]yesAgent files (agents/).
capsulesBuildRequestItem[]yesCapsule files (capsules/).
connectorsBuildOpenApiAndMcpRequestyesConnector files (connectors/).
externalOperationsBuildOpenApiAndMcpRequestyesTool files (external-operations/).
interactionsBuildInteractionsRequestyesInteraction files (interactions/).
appsBuildRequestApp[]yesApps (apps/), one entry per app folder.
codePipelinesBuildRequestCodePipeline[]yesCode pipeline definitions (code-pipelines/), sent as JSON.
codePipelineHooksmap<string,BuildRequestApp> | nullOptional Cogniscript hooks for code pipelines (code-pipeline-hooks/), keyed by the pipeline’s name.
loomsBuildRequestItem[] | nullOptional named looms (looms/<name>.mtr).
resourceFilesResourceFileReferencesyesThe shared prompts and JSON files the other files read with @prompt and @json.

Response: BuildResponse (200)

curl -X PUT "https://api.maitento.com/namespaces/<namespaceName>/build" \
-H "Authorization: $MAITENTO_AUTH" \
-H "Content-Type: application/json" \
-d '{"isDeploy":false,"agents":[],"capsules":[],"connectors":{"openApi":[],"modelContextProtocol":[]},"externalOperations":{"openApi":[],"modelContextProtocol":[]},"interactions":{"oneShot":[],"roundRobin":[],"managed":[]},"apps":[],"codePipelines":[],"resourceFiles":{"prompts":[],"json":[]}}'
GET /namespaces/{namespaceName}/builds

The build history, newest first: await it for the first page, or iterate every build.

Who can call it: Admins and members, with an API key or a portal session. Try it in the API playground.

Path parameters

NameTypeRequiredDescription
namespaceNamestringyes

Query parameters

NameTypeRequiredDescription
namespacestring[]Namespace names (exact, case-sensitive), repeatable or comma-separated: ?namespace=a&namespace=b or ?namespace=a,b. At most 50. Ignored when listing one namespace’s builds.
outcomestringOnly builds that ended this way: Succeeded, Failed or Rejected (case-insensitive).
isDeploybooleanTrue: deploys only; false: validations only. Omitted: both.
cursorstringThe nextCursor of the previous page.
limitintegerHow many builds to return: 1 to 200, default 50.

Response: BuildRecordPage (200)

curl -X GET "https://api.maitento.com/namespaces/<namespaceName>/builds" \
-H "Authorization: $MAITENTO_AUTH"