Documentation menu

Preview template upgrade

GEThttps://api.instacloud.com/template-deployments/{deploymentId}/upgrade

Token scope: account · org · project — read-only tokens allowed.

What upgrading this deployment to the version the registry serves now would do: per-service field changes, which of them the upgrade writes and which it only reports, required variables with no value yet, and anything that makes the upgrade impossible. Each field row carries the label to show for it — render that label as given, because it is where a change states how far it reaches (public access on a storage service applies to that bucket on every branch). Reads only.

Parameters

NameInTypeRequiredDescription
deploymentIdpathstringyes

Responses

200

Default Response

FieldTypeRequiredDescription
planobjectyes
plan.from_versionstringyesthe version this instance was deployed from
plan.to_versionstringyesthe version the registry serves now
plan.to_digeststringyescontent digest of the manifest this plan was computed from, send it back as expected_digest so the apply cannot run a version nobody reviewed
plan.servicesobject[]yes
plan.services.keystringyesthe manifest key; stable across copies, where the platform name may be <key>-2
plan.services.service_idstring | nullno
plan.services.service_namestring | nullno
plan.services.gonebooleanyesthe deployment created it and the branch no longer has it: the user deleted it. Reported, never recreated
plan.services.addedbooleanyesthe new version introduces it; the upgrade creates it
plan.services.fieldsobject[]yeswhat the upgrade will write on this service. On an `added` service these are the values it will be CREATED with, so `deployed` and `live` are null and `drifted` is false; a field the manifest does not declare gets no row and takes the platform default
plan.services.fields.fieldstringyesthe `services` column this concerns — image, port, start_command, always_on, public, volume_gib (the new version adds a volume; it is attached at this plan's size) or volume_mount_path — so a client can deep-link to the setting
plan.services.fields.labelstringyeswhat to show for this row. Render it as given: it is where a field states how far its change reaches, e.g. public access on a storage bucket applies to that bucket on every branch
plan.services.fields.deployedstring | nullno
plan.services.fields.livestring | nullno
plan.services.fields.nextstring | nullno
plan.services.fields.driftedbooleanyesthe live value differs from what the deployment recorded: the user changed it after deploying
plan.services.fields.verdict"applied" | "refused"yesapplied: the upgrade writes it, which covers everything a manifest can declare for a service it keeps and for one it creates. refused: it cannot be changed in place at all, and refuses the whole upgrade
plan.services.missing_variablesstring[]yes
plan.removedstring[]yes
plan.refusalsstring[]yes

404

Default Response

FieldTypeRequiredDescription
errorstringyes

409

code template_not_served: the registry no longer serves this template. code template_up_to_date: the instance already runs the content the registry publishes. code template_superseded: this instance already moved off this deployment — the message names the one to act on instead

FieldTypeRequiredDescription
errorstringyes
codestringnostable machine-readable reason, e.g. private_lane_disabled, private_lane_unavailable_in_region, public_access_closed, credential_change_in_progress

View as Markdown