Skip to content

Show where each name a deployment's pack declares is set

View as Markdown
GET
/v1/deployments/{deploymentId}/pack-env
curl --request GET \
--url https://example.com/v1/deployments/example/pack-env \
--header 'Authorization: Bearer <token>'

On a server that runs a pack service per deployment and gives it the env its pack declares: each declared name, where it’s set (the deployment’s project, then its org, then the tenant, at the env the server serves) and why it can’t be given, if it can’t. Never a value. A name set only as a secret can’t be given into the pack service’s environment yet: a tool reads it per call (ctx.secrets).

deploymentId
required
string
>= 1 characters

Deployment id assigned by the ledger at register time.

Where each declared name is set.

Media typeapplication/json

Where each name the deployment’s pack declares is set, at the env the server serves. Never a value.

object
envName
required

The env the values are read at (KINDGI_ENV).

string
data
required

Every declared name, required ones first, each list in name order.

Array<object>

One name the deployment’s pack declares: where it’s set, and why it can’t be given to the pack service, if it can’t (secretScope, for ambiguous only, names the secret’s scope). Each name is looked for at the deployment’s project, then its org, then the tenant (most specific wins); a tenant-wide deployment’s, at the tenant’s Default project. Never a value.

object
name
required
string
required
required
boolean
kind
required
One of:
string
Allowed values: env secret
scope
required
One of:

Where a value is set: the deployment’s project, the project’s org, or the tenant.

object
kind
required
string
Allowed values: project org tenant
id

The project’s or the org’s id. Absent for the tenant.

string
missing
required

Set nowhere, as a plain value or a secret (optional names too).

boolean
problem

Why it can’t be given to the pack service. ambiguous: set both as a secret and as a plain value (secretScope names the secret’s scope). secret-not-yet: set only as a secret, and the orchestrator didn’t ask for secret values (secrets=values); a tool reads it per call (ctx.secrets). missing: a required name set nowhere. unreadable: set as a secret, and it can’t be read for a reason the platform fixes, not the owner. Absent when it can be given, and for an optional name set nowhere. The owner’s check (GET /v1/deployments/{deploymentId}/pack-env) lists a name set only as a secret as kind: 'secret', with no problem.

string
Allowed values: ambiguous secret-not-yet missing unreadable
secretScope

Where a value is set: the deployment’s project, the project’s org, or the tenant.

object
kind
required
string
Allowed values: project org tenant
id

The project’s or the org’s id. Absent for the tenant.

string
problem

Why a deployment’s pack service can’t be given its declared environment, the first in this order: pack-env-ambiguous (a name is set both as a secret and as a plain value), pack-env-secret-not-yet (a name is set only as a secret, and its value wasn’t asked for), pack-env-missing (a required name is set nowhere), pack-env-secret-unreadable (a name’s secret is set, but it can’t be read for a reason the platform fixes, not the owner; only a read with secrets=values finds it, and only when there’s no other problem). A later runtime may add codes, so treat an unknown one as a reason not yet named.

string
Allowed values: pack-env-ambiguous pack-env-secret-not-yet pack-env-missing pack-env-secret-unreadable
Example
{
"data": [
{
"kind": "env",
"scope": {
"kind": "project"
},
"problem": "ambiguous",
"secretScope": {
"kind": "project"
}
}
],
"problem": "pack-env-ambiguous"
}

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"
}
}

No deployment with that id under this tenant, or one in a project the caller doesn’t read (deployment-not-found).

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"
}
}

The server’s pack services take their env from how they’re run, not from the env store (pack-env-not-served).

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