Skip to content
Docs
Versions

Get a specific zone package version

Get a specific zone package version

client.Zones.Packages.Versions.Get(ctx, versionID, params) (*PackageVersion, error)
GET/zones/{zone_id}/packages/{package_id}/versions/{version_id}

Get a specific zone package version

ParametersExpand Collapse
versionID string
params ZonePackageVersionGetParams
ZoneID param.Field[string]

Path param

PackageID param.Field[string]

Path param

minLength1
maxLength70
XClientRequestID param.Field[string]optional

Header param: Unique request identifier specified by the originating caller and passed along by proxies.

formatuuid
ReturnsExpand Collapse
type PackageVersion struct{…}
ID string
CreatedAt Time
formatdate-time
ManifestSha string
Name string
OwnerType PackageVersionOwnerType
Accepts one of the following:
const PackageVersionOwnerTypePlatform PackageVersionOwnerType = "platform"
const PackageVersionOwnerTypeCustomer PackageVersionOwnerType = "customer"
Version int64
formatint32
ArchivedAt Timeoptional
formatdate-time
CreatedBy stringoptional
Description stringoptional
IconURL stringoptional
Inputs PackageInputBindingoptional

Input binding for a package.

schema constrains install-level inputs. bindings is a CEL expression that assembles the flat input map — static values are CEL literals, install-provided values are pkg.inputs.X references. Evaluated at provisioning time to produce the entities.inputs map for entity bindings.

Bindings stringoptional

CEL expression assembling the flat input map from static values and install-provided values (referenced via pkg.inputs.X).

Scope:

  • pkg.inputs — install-supplied values conforming to schema.
Schema PackageInputBindingSchemaoptional

A subset of JSON Schema 2020-12 used to describe package input and output shapes.

Supported keywords:

  • Structural: type, properties, required, items, additionalProperties
  • Annotations: title, description, default, readOnly, writeOnly
  • Constraints: pattern, minLength, maxLength, minimum, maximum, minItems, maxItems, enum, const, format

Intentionally unsupported (reject at release time rather than silently ignore):

  • Schema combinators: allOf, anyOf, oneOf, not
  • References: $ref, $dynamicRef
  • patternProperties, propertyNames, unevaluatedProperties
  • Custom vocabularies and $vocabulary

Dialect: JSON Schema 2020-12 (implied — authors do not include $schema).

AdditionalProperties anyoptional

Schema for properties not named in properties.

Const anyoptional

Constant allowed value.

Default anyoptional

Default value (annotation).

Description stringoptional

Human-readable description (annotation).

Enum []anyoptional

Enumerated allowed values.

Format stringoptional

Format hint (e.g., "uri", "uuid", "email", "date-time").

Items anyoptional

Schema for array items.

Maximum float64optional
MaxItems int64optional
MaxLength int64optional
Minimum float64optional
MinItems int64optional
MinLength int64optional
Pattern stringoptional
Properties anyoptional

Property schemas, keyed by property name.

ReadOnly booloptional

Read-only hint — server-populated, ignored on write.

Required []stringoptional

Names of required properties.

Title stringoptional

Human-readable title (annotation).

Type stringoptional

The type keyword in JSON Schema 2020-12.

Accepts one of the following:
const PackageInputBindingSchemaTypeObject PackageInputBindingSchemaType = "object"
const PackageInputBindingSchemaTypeArray PackageInputBindingSchemaType = "array"
const PackageInputBindingSchemaTypeString PackageInputBindingSchemaType = "string"
const PackageInputBindingSchemaTypeInteger PackageInputBindingSchemaType = "integer"
const PackageInputBindingSchemaTypeNumber PackageInputBindingSchemaType = "number"
const PackageInputBindingSchemaTypeBoolean PackageInputBindingSchemaType = "boolean"
const PackageInputBindingSchemaTypeNull PackageInputBindingSchemaType = "null"
WriteOnly booloptional

Write-only hint (passwords, secrets) — never returned on read.

Outputs PackageOutputBindingoptional

Output binding for a package.

schema describes the flat outputs surfaced on an install. bindings is a CEL expression — a map literal whose keys match schema.properties and whose values project fields out of the resolved entity graph. Evaluated after the provisioner has resolved all entities.

Bindings string

CEL expression source. Must evaluate to a map whose fields match schema.properties.

Scope: entities:

  • entities.inputs — the package's input values (merged with install inputs at provisioning time).
  • entities.<name> — resolved entities in the graph, each with href: string and outputs: map<string, dyn>.
Schema PackageOutputBindingSchema

A subset of JSON Schema 2020-12 used to describe package input and output shapes.

Supported keywords:

  • Structural: type, properties, required, items, additionalProperties
  • Annotations: title, description, default, readOnly, writeOnly
  • Constraints: pattern, minLength, maxLength, minimum, maximum, minItems, maxItems, enum, const, format

Intentionally unsupported (reject at release time rather than silently ignore):

  • Schema combinators: allOf, anyOf, oneOf, not
  • References: $ref, $dynamicRef
  • patternProperties, propertyNames, unevaluatedProperties
  • Custom vocabularies and $vocabulary

Dialect: JSON Schema 2020-12 (implied — authors do not include $schema).

AdditionalProperties anyoptional

Schema for properties not named in properties.

Const anyoptional

Constant allowed value.

Default anyoptional

Default value (annotation).

Description stringoptional

Human-readable description (annotation).

Enum []anyoptional

Enumerated allowed values.

Format stringoptional

Format hint (e.g., "uri", "uuid", "email", "date-time").

Items anyoptional

Schema for array items.

Maximum float64optional
MaxItems int64optional
MaxLength int64optional
Minimum float64optional
MinItems int64optional
MinLength int64optional
Pattern stringoptional
Properties anyoptional

Property schemas, keyed by property name.

ReadOnly booloptional

Read-only hint — server-populated, ignored on write.

Required []stringoptional

Names of required properties.

Title stringoptional

Human-readable title (annotation).

Type stringoptional

The type keyword in JSON Schema 2020-12.

Accepts one of the following:
const PackageOutputBindingSchemaTypeObject PackageOutputBindingSchemaType = "object"
const PackageOutputBindingSchemaTypeArray PackageOutputBindingSchemaType = "array"
const PackageOutputBindingSchemaTypeString PackageOutputBindingSchemaType = "string"
const PackageOutputBindingSchemaTypeInteger PackageOutputBindingSchemaType = "integer"
const PackageOutputBindingSchemaTypeNumber PackageOutputBindingSchemaType = "number"
const PackageOutputBindingSchemaTypeBoolean PackageOutputBindingSchemaType = "boolean"
const PackageOutputBindingSchemaTypeNull PackageOutputBindingSchemaType = "null"
WriteOnly booloptional

Write-only hint (passwords, secrets) — never returned on read.

Properties map[string, any]optional

Vocabulary-defined metadata properties, keyed by property URN.

Known properties are declared with their schemas; additional properties with custom URNs are permitted via Record<unknown>.

Each property carries x-subject-types indicating which entity types it applies to. Properties with draft/ in the URN are experimental and carry x-internal: true.

Tags []stringoptional

Get a specific zone package version

package main

import (
  "context"
  "fmt"

  "github.com/keycardai/keycard-go"
)

func main() {
  client := keycard.NewClient(

  )
  packageVersion, err := client.Zones.Packages.Versions.Get(
    context.TODO(),
    "version_id",
    keycard.ZonePackageVersionGetParams{
      ZoneID: "zone_id",
      PackageID: "lkfwmkifjr:4mtu9913w4",
    },
  )
  if err != nil {
    panic(err.Error())
  }
  fmt.Printf("%+v\n", packageVersion.ID)
}
{
  "id": "id",
  "created_at": "2019-12-27T18:11:19.117Z",
  "manifest_sha": "manifest_sha",
  "name": "name",
  "owner_type": "platform",
  "version": 0,
  "archived_at": "2019-12-27T18:11:19.117Z",
  "created_by": "created_by",
  "description": "description",
  "icon_url": "icon_url",
  "inputs": {
    "bindings": "bindings",
    "schema": {
      "additionalProperties": {},
      "const": {},
      "default": {},
      "description": "description",
      "enum": [
        {}
      ],
      "format": "format",
      "items": {},
      "maximum": 0,
      "maxItems": 0,
      "maxLength": 0,
      "minimum": 0,
      "minItems": 0,
      "minLength": 0,
      "pattern": "pattern",
      "properties": {},
      "readOnly": true,
      "required": [
        "string"
      ],
      "title": "title",
      "type": "object",
      "writeOnly": true
    }
  },
  "links": [
    {
      "href": "href",
      "rel": "rel",
      "properties": {
        "foo": "bar"
      },
      "titles": {
        "foo": "string"
      },
      "type": "type"
    }
  ],
  "outputs": {
    "bindings": "bindings",
    "schema": {
      "additionalProperties": {},
      "const": {},
      "default": {},
      "description": "description",
      "enum": [
        {}
      ],
      "format": "format",
      "items": {},
      "maximum": 0,
      "maxItems": 0,
      "maxLength": 0,
      "minimum": 0,
      "minItems": 0,
      "minLength": 0,
      "pattern": "pattern",
      "properties": {},
      "readOnly": true,
      "required": [
        "string"
      ],
      "title": "title",
      "type": "object",
      "writeOnly": true
    }
  },
  "properties": {
    "foo": "bar"
  },
  "tags": [
    "string"
  ]
}
Returns Examples
{
  "id": "id",
  "created_at": "2019-12-27T18:11:19.117Z",
  "manifest_sha": "manifest_sha",
  "name": "name",
  "owner_type": "platform",
  "version": 0,
  "archived_at": "2019-12-27T18:11:19.117Z",
  "created_by": "created_by",
  "description": "description",
  "icon_url": "icon_url",
  "inputs": {
    "bindings": "bindings",
    "schema": {
      "additionalProperties": {},
      "const": {},
      "default": {},
      "description": "description",
      "enum": [
        {}
      ],
      "format": "format",
      "items": {},
      "maximum": 0,
      "maxItems": 0,
      "maxLength": 0,
      "minimum": 0,
      "minItems": 0,
      "minLength": 0,
      "pattern": "pattern",
      "properties": {},
      "readOnly": true,
      "required": [
        "string"
      ],
      "title": "title",
      "type": "object",
      "writeOnly": true
    }
  },
  "links": [
    {
      "href": "href",
      "rel": "rel",
      "properties": {
        "foo": "bar"
      },
      "titles": {
        "foo": "string"
      },
      "type": "type"
    }
  ],
  "outputs": {
    "bindings": "bindings",
    "schema": {
      "additionalProperties": {},
      "const": {},
      "default": {},
      "description": "description",
      "enum": [
        {}
      ],
      "format": "format",
      "items": {},
      "maximum": 0,
      "maxItems": 0,
      "maxLength": 0,
      "minimum": 0,
      "minItems": 0,
      "minLength": 0,
      "pattern": "pattern",
      "properties": {},
      "readOnly": true,
      "required": [
        "string"
      ],
      "title": "title",
      "type": "object",
      "writeOnly": true
    }
  },
  "properties": {
    "foo": "bar"
  },
  "tags": [
    "string"
  ]
}