dots.v2.apps.byApp_Id().deployments.get()

Generated on 5 Nov 2026 from DoTs version v1.23.0

Usage

client.v2.apps.byApp_Id(app_Id).deployments.get(requestConfiguration?: RequestConfiguration<DeploymentsRequestBuilderGetQueryParameters>): Promise<undefined | Apps_deployments_response>

Description

List all deployments of an app.

Parameters

Path Parameters

app_Id string required

Example: 4f6c71e2-1e90-4762-9fee-6cc4a0a9f2cf

The app ID

Query Parameters

page integer optional

Example: 1

Which 'page' of paginated results to return.

Default: 1

Min: 1

perPage integer optional

Example: 2

Number of items returned per page

Default: 20

Min: 1

Max: 200

deploymentTypes array of strings optional

Example: ["MANUAL", "AUTOSCALED"]

Optional. Filter deployments by deployment_type
- MANUAL: manual deployment
- DEPLOY_ON_PUSH: deployment triggered by a push to the app's repository
- MAINTENANCE: deployment for maintenance purposes
- MANUAL_ROLLBACK: manual revert to a previous deployment
- AUTO_ROLLBACK: automatic revert to a previous deployment
- UPDATE_DATABASE_TRUSTED_SOURCES: update database trusted sources
- AUTOSCALED: deployment that has been autoscaled

Request Sample

Show Request Sample
import { FetchRequestAdapter } from "@microsoft/kiota-http-fetchlibrary";
import {
    createDigitalOceanClient,
    DigitalOceanApiKeyAuthenticationProvider,
} from "@digitalocean/dots";

const authProvider = new DigitalOceanApiKeyAuthenticationProvider(process.env.DIGITALOCEAN_TOKEN!);
const adapter = new FetchRequestAdapter(authProvider);
const client = createDigitalOceanClient(adapter);

const response = await client.v2.apps
    .byApp_Id("4f6c71e2-1e90-4762-9fee-6cc4a0a9f2cf").deployments.get();

Pagination

This method returns paginated results. The response includes a links.pages object with URLs for navigating between pages. To retrieve the next page, parse the next URL and pass the page query parameter:

let response = await client.v2.apps
    .byApp_Id("4f6c71e2-1e90-4762-9fee-6cc4a0a9f2cf").deployments.get();
let pages = response?.links?.pages;

while (pages && "next" in pages && typeof pages.next === "string") {
    const page = Number(new URL(pages.next).searchParams.get("page"));
    response = await client.v2.apps
        .byApp_Id("4f6c71e2-1e90-4762-9fee-6cc4a0a9f2cf").deployments.get({
        queryParameters: {
            page,
        },
    });
    pages = response?.links?.pages;
}

Response Example

Show Response Example
{
  "deployments": [
    {
      "id": "b6bdf840-2854-4f87-a36c-5f231c617c84",
      "spec": {
        "name": "sample-golang",
        "disable_edge_cache": true,
        "disable_email_obfuscation": true,
        "enhanced_threat_control_enabled": true,
        "services": [
          {
            "name": "web",
            "github": {
              "repo": "digitalocean/sample-golang",
              "branch": "branch"
            },
            "run_command": "bin/sample-golang",
            "environment_slug": "go",
            "instance_size_slug": "apps-s-1vcpu-0.5gb",
            "instance_count": 2,
            "routes": [
              {
                "path": "/"
              }
            ]
          }
        ],
        "region": "ams"
      },
      "services": [
        {
          "name": "web",
          "source_commit_hash": "9a4df0b8e161e323bc3cdf1dc71878080fe144fa"
        }
      ],
      "phase_last_updated_at": "0001-01-01T00:00:00Z",
      "created_at": "2020-07-28T18:00:00Z",
      "updated_at": "2020-07-28T18:00:00Z",
      "cause": "commit 9a4df0b pushed to github/digitalocean/sample-golang",
      "progress": {
        "pending_steps": 6,
        "total_steps": 6,
        "steps": [
          {
            "name": "build",
            "status": "PENDING",
            "steps": [
              {
                "name": "initialize",
                "status": "PENDING"
              },
              {
                "name": "components",
                "status": "PENDING",
                "steps": [
                  {
                    "name": "web",
                    "status": "PENDING",
                    "component_name": "web",
                    "message_base": "Building service"
                  }
                ]
              }
            ]
          },
          {
            "name": "deploy",
            "status": "PENDING",
            "steps": [
              {
                "name": "initialize",
                "status": "PENDING"
              },
              {
                "name": "components",
                "status": "PENDING",
                "steps": [
                  {
                    "name": "web",
                    "status": "PENDING",
                    "steps": [
                      {
                        "name": "deploy",
                        "status": "PENDING",
                        "component_name": "web",
                        "message_base": "Deploying service"
                      },
                      {
                        "name": "wait",
                        "status": "PENDING",
                        "component_name": "web",
                        "message_base": "Waiting for service"
                      }
                    ],
                    "component_name": "web"
                  }
                ]
              },
              {
                "name": "finalize",
                "status": "PENDING"
              }
            ]
          }
        ]
      },
      "phase": "PENDING_BUILD",
      "tier_slug": "basic"
    }
  ],
  "links": {
    "pages": {}
  },
  "meta": {
    "total": 1
  }
}

More Information

See /v2/apps/{app_id}/deployments in the API reference for additional detail on responses, headers, parameters, and more.

We can't find any results for your search.

Try using different keywords or simplifying your search terms.