Skip to main content
GET
/
v13
/
deployments
/
{idOrUrl}
getDeployment
import { Vercel } from "@vercel/sdk";

const vercel = new Vercel({
  bearerToken: "<YOUR_BEARER_TOKEN_HERE>",
});

async function run() {
  const result = await vercel.deployments.getDeployment({
    idOrUrl: "dpl_89qyp1cskzkLrVicDaZoDbjyHuDJ",
    withGitRepoInfo: "true",
    teamId: "team_1a2b3c4d5e6f7g8h9i0j1k2l",
    slug: "my-team-url-slug",
  });

  console.log(result);
}

run();
{
  "build": {
    "env": [
      "<string>"
    ]
  },
  "env": [
    "<string>"
  ],
  "inspectorUrl": "<string>",
  "isInConcurrentBuildsQueue": false,
  "isInSystemBuildsQueue": false,
  "projectSettings": {
    "nodeVersion": "24.x",
    "buildCommand": "<string>",
    "devCommand": "<string>",
    "framework": "blitzjs",
    "commandForIgnoringBuildStep": "<string>",
    "installCommand": "<string>",
    "outputDirectory": "<string>",
    "speedInsights": {
      "id": "<string>",
      "enabledAt": 123,
      "disabledAt": 123,
      "canceledAt": 123,
      "hasData": false,
      "paidAt": 123
    },
    "webAnalytics": {
      "id": "<string>",
      "disabledAt": 123,
      "canceledAt": 123,
      "enabledAt": 123,
      "hasData": true
    }
  },
  "aliasAssigned": true,
  "bootedAt": 123,
  "buildingAt": 123,
  "buildSkipped": false,
  "creator": {
    "uid": "96SnxkFiMyVKsK3pnoHfx3Hz",
    "username": "john-doe",
    "avatar": "<string>"
  },
  "public": false,
  "status": "QUEUED",
  "id": "dpl_89qyp1cskzkLrVicDaZoDbjyHuDJ",
  "createdAt": 1540257589405,
  "readyState": "READY",
  "name": "my-project",
  "type": "LAMBDAS",
  "meta": {},
  "regions": [
    "sfo1"
  ],
  "url": "my-instant-deployment-3ij3cxz9qr.now.sh",
  "version": 2,
  "projectId": "<string>",
  "plan": "pro",
  "createdIn": "<string>",
  "ownerId": "<string>",
  "routes": [
    {
      "src": "<string>",
      "dest": "<string>",
      "headers": {},
      "methods": [
        "<string>"
      ],
      "continue": false,
      "override": false,
      "caseSensitive": false,
      "check": false,
      "important": false,
      "status": 123,
      "has": [
        {
          "type": "host",
          "value": "<string>"
        }
      ],
      "missing": [
        {
          "type": "host",
          "value": "<string>"
        }
      ],
      "mitigate": {
        "action": "challenge"
      },
      "transforms": [
        {
          "type": "request.headers",
          "op": "append",
          "target": {
            "key": "<string>"
          },
          "args": "<string>",
          "env": [
            "<string>"
          ]
        }
      ],
      "env": [
        "<string>"
      ],
      "locale": {
        "redirect": {},
        "cookie": "<string>"
      },
      "middlewarePath": "<string>",
      "middlewareRawSrc": [
        "<string>"
      ],
      "middleware": 123,
      "respectOriginCacheControl": false
    }
  ],
  "aliasAssignedAt": 123,
  "alwaysRefuseToBuild": false,
  "buildArtifactUrls": [
    "<string>"
  ],
  "builds": [
    {
      "use": "<string>",
      "src": "<string>",
      "config": {}
    }
  ],
  "readyStateReason": "<string>",
  "integrations": {
    "status": "skipped",
    "startedAt": 123,
    "completedAt": 123,
    "skippedAt": 123,
    "skippedBy": "<string>"
  },
  "images": {
    "sizes": [
      123
    ],
    "qualities": [
      123
    ],
    "domains": [
      "<string>"
    ],
    "remotePatterns": [
      {
        "hostname": "<string>",
        "protocol": "http",
        "port": "<string>",
        "pathname": "<string>",
        "search": "<string>"
      }
    ],
    "localPatterns": [
      {
        "pathname": "<string>",
        "search": "<string>"
      }
    ],
    "minimumCacheTTL": 123,
    "formats": [
      "image/avif"
    ],
    "dangerouslyAllowSVG": false,
    "contentSecurityPolicy": "<string>",
    "contentDispositionType": "inline"
  },
  "alias": [],
  "buildContainerFinishedAt": 123,
  "initReadyAt": 123,
  "isFirstBranchDeployment": false,
  "lambdas": [
    {
      "id": "<string>",
      "output": [
        {
          "path": "<string>",
          "functionName": "<string>"
        }
      ],
      "createdAt": 123,
      "readyState": "BUILDING",
      "entrypoint": "<string>",
      "readyStateAt": 123
    }
  ],
  "ready": 123,
  "team": {
    "id": "<string>",
    "name": "<string>",
    "slug": "<string>",
    "avatar": "<string>"
  },
  "userAliases": [
    "sub1.example.com",
    "sub2.example.com"
  ],
  "previewCommentsEnabled": false,
  "ttyBuildLogs": false,
  "customEnvironment": {
    "id": "<string>",
    "slug": "<string>",
    "type": "production",
    "createdAt": 123,
    "updatedAt": 123,
    "description": "<string>",
    "branchMatcher": {
      "type": "endsWith",
      "pattern": "<string>"
    },
    "domains": [
      {
        "name": "<string>",
        "apexName": "<string>",
        "projectId": "<string>",
        "verified": false,
        "redirect": "<string>",
        "redirectStatusCode": 307,
        "gitBranch": "<string>",
        "customEnvironmentId": "<string>",
        "updatedAt": 123,
        "createdAt": 123,
        "verification": [
          {
            "type": "<string>",
            "domain": "<string>",
            "value": "<string>",
            "reason": "<string>"
          }
        ]
      }
    ],
    "currentDeploymentAliases": [
      "<string>"
    ]
  },
  "oomReport": "out-of-memory",
  "aliasWarning": {
    "code": "<string>",
    "message": "<string>",
    "link": "<string>",
    "action": "<string>"
  },
  "aliasError": null,
  "aliasFinal": "<string>",
  "autoAssignCustomDomains": false,
  "automaticAliases": [
    "<string>"
  ],
  "buildErrorAt": 123,
  "checksState": "registered",
  "checksConclusion": "succeeded",
  "deletedAt": 1540257589405,
  "defaultRoute": "<string>",
  "canceledAt": 123,
  "errorCode": "<string>",
  "errorLink": "<string>",
  "errorMessage": "<string>",
  "errorStep": "<string>",
  "passiveRegions": [
    "<string>"
  ],
  "gitSource": {
    "type": "github",
    "repoId": "<string>",
    "ref": "<string>",
    "sha": "<string>",
    "prId": 123
  },
  "manualProvisioning": {
    "state": "PENDING",
    "completedAt": 123
  },
  "originCacheRegion": "<string>",
  "nodeVersion": "24.x",
  "project": {
    "id": "<string>",
    "name": "<string>",
    "framework": "<string>"
  },
  "prebuilt": false,
  "readySubstate": "STAGED",
  "softDeletedByRetention": "true",
  "source": "cli",
  "target": null,
  "undeletedAt": 1540257589405,
  "userConfiguredDeploymentId": "abc123",
  "oidcTokenClaims": {
    "iss": "<string>",
    "sub": "<string>",
    "scope": "<string>",
    "aud": "<string>",
    "owner": "<string>",
    "owner_id": "<string>",
    "project": "<string>",
    "project_id": "<string>",
    "environment": "<string>",
    "plan": "<string>"
  },
  "connectBuildsEnabled": false,
  "connectConfigurationId": "<string>",
  "crons": [
    {
      "schedule": "<string>",
      "path": "<string>"
    }
  ],
  "functions": {},
  "monorepoManager": "<string>",
  "passiveConnectConfigurationId": "<string>",
  "gitRepo": {
    "namespace": "<string>",
    "projectId": 123,
    "type": "gitlab",
    "url": "<string>",
    "path": "<string>",
    "defaultBranch": "<string>",
    "name": "<string>",
    "private": false,
    "ownerType": "team"
  },
  "flags": {
    "definitions": {}
  },
  "microfrontends": {
    "defaultAppProjectName": "<string>",
    "groupIds": [
      "<string>"
    ],
    "isDefaultApp": false,
    "defaultRoute": "<string>"
  },
  "config": {
    "functionType": "standard",
    "functionMemoryType": "standard",
    "functionTimeout": 123,
    "secureComputePrimaryRegion": "<string>",
    "secureComputeFallbackRegion": "<string>",
    "version": 123,
    "isUsingActiveCPU": false,
    "resourceConfig": {
      "buildQueue": {
        "configuration": "SKIP_NAMESPACE_QUEUE"
      },
      "buildMachine": {
        "default": "enhanced",
        "purchaseType": "enhanced",
        "isDefaultBuildMachine": false,
        "cores": 123,
        "memory": 123
      },
      "elasticConcurrency": "TEAM_SETTING"
    }
  },
  "checks": {
    "deployment-alias": {
      "state": "succeeded",
      "startedAt": 123,
      "completedAt": 123
    }
  }
}

Authorizations

Authorization
string
header
required

Default authentication mechanism

Path Parameters

idOrUrl
string
required

The unique identifier or hostname of the deployment.

Example:

"dpl_89qyp1cskzkLrVicDaZoDbjyHuDJ"

Query Parameters

withGitRepoInfo
string

Whether to add in gitRepo information.

Example:

"true"

teamId
string

The Team identifier to perform the request on behalf of.

Example:

"team_1a2b3c4d5e6f7g8h9i0j1k2l"

slug
string

The Team slug to perform the request on behalf of.

Example:

"my-team-url-slug"

Response

The deployment including only public information The deployment including both public and private information

The deployment including both public and private information

build
object
required
env
string[]
required
inspectorUrl
string | null
required
isInConcurrentBuildsQueue
enum<boolean>
required
Available options:
true,
false
isInSystemBuildsQueue
enum<boolean>
required
Available options:
true,
false
projectSettings
object
required
aliasAssigned
enum<boolean>
required

A boolean that will be true when the aliases from the alias property were assigned successfully

Available options:
true,
false
Example:

true

bootedAt
number
required
buildingAt
number
required
buildSkipped
enum<boolean>
required
Available options:
true,
false
creator
object
required

Information about the deployment creator

public
enum<boolean>
required

A boolean representing if the deployment is public or not. By default this is false

Available options:
true,
false
Example:

false

status
enum<string>
required
Available options:
QUEUED,
BUILDING,
ERROR,
INITIALIZING,
READY,
CANCELED
id
string
required

A string holding the unique ID of the deployment

Example:

"dpl_89qyp1cskzkLrVicDaZoDbjyHuDJ"

createdAt
number
required

A number containing the date when the deployment was created in milliseconds

Example:

1540257589405

readyState
enum<string>
required

The state of the deployment depending on the process of deploying, or if it is ready or in an error state

Available options:
QUEUED,
BUILDING,
ERROR,
INITIALIZING,
READY,
CANCELED
Example:

"READY"

name
string
required

The name of the project associated with the deployment at the time that the deployment was created

Example:

"my-project"

type
enum<string>
required
Available options:
LAMBDAS
meta
object
required
regions
string[]
required

The regions the deployment exists in

Example:
["sfo1"]
url
string
required

A string with the unique URL of the deployment

Example:

"my-instant-deployment-3ij3cxz9qr.now.sh"

version
enum<number>
required

The platform version that was used to create the deployment.

Available options:
2
Example:

2

projectId
string
required
plan
enum<string>
required
Available options:
pro,
enterprise,
hobby
createdIn
string
required
ownerId
string
required
routes
object[] | null
required
aliasAssignedAt
alwaysRefuseToBuild
enum<boolean>
Available options:
true,
false
buildArtifactUrls
string[]
builds
object[]
readyStateReason
string
integrations
object
images
object
alias
string[]

A list of all the aliases (default aliases, staging aliases and production aliases) that were assigned upon deployment creation

Example:
[]
buildContainerFinishedAt
number

Since April 2025 it necessary for On-Demand Concurrency Minutes calculation

initReadyAt
number
isFirstBranchDeployment
enum<boolean>
Available options:
true,
false
lambdas
object[]
ready
number
team
object

The team that owns the deployment if any

userAliases
string[]

An array of domains that were provided by the user when creating the Deployment.

Example:
["sub1.example.com", "sub2.example.com"]
previewCommentsEnabled
enum<boolean>

Whether or not preview comments are enabled for the deployment

Available options:
true,
false
Example:

false

ttyBuildLogs
enum<boolean>
Available options:
true,
false
customEnvironment
object

If the deployment was created using a Custom Environment, then this property contains information regarding the environment used.

oomReport
enum<string>
Available options:
out-of-memory
aliasWarning
object
aliasError
object

An object that will contain a code and a message when the aliasing fails, otherwise the value will be null

Example:

null

aliasFinal
string | null
autoAssignCustomDomains
enum<boolean>

applies to custom domains only, defaults to true

Available options:
true,
false
automaticAliases
string[]
buildErrorAt
number
checksState
enum<string>
Available options:
registered,
running,
completed
checksConclusion
enum<string>
Available options:
succeeded,
failed,
skipped,
canceled
deletedAt
number | null

A number containing the date when the deployment was deleted at milliseconds

Example:

1540257589405

defaultRoute
string

Computed field that is only available for deployments with a microfrontend configuration.

canceledAt
number
errorCode
string
errorMessage
string | null
errorStep
string
passiveRegions
string[]

Since November 2023 this field defines a set of regions that we will deploy the lambda to passively Lambdas will be deployed to these regions but only invoked if all of the primary regions are marked as out of service

gitSource
object
manualProvisioning
object

Present when deployment was created with VERCEL_MANUAL_PROVISIONING=true. The deployment stays in INITIALIZING until /continue is called.

originCacheRegion
string
nodeVersion
enum<string>

If set it overrides the projectSettings.nodeVersion for this deployment.

Available options:
24.x,
22.x,
20.x,
18.x,
16.x,
14.x,
12.x,
10.x,
8.10.x
project
object

The public project information associated with the deployment.

prebuilt
enum<boolean>
Available options:
true,
false
readySubstate
enum<string>

Substate of deployment when readyState is 'READY' Tracks whether or not deployment has seen production traffic: - STAGED: never seen production traffic - ROLLING: in the process of having production traffic gradually transitioned. - PROMOTED: has seen production traffic

Available options:
STAGED,
ROLLING,
PROMOTED
softDeletedByRetention
enum<boolean>

flag to indicate if the deployment was deleted by retention policy

Available options:
true,
false
Example:

"true"

source
enum<string>

Where was the deployment created from

Available options:
api-trigger-git-deploy,
cli,
clone/repo,
git,
import,
import/repo,
redeploy,
v0-web
Example:

"cli"

target
enum<string> | null

If defined, either staging if a staging alias in the format <project>.<team>.now.sh was assigned upon creation, or production if the aliases from alias were assigned. null value indicates the "preview" deployment.

Available options:
staging,
production
Example:

null

undeletedAt
number

A number containing the date when the deployment was undeleted at milliseconds

Example:

1540257589405

userConfiguredDeploymentId
string

Since January 2025 User-configured deployment ID for skew protection with pre-built deployments. This is set when users configure a custom deploymentId in their next.config.js file. This allows Next.js to use skew protection even when deployments are pre-built outside of Vercel's build system.

Example:

"abc123"

oidcTokenClaims
object
connectBuildsEnabled
enum<boolean>
Available options:
true,
false
connectConfigurationId
string
crons
object[]
functions
object
monorepoManager
string | null
passiveConnectConfigurationId
string

Since November 2023 this field defines a Secure Compute network that will only be used to deploy passive lambdas to (as in passiveRegions)

gitRepo
object
flags
object

Flags defined in the Build Output API, used by this deployment. Primarily used by the Toolbar to know about the used flags.

microfrontends
object
config
object

Since February 2025 the configuration must include snapshot data at the time of deployment creation to capture properties for the /deployments/:id/config endpoint utilized for displaying Deployment Configuration on the frontend This is optional because older deployments may not have this data captured

checks
object