GET
/
organizations
/
{organization}
/
databases
/
{database}
/
deploy-requests
/
{number}
/
deployment
Get a deployment
curl --request GET \
  --url https://api.planetscale.com/v1/organizations/{organization}/databases/{database}/deploy-requests/{number}/deployment \
  --header 'Authorization: <api-key>'
{
  "id": "<string>",
  "auto_cutover": true,
  "auto_delete_branch": true,
  "created_at": "<string>",
  "cutover_at": "<string>",
  "cutover_expiring": true,
  "deploy_check_errors": "<string>",
  "finished_at": "<string>",
  "queued_at": "<string>",
  "ready_to_cutover_at": "<string>",
  "started_at": "<string>",
  "state": "pending",
  "submitted_at": "<string>",
  "updated_at": "<string>",
  "into_branch": "<string>",
  "deploy_request_number": 123,
  "deployable": true,
  "preceding_deployments": [
    {}
  ],
  "deploy_operations": [
    {
      "id": "<string>",
      "state": "pending",
      "keyspace_name": "<string>",
      "table_name": "<string>",
      "operation_name": "<string>",
      "eta_seconds": 123,
      "progress_percentage": 123,
      "deploy_error_docs_url": "<string>",
      "ddl_statement": "<string>",
      "syntax_highlighted_ddl": "<string>",
      "created_at": "<string>",
      "updated_at": "<string>",
      "throttled_at": "<string>",
      "can_drop_data": true,
      "table_locked": true,
      "table_recently_used": true,
      "table_recently_used_at": "<string>",
      "removed_foreign_key_names": [
        "<string>"
      ],
      "deploy_errors": "<string>"
    }
  ],
  "deploy_operation_summaries": [
    {
      "id": "<string>",
      "created_at": "<string>",
      "deploy_errors": "<string>",
      "ddl_statement": "<string>",
      "eta_seconds": 123,
      "keyspace_name": "<string>",
      "operation_name": "<string>",
      "progress_percentage": 123,
      "state": "pending",
      "syntax_highlighted_ddl": "<string>",
      "table_name": "<string>",
      "table_recently_used_at": "<string>",
      "throttled_at": "<string>",
      "removed_foreign_key_names": [
        "<string>"
      ],
      "shard_count": 123,
      "shard_names": [
        "<string>"
      ],
      "can_drop_data": true,
      "table_recently_used": true,
      "sharded": true,
      "operations": [
        {
          "id": "<string>",
          "shard": "<string>",
          "state": "pending",
          "progress_percentage": 123,
          "eta_seconds": 123
        }
      ]
    }
  ],
  "lint_errors": [
    {}
  ],
  "sequential_diff_dependencies": [
    {}
  ],
  "lookup_vindex_operations": [
    {}
  ],
  "throttler_configurations": [
    {}
  ],
  "deployment_revert_request": {},
  "actor": {
    "id": "<string>",
    "display_name": "<string>",
    "avatar_url": "<string>"
  },
  "cutover_actor": {
    "id": "<string>",
    "display_name": "<string>",
    "avatar_url": "<string>"
  },
  "cancelled_actor": {
    "id": "<string>",
    "display_name": "<string>",
    "avatar_url": "<string>"
  },
  "schema_last_updated_at": "<string>",
  "table_locked": true,
  "locked_table_name": "<string>",
  "instant_ddl": true,
  "instant_ddl_eligible": true
}

Authorizations

Authorization
string
header
required

Path Parameters

organization
string
required

The name of the deploy request's organization

database
string
required

The name of the deploy request's database

number
string
required

The number of the deploy request

Response

Returns the deployment for a deploy request

id
string
required

The ID of the deployment

auto_cutover
boolean
required

Whether or not to automatically cutover once deployment is finished

auto_delete_branch
boolean
required

Whether or not to automatically delete the head branch once deployment is finished

created_at
string
required

When the deployment was created

cutover_at
string
required

When the cutover for the deployment was initiated

cutover_expiring
boolean
required

Whether or not the deployment cutover will expire soon

deploy_check_errors
string
required

Deploy check errors for the deployment

finished_at
string
required

When the deployment was finished

queued_at
string
required

When the deployment was queued

ready_to_cutover_at
string
required

When the deployment was ready for cutover

started_at
string
required

When the deployment was started

state
enum<string>
required

The state the deployment is in

Available options:
pending,
ready,
no_changes,
queued,
submitting,
in_progress,
pending_cutover,
in_progress_vschema,
in_progress_cancel,
in_progress_cutover,
complete,
complete_cancel,
complete_error,
complete_pending_revert,
in_progress_revert,
in_progress_revert_vschema,
complete_revert,
complete_revert_error,
cancelled,
error
submitted_at
string
required

When the deployment was submitted

updated_at
string
required

When the deployment was last updated

into_branch
string
required

The name of the base branch the deployment will be merged into

deploy_request_number
number
required

The number of the deploy request associated with this deployment

deployable
boolean
required

Whether the deployment is deployable

preceding_deployments
object[]
required

The deployments ahead of this one in the queue

deploy_operations
object[]
required
deploy_operation_summaries
object[]
required
lint_errors
object[]
required

Schema lint errors preventing the deployment from completing

sequential_diff_dependencies
object[]
required

The schema dependencies that must be satisfied

lookup_vindex_operations
object[]
required

Lookup Vitess index operations

throttler_configurations
object[]
required

Deployment throttling configurations

deployment_revert_request
object
required

The request to revert the schema operations in this deployment

actor
object
required
cutover_actor
object
required
cancelled_actor
object
required
schema_last_updated_at
string
required

When the schema was last updated for the deployment

table_locked
boolean
required

Whether or not the deployment has a table locked

locked_table_name
string
required

The name of he table that is locked by the deployment

instant_ddl
boolean
required

Whether or not the deployment is an instant DDL deployment

instant_ddl_eligible
boolean
required

Whether or not the deployment is eligible for instant DDL