DeployPulse

πŸš€ DeployPulse API Instructions

πŸ›‚ 1. Retrieve Your Bearer Token

Before making API requests, you’ll need an authorization token.

➑️ Follow the DeployPulse Quickstart Guide – Registering and Login to sign in and obtain your Bearer token.

Use it in every request like this:

-H "Authorization: Bearer YOUR_BEARER_TOKEN"

πŸ“˜ 2. Create a New App

curl 'https://api.deploypulse.io/apps' \
  -X POST \
  -H "Authorization: Bearer YOUR_BEARER_TOKEN" \
  -H "Content-Type: application/json" \
  --data-raw '{
    "name": "New App",
    "manuallyProvisionDeployments": false
  }'

Note: If you set manuallyProvisionDeployments to true, you will need to manually create deployments for this app. By default, a staging and production deployment will be created.


πŸ” 3. Get an App by Name

curl 'https://api.deploypulse.io/apps/New%20App' \
  -H "Authorization: Bearer YOUR_BEARER_TOKEN"

πŸ“₯ Example Response

{
  "app": {
    "name": "New App",
    "collaborators": {
      "you@example.com": {
        "isCurrentAccount": true,
        "permission": "Owner",
        "canEdit": false,
        "canTransfer": true
      }
    },
    "deployments": [
      "Production",
      "Staging"
    ]
  }
}

πŸ“¦ 4. List Deployments for an App

curl 'https://api.deploypulse.io/apps/New%20App/deployments' \
  -H "Authorization: Bearer YOUR_BEARER_TOKEN"

πŸ“₯ Example Response

{
  "deployments": [
    {
      "timestamp": "2025-01-10T10:15:30.1234567Z",
      "name": "Production",
      "key": "PRODUCTION_DEPLOYMENT_KEY",
      "id": "PRODUCTION_DEPLOYMENT_ID",
    },
    {
      "timestamp": "2025-01-10T10:16:45.9876543Z",
      "name": "Staging",
      "key": "STAGING_DEPLOYMENT_KEY",
      "id": "STAGING_DEPLOYMENT_ID",
    }
  ]
}

πŸ› οΈ 5. Create a New Deployment

Use this POST request to create a new deployment within an app:

curl 'https://api.deploypulse.io/apps/New%20App/deployments' \
  -X POST \
  -H "Authorization: Bearer YOUR_BEARER_TOKEN" \
  -H "Content-Type: application/json" \
  --data-raw '{
    "name": "New Deployment"
  }'

πŸ“₯ Example Response

{
  "deployment": {
    "name": "New Deployment",
    "key": "NEW_DEPLOYMENT_KEY"
  }
}

πŸ”‘ The key returned uniquely identifies the deployment and is used in deployment variant in the DeployPulse SDK.


βœ… Required Headers Summary

Always include the following headers:

-H "Authorization: Bearer YOUR_BEARER_TOKEN"
-H "Content-Type: application/json"
-H "Accept: application/json"