Skip to content

List deployments that need a pack service, or should lose theirs

View as Markdown
GET
/v1/system/deployments
curl --request GET \
--url 'https://example.com/v1/system/deployments?endpoint=missing&limit=25' \
--header 'Authorization: Bearer <token>'

Across tenants, oldest activatedAt first. endpoint=missing: deployments that need a pack service. Each is routed (the newest deployment with routes for some tool version or pack check), has no endpoint or a cleared one, and nothing about it is closing or suspended. endpoint=retire: deployments with an endpoint whose pack service should go, each with its reason. Name each service packServiceName(tenantId, deploymentId) (@kindgi/api). Takes system:deployments. Each entry carries the tenant’s id and nothing else of it.

endpoint
required
string
Allowed values: missing retire

missing: deployments that need a pack service. retire: deployments whose pack service should go.

cursor
string

Where the previous page ended: its nextCursor, as it came. A runtime that seals cursors takes one only for the same list, filters and caller, within a day; otherwise 400 bad-input, and the list starts again without it. Absent → first page.

limit
integer
default: 25 >= 1 <= 100

1..100. Default 25.

One page of deployments.

Media typeapplication/json
object
data
required
Array<object>

A deployment as whatever runs its pack service needs it: ids and the image, nothing of the tenant beyond its id. Name the service packServiceName(tenantId, deploymentId) (@kindgi/api). In the retire list, reason says why the service should go.

object
tenantId
required
string format: uuid
deploymentId
required
string
>= 1 characters
packId
required

The pack it deploys (the image index’s packId).

string
>= 1 characters
projectId

The deployment’s project, as a call routes in it: the one it named, else the tenant’s Default. Absent only when the tenant has no Default project.

string
imageRef
required

Digest-pinned, as registered: the pack service is created from exactly this.

string
imageDigest
required
string
/^sha256:[0-9a-f]{64}$/
artifactVersion
required
string
activatedAt
required
string format: date-time
reason

In the retire list only. superseded: newer deployments ship every tool version and check it does, so no new call reaches it. A tool call a step made on it still goes back to it when the step runs again, and fails closed (pack-endpoint-cleared) once its endpoint is cleared. tenant-closing, tenant-suspended: every deployment of the tenant, routed or not. project-suspended, pack-suspended: every deployment of the project, or this one.

string
Allowed values: superseded tenant-closing tenant-suspended project-suspended pack-suspended
nextCursor

Opaque cursor for the next page. Absent when hasMore: false.

string
hasMore
required
boolean
Example
{
"data": [
{
"reason": "superseded"
}
]
}

endpoint missing or neither missing nor retire; a limit out of range; a cursor refused.

Media typeapplication/json
object
error
required
object
code
required

Stable machine-readable discriminant. Values match domain error codes (see docs/API-ROUTE-CONVENTIONS.md §4.3).

string
message
required
string
details

Optional, kind-specific.

object
key
additional properties
any
requestId
required

Server-assigned request id; also echoed via X-Request-Id header.

string
Examplegenerated
{
"error": {
"code": "example",
"message": "example",
"details": {},
"requestId": "example"
}
}

Missing / malformed / expired / revoked bearer token.

Media typeapplication/json
object
error
required
object
code
required

Stable machine-readable discriminant. Values match domain error codes (see docs/API-ROUTE-CONVENTIONS.md §4.3).

string
message
required
string
details

Optional, kind-specific.

object
key
additional properties
any
requestId
required

Server-assigned request id; also echoed via X-Request-Id header.

string
Examplegenerated
{
"error": {
"code": "example",
"message": "example",
"details": {},
"requestId": "example"
}
}

A tenant’s key or session (system-principal-required), or a system key without system:deployments (system-scope-missing).

Media typeapplication/json
object
error
required
object
code
required

Stable machine-readable discriminant. Values match domain error codes (see docs/API-ROUTE-CONVENTIONS.md §4.3).

string
message
required
string
details

Optional, kind-specific.

object
key
additional properties
any
requestId
required

Server-assigned request id; also echoed via X-Request-Id header.

string
Examplegenerated
{
"error": {
"code": "example",
"message": "example",
"details": {},
"requestId": "example"
}
}

See also