Deployments
The Deployments API allows you to configure and manage Pulumi Deployments, which enable you to execute Pulumi updates and other operations through the Pulumi Cloud. With this API, you can configure deployment settings for your stacks, trigger deployments, view deployment status and logs, and manage deployment execution.
See Pulumi Deployments for conceptual documentation and getting-started guides.
Get Deployments Status
/api/deployments/{deploymentId}/statusReturns the current execution status of a Pulumi Deployments run. This endpoint is used by self-hosted deployment agents running in agent pools to check whether a deployment is still active. Authenticated using an agent pool secret rather than a user access token.
Request Parameters
deploymentIdstring path requiredThe deployment identifier
Responses
Get Pulumi Deploy Executor
/api/deployments/executorStreams the Linux/AMD64 Pulumi Deployments executor binary to the requester. The executor is the component that runs inside a deployment container and executes the actual Pulumi operations. The binary is retrieved from the Docker image/filesystem and proxied through the service to control access. This API is for internal use by workflow runners and requires valid credentials.
Responses
Poll Deployments Queue
/api/deployments/pollPolls the Pulumi Deployments queue for available work to execute. This endpoint is used by self-hosted deployment agents running in agent pools to pick up queued deployment jobs. Returns 200 with the next available deployment’s workflow definition if work is available, or 204 No Content if the queue is empty. Agents should poll this endpoint repeatedly. Authenticated using an agent pool secret rather than a user access token.
Responses
jobTokenstring requiredAuthentication token for the workflow agent to make API calls to the Pulumi Service.oidcTokenstring requiredOIDC token for authenticating with cloud providers during workflow execution.typeSpecificIDstring requiredThe unique identifier specific to the workflow type. For deployments, this is the deployment ID. For insights scans, this is the account ID.deploymentIDstring optionalDeprecated: use typeSpecificID instead.jobIDstring requiredThe unique identifier for the workflow job.runIDstring requiredThe unique identifier for the workflow run.
List Org Deployments
/api/orgs/{orgName}/deploymentsReturns a paginated list of all Pulumi Deployments executions across an organization, filtered to only include deployments for stacks the requesting user has access to. The response includes each deployment’s ID, status, version, creation time, the requesting user, project and stack names, Pulumi operation type, job details, and associated update results. Use ‘page’ (minimum 1, default 1) and ‘pageSize’ (1-100, default 10) for pagination, ‘sort’ to specify the sort field, and ‘asc’ to control sort direction (default descending). The response also includes the total count of matching deployments.
Request Parameters
orgNamestring path requiredThe organization nameascboolean query optionalSort in ascending order when true (default false)pageinteger query optionalPage number (min 1, default 1)pageSizeinteger query optionalResults per page (1-100, default 10)sortstring query optionalField to sort results by
Responses
- The list of deployment snapshots
- ↳
idstring requiredUnique identifier for this deployment. - ↳
projectNamestring optionalProjectName is the name of the project. - ↳
createdstring requiredCreated defines when the Deployment was created. - ↳
stackNamestring optionalStackName is the name of the stack. - ↳
modifiedstring requiredCreated defines when the corresponding WorkflowRun was modified. - ↳
pausedboolean optionalPaused indicates whether or not deployments are paused for this program. - ↳
pulumiOperationenum requiredPulumiOperation is the operation that was performed.Values:update,preview,destroy,refresh,detect-drift,remediate-drift - ↳
statusenum requiredStatus is the current status of the workflow runID.Values:not-started,accepted,running,failed,succeeded,skipped - Updates
- ↳
versioninteger requiredVersion is the ordinal ID for the stack - The list of jobs in this deployment
- RequestedBy contains the user information about the user who created the Deployment
- ↳
initiatorstring optionalInitiator is the initiation source of the deployment. - The agent pool used for this deployment, if any
itemsPerPageinteger requiredThe number of items per pagetotalinteger requiredThe total number of deployments
Org Deployments Metadata
/api/orgs/{orgName}/deployments/metadataReturns metadata about the organization’s Pulumi Deployments state. The response includes the overall pause status, a list of individually paused stacks (as stack references like project/stack), the configured concurrency limit (maximum number of concurrent deployments), and deployment counts broken down by status (notStarted, accepted, running, failed, succeeded, skipped, and total). This endpoint is useful for monitoring deployment health and capacity across an organization.
Request Parameters
orgNamestring path requiredThe organization name
Responses
pausedboolean requiredPaused is true if all new deployments for this org are paused right now.concurrencyinteger requiredConcurrency is the number of concurrent deployments allowed for this org.- DeploymentCounts is the number of deployments with different statuses for this org.
- ↳
notStartedinteger requiredThe number of deployments that have not started. - ↳
acceptedinteger requiredThe number of deployments that have been accepted. - ↳
runninginteger requiredThe number of deployments currently running. - ↳
failedinteger requiredThe number of deployments that have failed. - ↳
succeededinteger requiredThe number of deployments that have succeeded. - ↳
skippedinteger requiredThe number of deployments that have been skipped. - ↳
totalinteger requiredThe total number of deployments.
Pause Org Deployments
/api/orgs/{orgName}/deployments/pausePauses all future Pulumi Deployments executions across an entire organization. While paused, new deployments can still be queued and currently executing deployments will continue to run to completion. However, queued deployments will not be picked up for execution until deployments are resumed. This provides a safety mechanism to temporarily halt all deployment activity across the organization, for example during maintenance windows or incident response. Requires organization administrator permissions. Use the ResumeOrgDeployments endpoint to resume processing.
Request Parameters
orgNamestring path requiredThe organization name
Responses
Resume Org Deployments
/api/orgs/{orgName}/deployments/resumeResumes Pulumi Deployments executions for an organization that was previously paused via PauseOrgDeployments. Any queued deployments that accumulated while the organization was paused will begin processing according to the organization’s concurrency limits. Requires organization administrator permissions.
Request Parameters
orgNamestring path requiredThe organization name
Responses
Get Usage Summary Deploy Compute
/api/orgs/{orgName}/deployments/summaryRetrieves a summary of Pulumi Deployments compute usage (deployment minutes) for an organization. The response provides aggregated deployment minute consumption over the specified time period. Use the ‘granularity’ parameter to control time bucketing (e.g. ‘daily’ or ‘hourly’), and either ’lookbackDays’ (number of days from the current date) or ’lookbackStart’ (a Unix timestamp) to define the reporting window. Returns 204 No Content if no usage data is available for the specified period.
Request Parameters
orgNamestring path requiredThe organization namegranularitystring query optionalTime granularity for the summary (e.g. ‘daily’, ‘hourly’)lookbackDaysinteger query optionalNumber of days to look back from the current datelookbackStartinteger query optionalStart of the lookback period (Unix timestamp)
Responses
- The list of resource count summaries
- ↳
yearinteger requiredThe 4-digit year. - ↳
monthinteger optionalThe month of the year. Ranges from 1 to 12. - ↳
dayinteger optionalThe day of month. Ranges from 1 to 31. - ↳
weekNumberinteger optionalThe week number in the year with Sunday marking the start of the week. Ranges from 0-53. - ↳
hourinteger optionalThe hour of the day. Ranges from 0 to 23. - ↳
resourcesinteger requiredThe RUM (total number of resources under management at a given time). Calculated by getting the average of the all the resources for the given time frame. - ↳
resourceHoursinteger requiredThe RHUM, which is the number of hours the resources under management have been running. Calculated by getting the sum of all the resources for the given time frame. 1 resource hour = 1 Pulumi credit.
Get Deploy Usage Report
/api/orgs/{orgName}/deployments/usagereportRetrieves raw deployment usage records for self-hosted Pulumi Cloud customers to self-report deployment consumption. Returns aggregated deployment usage records for the specified organization. The ’lookbackDays’ query parameter controls how far back in time to retrieve records. This endpoint is primarily used by self-hosted customers for usage reporting and billing reconciliation purposes.
Request Parameters
orgNamestring path requiredThe organization namelookbackDaysinteger query optionalNumber of days to look back
Responses
List Stack Deployments Handler V2
/api/stacks/{orgName}/{projectName}/{stackName}/deploymentsReturns a paginated list of Pulumi Deployments executions for a specific stack. The response includes each deployment’s ID, status, version, creation and modification timestamps, the requesting user, Pulumi operation type, job details with step-level progress, and associated stack update results. Use ‘page’ (minimum 1, default 1) and ‘pageSize’ (1-100, default 10) for pagination, ‘sort’ to specify the sort field, and ‘asc’ to control sort direction (default descending). The response also includes the total count of deployments for the stack.
Request Parameters
orgNamestring path requiredThe organization nameprojectNamestring path requiredThe project namestackNamestring path requiredThe stack nameascboolean query optionalSort in ascending order when true (default false)pageinteger query optionalPage number (min 1, default 1)pageSizeinteger query optionalResults per page (1-100, default 10)sortstring query optionalField to sort results by
Responses
- The list of deployment snapshots
- ↳
idstring requiredUnique identifier for this deployment. - ↳
projectNamestring optionalProjectName is the name of the project. - ↳
createdstring requiredCreated defines when the Deployment was created. - ↳
stackNamestring optionalStackName is the name of the stack. - ↳
modifiedstring requiredCreated defines when the corresponding WorkflowRun was modified. - ↳
pausedboolean optionalPaused indicates whether or not deployments are paused for this program. - ↳
pulumiOperationenum requiredPulumiOperation is the operation that was performed.Values:update,preview,destroy,refresh,detect-drift,remediate-drift - ↳
statusenum requiredStatus is the current status of the workflow runID.Values:not-started,accepted,running,failed,succeeded,skipped - Updates
- ↳
versioninteger requiredVersion is the ordinal ID for the stack - The list of jobs in this deployment
- RequestedBy contains the user information about the user who created the Deployment
- ↳
initiatorstring optionalInitiator is the initiation source of the deployment. - The agent pool used for this deployment, if any
itemsPerPageinteger requiredThe number of items per pagetotalinteger requiredThe total number of deployments
Create API Deployment Handler V2
/api/stacks/{orgName}/{projectName}/{stackName}/deploymentsInitiates a new Pulumi Deployments execution for a stack. Pulumi Deployments is a managed service that executes Pulumi operations (update, preview, refresh, or destroy) in a secure, hosted environment.
Important: The stack must already exist before a deployment can be created for it.
The operation field is required and accepts: update, preview, refresh, or destroy. Three usage modes are supported:
- Stack settings only: Send
{"operation": "update"}to use the stack’s saved deployment settings. - Merged settings: Include partial settings in the request body alongside
operation. WheninheritSettingsis true (the default), request settings are merged with saved stack settings, with request values taking precedence. - Request settings only: Set
inheritSettingsto false and provide all settings in the request body.
Settings include source context (git repo, branch, directory), operation context (environment variables, pre-run commands, OIDC configuration), executor context, GitHub integration settings, and cache options.
This is v2 with breaking changes from CreateAPIDeploymentHandler: inheritSettings defaults to true, and operation is a required top-level field and no longer valid as part of operationContext.
Request Parameters
orgNamestring path requiredThe organization nameprojectNamestring path requiredThe project namestackNamestring path requiredThe stack name
Request Body
operationenum optionalThe Pulumi operation to perform.Values:update,preview,destroy,refresh,detect-drift,remediate-drifttagstring optionalA tag to identify the deployment settings configuration.- The executor context defining the execution environment.
- The Docker image to use for the execution environment.
- ↳
executorRootPathstring optionalThe root path for the executor binary and working directory. inheritSettingsboolean optionalWhether this deployment should inherit the stack’s deployment settings. Defaults to true.- The source context defining where the source code is located.
- Git-based source context configuration.
- Mercurial-based source context configuration.
- Template-based source context configuration.
- GitHub-specific deployment settings
- ↳
repositorystring optionalThe GitHub repository in the format owner/repo. - ↳
deployCommitsboolean optionalWhether to automatically deploy commits pushed to the target branch. - ↳
previewPullRequestsboolean optionalWhether to automatically preview pull requests. - ↳
pullRequestTemplateboolean requiredWhether to use a pull request template for deployment previews. - ↳
deployPullRequestinteger optionalThe pull request number to deploy, if targeting a specific pull request. - ↳
pathsarray[string] optionalThe list of file paths to filter deployment triggers. - ↳
installationIdstring optionalThe GitHub App installation ID. - VCS provider settings
- ↳
repositorystring optionalThe VCS repository reference (format varies by provider) - ↳
deployCommitsboolean optionalWhether to deploy all commits to the default branch - ↳
pathsarray[string] optionalPaths within the repository that trigger deployments when changed - ↳
installationIdstring optionalVCS installation/integration ID linking to the VCS provider - ↳
pullRequestTemplateboolean optionalWhether to use pull request templates for deployment PRs - ↳
previewPullRequestsboolean optionalWhether to create preview deployments for pull requests - ↳
deployPullRequestinteger optionalSpecific pull request number to deploy (overrides automatic deployment) - ↳
providerstring required - The operation context defining pre-run and post-run commands and environment variables.
- The OIDC configuration for the operation.
- ↳
preRunCommandsarray[string] optionalOptional list of commands to run before Pulumi is invoked. - ↳
operationenum optionalThe Pulumi operation to perform (e.g. update, preview, destroy).Values:update,preview,destroy,refresh,detect-drift,remediate-drift - Environment variables to apply during execution.
- Options to specify or override default behavior.
- The deployment role to assume for the operation.
agentPoolIDstring optionalThe identifier of the agent pool to use for deployments.- Cache options for the deployment.
- ↳
enableboolean optionalWhether build caching should be enabled for deployments on this stack.
Responses
idstring requiredThe generated deployment identifier.consoleUrlstring requiredThe Pulumi Console URL for the deployment.versioninteger requiredThe numerical sequential version for the deployment.
Get Deployment
/api/stacks/{orgName}/{projectName}/{stackName}/deployments/{deploymentId}Retrieves detailed information about a specific Pulumi Deployments execution by its deployment ID. The response includes the deployment’s current status, creation and modification timestamps, version number, the user who requested the deployment, the Pulumi operation type (update, preview, refresh, or destroy), and detailed job information. Each job contains an array of steps with their individual statuses (not-started, running, succeeded, or failed), start times, and last update timestamps. The response also includes any associated stack update results with update IDs, versions, start/end times, and result status.
Request Parameters
orgNamestring path requiredThe organization nameprojectNamestring path requiredThe project namestackNamestring path requiredThe stack namedeploymentIdstring path requiredThe deployment identifier
Responses
idstring requiredUnique identifier for this deployment.createdstring requiredCreated defines when the Deployment was created.modifiedstring requiredCreated defines when the corresponding WorkflowRun was modified.statusenum requiredStatus is the current status of the workflow runID.Values:not-started,accepted,running,failed,succeeded,skippedversioninteger requiredVersion is the ordinal ID for the stack- RequestedBy contains the user information about the user who created the Deployment
- ↳
namestring requiredThe user’s display name. - ↳
githubLoginstring requiredThe user’s login name. - ↳
avatarUrlstring requiredThe URL of the user’s avatar image. - ↳
emailstring optionalIMPORTANT: The email address of the user is only included on a few admin-only APIs. For nearly all APIs that return a UserInfo object, this will not be provided. considered sensitive information. - Jobs make up all the Jobs of the Deployment. Omitted for deployments that have not started yet.
- ↳
statusenum requiredThe current status of the deployment job.Values:not-started,accepted,running,failed,succeeded,skipped - ↳
startedstring optionalThe timestamp when the job started. - ↳
lastUpdatedstring optionalThe timestamp when the job was last updated. - The list of steps in the deployment job.
latestVersioninteger requiredLatestVersion is the most recent version number for deployments for the given programID- Configuration contains the environment variables and source information for a deployment
- The list of environment variables for the deployment.
- The source configuration for the deployment.
initiatorstring optionalInitiator is the initiation source of the deployment.pulumiOperationenum optionalPulumiOperation is the operation that was performed. Omitted for historical deployments that predate this field.Values:update,preview,destroy,refresh,detect-drift,remediate-drift
Cancel Deployment
/api/stacks/{orgName}/{projectName}/{stackName}/deployments/{deploymentId}/cancelTerminates an in-progress Pulumi Deployments execution for a specific stack. If the deployment is currently running, it is stopped immediately. If the deployment is queued but has not yet started, it is removed from the queue.
Warning: Canceling a deployment is a dangerous action and may leave the stack in an inconsistent state if the deployment is canceled during the execution of a Pulumi operation.
Note that this serves two endpoints:
- /{orgName}/{projectName}/{stackName}/deployments/{deploymentId}/cancel
- /admin/deployments/{deploymentId}/cancel
The former requires that the requesting user has stack deployment create permissions. The latter requires that the requesting user is a site administrator.
Request Parameters
orgNamestring path requiredThe organization nameprojectNamestring path requiredThe project namestackNamestring path requiredThe stack namedeploymentIdstring path requiredThe deployment identifier
Responses
Get Deployment Logs
/api/stacks/{orgName}/{projectName}/{stackName}/deployments/{deploymentId}/logsRetrieves execution logs for a Pulumi Deployments run. Supports two retrieval modes: streaming mode and step mode. In streaming mode, omit job/step parameters and use the continuationToken to incrementally fetch logs from the beginning through completion. Each response includes a nextToken field; continue requesting with this token until nextToken is absent, indicating all logs have been retrieved. In step mode, specify job and step indices to retrieve logs for a specific step within a specific job, with offset and count parameters for pagination within that step’s logs. In step mode, count must be between 1 and 499 (default 100), and the response includes a nextOffset field for fetching subsequent pages. Log lines include timestamps and the log line content.
Note that this serves two endpoints:
- /{orgName}/{projectName}/{stackName}/deployments/{deploymentId}/logs
- /admin/deployments/{deploymentId}/logs
The former requires stack deployment read permissions. The latter requires site administrator privileges.
Request Parameters
orgNamestring path requiredThe organization nameprojectNamestring path requiredThe project namestackNamestring path requiredThe stack namedeploymentIdstring path requiredThe deployment identifiercontinuationTokenstring query optionalContinuation token for streaming logs; use nextToken from the previous response to fetch subsequent log entriescountinteger query optionalNumber of log lines to return (1-499, default 100)jobinteger query optionalZero-based job index to retrieve logs foroffsetinteger query optionalZero-based line offset within the step logsstepinteger query optionalZero-based step index within the specified job
Responses
Get Deployment Updates
/api/stacks/{orgName}/{projectName}/{stackName}/deployments/{deploymentId}/updatesRetrieves all stack updates (program updates) associated with a specific Pulumi Deployments execution. A single deployment may produce one or more stack updates depending on the operation performed. Each update in the response includes details such as the update ID, version, start and end times, result status, and resource changes. This is useful for correlating deployment executions with their resulting infrastructure changes.
Request Parameters
orgNamestring path requiredThe organization nameprojectNamestring path requiredThe project namestackNamestring path requiredThe stack namedeploymentIdstring path requiredThe deployment identifier
Responses
Clear Project Cache
/api/stacks/{orgName}/{projectName}/{stackName}/deployments/cacheClears all cached dependency and build artifacts associated with the project for Pulumi Deployments. The deployment cache stores dependencies and other artifacts between deployment runs to speed up execution. Use this endpoint to force a clean build on the next deployment, for example when cached dependencies become stale or corrupted.
Request Parameters
orgNamestring path requiredThe organization nameprojectNamestring path requiredThe project namestackNamestring path requiredThe stack name
Responses
Get Presigned Cache URL
/api/stacks/{orgName}/{projectName}/{stackName}/deployments/cache/urlReturns a presigned URL for saving or restoring the Pulumi Deployments dependency cache. The cache stores build artifacts and dependencies between deployment runs to speed up execution. The request body must specify a method (PUT to upload a cache archive, or GET to download one) and a non-empty cache key identifying the cached content. The returned presigned URL can be used directly for the corresponding HTTP operation against the object store without additional authentication.
Request Parameters
orgNamestring path requiredThe organization nameprojectNamestring path requiredThe project namestackNamestring path requiredThe stack name
Request Body
methodstring requiredS3 method of the presigned URLkeystring requiredThe key
Responses
Stack Deployments Metadata
/api/stacks/{orgName}/{projectName}/{stackName}/deployments/metadataReturns metadata about the Pulumi Deployments state for a specific stack. The response distinguishes the source of any pause:
paused: overall pause status (true if either stack or org is paused)stackPaused: whether the stack itself is pausedorganizationPaused: whether the containing organization is paused
This is useful for determining whether new deployments will be processed or held in the queue.
Request Parameters
orgNamestring path requiredThe organization nameprojectNamestring path requiredThe project namestackNamestring path requiredThe stack name
Responses
pausedboolean requiredPaused is true if new deployments for this stack right now would be paused. This could be due to a stack-level or org-level pause.stackPausedboolean requiredStackPaused is true if deployments for this stack specifically are paused.organizationPausedboolean requiredOrgPaused is true if all deployments are paused for the org.hasSchedulesboolean requiredHasSchedules is true if the stack has at least one schedule.- Drift contains the drift status of the stack and associated metadata
- ↳
driftDetectedboolean requiredWhether drift was detected in the latest run. - ↳
latestDriftRunstring requiredThe identifier of the latest drift detection run. - ↳
runInProgressboolean requiredWhether a drift detection run is currently in progress.
Pause Stack Deployments
/api/stacks/{orgName}/{projectName}/{stackName}/deployments/pausePauses all future Pulumi Deployments executions for a specific stack. While paused, new deployments can still be queued and currently executing deployments will continue to run to completion. However, queued deployments will not be picked up for execution until deployments are resumed. The stack must have deployment settings configured before it can be paused. Requires stack deployment create permissions. Use the ResumeStackDeployments endpoint to resume processing.
Request Parameters
orgNamestring path requiredThe organization nameprojectNamestring path requiredThe project namestackNamestring path requiredThe stack name
Responses
Resume Stack Deployments
/api/stacks/{orgName}/{projectName}/{stackName}/deployments/resumeResumes Pulumi Deployments executions for a stack that was previously paused via PauseStackDeployments. Any queued deployments that accumulated while the stack was paused will begin processing. The stack must have deployment settings configured. Requires stack deployment create permissions.
Request Parameters
orgNamestring path requiredThe organization nameprojectNamestring path requiredThe project namestackNamestring path requiredThe stack name
Responses
Get Deployment Settings
/api/stacks/{orgName}/{projectName}/{stackName}/deployments/settingsRetrieves the Pulumi Deployments configuration for a specified stack. The response includes all saved deployment settings: source context (git repository URL, branch, and directory), operation context (environment variables, pre-run commands, OIDC provider configuration), executor context (deployment executor configuration), GitHub integration settings (repository, paths, deployment triggers), and cache options for dependency caching between runs. These settings serve as the baseline configuration for deployments when inheritSettings is true on a deployment request. Returns 404 if the stack has no deployment settings configured.
Request Parameters
orgNamestring path requiredThe organization nameprojectNamestring path requiredThe project namestackNamestring path requiredThe stack name
Responses
versioninteger optionalThe version of the deployment settings.tagstring optionalA tag to identify the deployment settings configuration.- The executor context defining the execution environment.
- Defines the image that the pulumi operations should run in.
- ↳
executorRootPathstring optionalDefines the root path for the executor binary and working directory. - The source context defining where the source code is located.
- Git-based source context for obtaining source code from a repository.
- Mercurial-based source context for obtaining source code from a repository.
- Template-based source context for obtaining source code from a template URL.
- GitHub-specific deployment settings
- ↳
repositorystring optionalThe GitHub repository in the format owner/repo. - ↳
pullRequestTemplateboolean optionalWhether to use a pull request template for deployment previews. - ↳
deployCommitsboolean optionalWhether to automatically deploy commits pushed to the target branch. - ↳
previewPullRequestsboolean optionalWhether to automatically preview pull requests. - ↳
deployPullRequestinteger optionalThe pull request number to deploy, if targeting a specific pull request. - ↳
pathsarray[string] optionalThe list of file paths to filter deployment triggers. - ↳
installationIdstring optionalThe GitHub App installation ID. - VCS provider settings
- ↳
repositorystring optionalThe VCS repository reference (format varies by provider) - ↳
deployCommitsboolean optionalWhether to deploy all commits to the default branch - ↳
pathsarray[string] optionalPaths within the repository that trigger deployments when changed - ↳
installationIdstring optionalVCS installation/integration ID linking to the VCS provider - ↳
pullRequestTemplateboolean optionalWhether to use pull request templates for deployment PRs - ↳
previewPullRequestsboolean optionalWhether to create preview deployments for pull requests - ↳
deployPullRequestinteger optionalSpecific pull request number to deploy (overrides automatic deployment) - ↳
providerstring required - The operation context defining pre-run and post-run commands and environment variables.
- OIDC contains the OIDC configuration for the operation.
- ↳
preRunCommandsarray[string] optionalPreRunCommands is an optional list of arbitrary commands to run before Pulumi is invoked. ref: https://github.com/pulumi/pulumi/issues/9397 - ↳
operationenum optionalThe Pulumi operation to perform (e.g. update, preview, refresh, destroy).Values:update,preview,destroy,refresh,detect-drift,remediate-drift - EnvironmentVariables contains environment variables to be applied during the execution.
- Options is a bag of settings to specify or override default behavior
- Role defines the deployment role to assume for the operation.
sourceenum optionalThe source from which the deployment settings were created.Values:console,api,provider,github-review-stack,azure-devops-review-stack,gitlab-review-stack,bitbucket-review-stack,github-gitopsagentPoolIDstring optionalThe identifier of the agent pool to use for deployments.- Cache options for the deployment.
- ↳
enableboolean requiredWhether build caching is enabled for deployments on this stack.
Patch Deployment Settings
/api/stacks/{orgName}/{projectName}/{stackName}/deployments/settingsCreates or updates Pulumi Deployments settings for a stack using a merge operation. If no settings exist, they are created. If settings already exist, the request body is merged with the current settings using the following logic: for each property, start with the current value, remove it if the patch specifies null, or merge the new non-null value with the existing one. Non-object properties (strings, numbers, booleans) are replaced entirely. Settings include source context (git repository URL, branch, directory), operation context (environment variables, pre-run commands, OIDC configuration), executor context, GitHub integration settings, and cache options. Requires a Team Growth or higher subscription. Cannot be used to configure Pulumi Deployments for Terraform stacks.
Request Parameters
orgNamestring path requiredThe organization nameprojectNamestring path requiredThe project namestackNamestring path requiredThe stack name
Request Body
tagstring optionalA tag to identify the deployment settings configuration.- The executor context defining the execution environment.
- The Docker image to use for the execution environment.
- ↳
executorRootPathstring optionalThe root path for the executor binary and working directory. - The source context defining where the source code is located.
- Git-based source context configuration.
- Mercurial-based source context configuration.
- Template-based source context configuration.
- GitHub-specific deployment settings
- ↳
repositorystring optionalThe GitHub repository in the format owner/repo. - ↳
deployCommitsboolean optionalWhether to automatically deploy commits pushed to the target branch. - ↳
previewPullRequestsboolean optionalWhether to automatically preview pull requests. - ↳
pullRequestTemplateboolean requiredWhether to use a pull request template for deployment previews. - ↳
deployPullRequestinteger optionalThe pull request number to deploy, if targeting a specific pull request. - ↳
pathsarray[string] optionalThe list of file paths to filter deployment triggers. - ↳
installationIdstring optionalThe GitHub App installation ID. - VCS provider settings
- ↳
repositorystring optionalThe VCS repository reference (format varies by provider) - ↳
deployCommitsboolean optionalWhether to deploy all commits to the default branch - ↳
pathsarray[string] optionalPaths within the repository that trigger deployments when changed - ↳
installationIdstring optionalVCS installation/integration ID linking to the VCS provider - ↳
pullRequestTemplateboolean optionalWhether to use pull request templates for deployment PRs - ↳
previewPullRequestsboolean optionalWhether to create preview deployments for pull requests - ↳
deployPullRequestinteger optionalSpecific pull request number to deploy (overrides automatic deployment) - ↳
providerstring required - The operation context defining pre-run and post-run commands and environment variables.
- The OIDC configuration for the operation.
- ↳
preRunCommandsarray[string] optionalOptional list of commands to run before Pulumi is invoked. - ↳
operationenum optionalThe Pulumi operation to perform (e.g. update, preview, destroy).Values:update,preview,destroy,refresh,detect-drift,remediate-drift - Environment variables to apply during execution.
- Options to specify or override default behavior.
- The deployment role to assume for the operation.
agentPoolIDstring optionalThe identifier of the agent pool to use for deployments.- Cache options for the deployment.
- ↳
enableboolean optionalWhether build caching should be enabled for deployments on this stack.
Responses
versioninteger optionalThe version of the deployment settings.tagstring optionalA tag to identify the deployment settings configuration.- The executor context defining the execution environment.
- Defines the image that the pulumi operations should run in.
- ↳
executorRootPathstring optionalDefines the root path for the executor binary and working directory. - The source context defining where the source code is located.
- Git-based source context for obtaining source code from a repository.
- Mercurial-based source context for obtaining source code from a repository.
- Template-based source context for obtaining source code from a template URL.
- GitHub-specific deployment settings
- ↳
repositorystring optionalThe GitHub repository in the format owner/repo. - ↳
pullRequestTemplateboolean optionalWhether to use a pull request template for deployment previews. - ↳
deployCommitsboolean optionalWhether to automatically deploy commits pushed to the target branch. - ↳
previewPullRequestsboolean optionalWhether to automatically preview pull requests. - ↳
deployPullRequestinteger optionalThe pull request number to deploy, if targeting a specific pull request. - ↳
pathsarray[string] optionalThe list of file paths to filter deployment triggers. - ↳
installationIdstring optionalThe GitHub App installation ID. - VCS provider settings
- ↳
repositorystring optionalThe VCS repository reference (format varies by provider) - ↳
deployCommitsboolean optionalWhether to deploy all commits to the default branch - ↳
pathsarray[string] optionalPaths within the repository that trigger deployments when changed - ↳
installationIdstring optionalVCS installation/integration ID linking to the VCS provider - ↳
pullRequestTemplateboolean optionalWhether to use pull request templates for deployment PRs - ↳
previewPullRequestsboolean optionalWhether to create preview deployments for pull requests - ↳
deployPullRequestinteger optionalSpecific pull request number to deploy (overrides automatic deployment) - ↳
providerstring required - The operation context defining pre-run and post-run commands and environment variables.
- OIDC contains the OIDC configuration for the operation.
- ↳
preRunCommandsarray[string] optionalPreRunCommands is an optional list of arbitrary commands to run before Pulumi is invoked. ref: https://github.com/pulumi/pulumi/issues/9397 - ↳
operationenum optionalThe Pulumi operation to perform (e.g. update, preview, refresh, destroy).Values:update,preview,destroy,refresh,detect-drift,remediate-drift - EnvironmentVariables contains environment variables to be applied during the execution.
- Options is a bag of settings to specify or override default behavior
- Role defines the deployment role to assume for the operation.
sourceenum optionalThe source from which the deployment settings were created.Values:console,api,provider,github-review-stack,azure-devops-review-stack,gitlab-review-stack,bitbucket-review-stack,github-gitopsagentPoolIDstring optionalThe identifier of the agent pool to use for deployments.- Cache options for the deployment.
- ↳
enableboolean requiredWhether build caching is enabled for deployments on this stack.
Replace Deployment Settings
/api/stacks/{orgName}/{projectName}/{stackName}/deployments/settingsFully replaces the Pulumi Deployments settings for a stack. Unlike the PATCH endpoint (PatchDeploymentSettings) which merges changes, this endpoint replaces all settings with the provided values. Any previously configured settings not included in the request body will be removed. Settings include source context (git repository URL, branch, directory), operation context (environment variables, pre-run commands, OIDC configuration), executor context, GitHub integration settings, and cache options. Requires a Team Growth or higher subscription. Cannot be used to configure Pulumi Deployments for Terraform stacks.
Request Parameters
orgNamestring path requiredThe organization nameprojectNamestring path requiredThe project namestackNamestring path requiredThe stack name
Request Body
tagstring optionalA tag to identify the deployment settings configuration.- The executor context defining the execution environment.
- The Docker image to use for the execution environment.
- ↳
executorRootPathstring optionalThe root path for the executor binary and working directory. - The source context defining where the source code is located.
- Git-based source context configuration.
- Mercurial-based source context configuration.
- Template-based source context configuration.
- GitHub-specific deployment settings
- ↳
repositorystring optionalThe GitHub repository in the format owner/repo. - ↳
deployCommitsboolean optionalWhether to automatically deploy commits pushed to the target branch. - ↳
previewPullRequestsboolean optionalWhether to automatically preview pull requests. - ↳
pullRequestTemplateboolean requiredWhether to use a pull request template for deployment previews. - ↳
deployPullRequestinteger optionalThe pull request number to deploy, if targeting a specific pull request. - ↳
pathsarray[string] optionalThe list of file paths to filter deployment triggers. - ↳
installationIdstring optionalThe GitHub App installation ID. - VCS provider settings
- ↳
repositorystring optionalThe VCS repository reference (format varies by provider) - ↳
deployCommitsboolean optionalWhether to deploy all commits to the default branch - ↳
pathsarray[string] optionalPaths within the repository that trigger deployments when changed - ↳
installationIdstring optionalVCS installation/integration ID linking to the VCS provider - ↳
pullRequestTemplateboolean optionalWhether to use pull request templates for deployment PRs - ↳
previewPullRequestsboolean optionalWhether to create preview deployments for pull requests - ↳
deployPullRequestinteger optionalSpecific pull request number to deploy (overrides automatic deployment) - ↳
providerstring required - The operation context defining pre-run and post-run commands and environment variables.
- The OIDC configuration for the operation.
- ↳
preRunCommandsarray[string] optionalOptional list of commands to run before Pulumi is invoked. - ↳
operationenum optionalThe Pulumi operation to perform (e.g. update, preview, destroy).Values:update,preview,destroy,refresh,detect-drift,remediate-drift - Environment variables to apply during execution.
- Options to specify or override default behavior.
- The deployment role to assume for the operation.
agentPoolIDstring optionalThe identifier of the agent pool to use for deployments.- Cache options for the deployment.
- ↳
enableboolean optionalWhether build caching should be enabled for deployments on this stack.
Responses
versioninteger optionalThe version of the deployment settings.tagstring optionalA tag to identify the deployment settings configuration.- The executor context defining the execution environment.
- Defines the image that the pulumi operations should run in.
- ↳
executorRootPathstring optionalDefines the root path for the executor binary and working directory. - The source context defining where the source code is located.
- Git-based source context for obtaining source code from a repository.
- Mercurial-based source context for obtaining source code from a repository.
- Template-based source context for obtaining source code from a template URL.
- GitHub-specific deployment settings
- ↳
repositorystring optionalThe GitHub repository in the format owner/repo. - ↳
pullRequestTemplateboolean optionalWhether to use a pull request template for deployment previews. - ↳
deployCommitsboolean optionalWhether to automatically deploy commits pushed to the target branch. - ↳
previewPullRequestsboolean optionalWhether to automatically preview pull requests. - ↳
deployPullRequestinteger optionalThe pull request number to deploy, if targeting a specific pull request. - ↳
pathsarray[string] optionalThe list of file paths to filter deployment triggers. - ↳
installationIdstring optionalThe GitHub App installation ID. - VCS provider settings
- ↳
repositorystring optionalThe VCS repository reference (format varies by provider) - ↳
deployCommitsboolean optionalWhether to deploy all commits to the default branch - ↳
pathsarray[string] optionalPaths within the repository that trigger deployments when changed - ↳
installationIdstring optionalVCS installation/integration ID linking to the VCS provider - ↳
pullRequestTemplateboolean optionalWhether to use pull request templates for deployment PRs - ↳
previewPullRequestsboolean optionalWhether to create preview deployments for pull requests - ↳
deployPullRequestinteger optionalSpecific pull request number to deploy (overrides automatic deployment) - ↳
providerstring required - The operation context defining pre-run and post-run commands and environment variables.
- OIDC contains the OIDC configuration for the operation.
- ↳
preRunCommandsarray[string] optionalPreRunCommands is an optional list of arbitrary commands to run before Pulumi is invoked. ref: https://github.com/pulumi/pulumi/issues/9397 - ↳
operationenum optionalThe Pulumi operation to perform (e.g. update, preview, refresh, destroy).Values:update,preview,destroy,refresh,detect-drift,remediate-drift - EnvironmentVariables contains environment variables to be applied during the execution.
- Options is a bag of settings to specify or override default behavior
- Role defines the deployment role to assume for the operation.
sourceenum optionalThe source from which the deployment settings were created.Values:console,api,provider,github-review-stack,azure-devops-review-stack,gitlab-review-stack,bitbucket-review-stack,github-gitopsagentPoolIDstring optionalThe identifier of the agent pool to use for deployments.- Cache options for the deployment.
- ↳
enableboolean requiredWhether build caching is enabled for deployments on this stack.
Delete Deployment Settings
/api/stacks/{orgName}/{projectName}/{stackName}/deployments/settingsRemoves all Pulumi Deployments settings for a stack, including source context, operation context, executor context, GitHub integration settings, and cache options. After deletion, the stack can no longer run deployments until new settings are configured. Any active schedules (drift detection, TTL, or custom) associated with the stack may also be affected.
Request Parameters
orgNamestring path requiredThe organization nameprojectNamestring path requiredThe project namestackNamestring path requiredThe stack name
Responses
Encrypt Deployment Settings Secret
/api/stacks/{orgName}/{projectName}/{stackName}/deployments/settings/encryptEncrypts a plaintext secret value for secure storage in Pulumi Deployments settings. Use this endpoint to encrypt sensitive values such as cloud provider credentials, API keys, or other secrets before including them in deployment settings (e.g. as environment variables in operationContext). The encrypted value can then be safely stored in the deployment settings and will be decrypted at deployment execution time. The request body must contain a non-empty plaintext value to encrypt.
Request Parameters
orgNamestring path requiredThe organization nameprojectNamestring path requiredThe project namestackNamestring path requiredThe stack name
Request Body
secretstring requiredThe secret value in plaintext.ciphertextarray[string] optionalThe encrypted representation of the secret value.
Responses
secretstring requiredThe secret value in plaintext.ciphertextarray[string] optionalThe encrypted representation of the secret value.
Get Deployment
/api/stacks/{orgName}/{projectName}/{stackName}/deployments/version/{version}Retrieves detailed information about a specific Pulumi Deployments execution by its version number within the stack. This is an alternative to fetching by deployment ID and returns the same response structure: deployment status, creation and modification timestamps, the user who requested the deployment, the Pulumi operation type, job details with step-level progress, and any associated stack update results.
Request Parameters
orgNamestring path requiredThe organization nameprojectNamestring path requiredThe project namestackNamestring path requiredThe stack nameversionstring path requiredThe deployment version number
Responses
idstring requiredUnique identifier for this deployment.createdstring requiredCreated defines when the Deployment was created.modifiedstring requiredCreated defines when the corresponding WorkflowRun was modified.statusenum requiredStatus is the current status of the workflow runID.Values:not-started,accepted,running,failed,succeeded,skippedversioninteger requiredVersion is the ordinal ID for the stack- RequestedBy contains the user information about the user who created the Deployment
- ↳
namestring requiredThe user’s display name. - ↳
githubLoginstring requiredThe user’s login name. - ↳
avatarUrlstring requiredThe URL of the user’s avatar image. - ↳
emailstring optionalIMPORTANT: The email address of the user is only included on a few admin-only APIs. For nearly all APIs that return a UserInfo object, this will not be provided. considered sensitive information. - Jobs make up all the Jobs of the Deployment. Omitted for deployments that have not started yet.
- ↳
statusenum requiredThe current status of the deployment job.Values:not-started,accepted,running,failed,succeeded,skipped - ↳
startedstring optionalThe timestamp when the job started. - ↳
lastUpdatedstring optionalThe timestamp when the job was last updated. - The list of steps in the deployment job.
latestVersioninteger requiredLatestVersion is the most recent version number for deployments for the given programID- Configuration contains the environment variables and source information for a deployment
- The list of environment variables for the deployment.
- The source configuration for the deployment.
initiatorstring optionalInitiator is the initiation source of the deployment.pulumiOperationenum optionalPulumiOperation is the operation that was performed. Omitted for historical deployments that predate this field.Values:update,preview,destroy,refresh,detect-drift,remediate-drift
List Drift Runs
/api/stacks/{orgName}/{projectName}/{stackName}/drift/runsReturns a paginated list of all drift detection runs for a stack. Each drift run represents a scheduled or manually triggered drift detection execution and includes details about whether drift was detected and any remediation actions taken. Use the ‘page’ (minimum 1, default 1) and ‘pageSize’ (1-100, default 10) query parameters for pagination.
Request Parameters
orgNamestring path requiredThe organization nameprojectNamestring path requiredThe project namestackNamestring path requiredThe stack namepageinteger query optionalPage number (min 1, default 1)pageSizeinteger query optionalResults per page (1-100, default 10)
Responses
- The list of drift runs
- ↳
idstring requiredThe unique identifier of the drift run. - ↳
driftDetectedboolean requiredWhether drift was detected during the run. - ↳
createdstring requiredThe timestamp when the drift run was created. - ↳
statusenum requiredThe current status of the drift run.Values:not-started,accepted,running,failed,succeeded,skipped - ↳
deploymentIdstring optionalThe deployment identifier associated with the drift run. - ↳
deploymentVersioninteger optionalThe deployment version associated with the drift run. - The update that performed drift detection.
- The update that performed drift remediation.
itemsPerPageinteger requiredThe number of items per pagetotalinteger requiredThe total number of drift runs
Get Stack Drift Status
/api/stacks/{orgName}/{projectName}/{stackName}/drift/statusRetrieves the current drift detection status and associated metadata for a stack. Drift occurs when the actual state of cloud resources diverges from the state declared in the Pulumi program. The response indicates whether drift has been detected, when the last drift check was performed, and details about any detected differences. This is used in conjunction with drift detection schedules to monitor infrastructure compliance.
Request Parameters
orgNamestring path requiredThe organization nameprojectNamestring path requiredThe project namestackNamestring path requiredThe stack name
Responses
driftDetectedboolean requiredWhether drift was detected in the latest run.latestDriftRunstring requiredThe identifier of the latest drift detection run.runInProgressboolean requiredWhether a drift detection run is currently in progress.
Thank you for your feedback!
If you have a question about how to use Pulumi, reach out in Community Slack.
Open an issue on GitHub to report a problem or suggest an improvement.