Automating Deployments


Track deployments to understand how changes impact performance. Deploys allow you to see timeline markers for code deployments.

Create deploy

Required API Permission: Create Deploys

To create deploys as part of your continuous integration or deployment system, add revision, repository and username details:

You can create deploys with the CLI, Node.js API, HTTP Site API or GraphQL API.

Example Response
ParameterRequiredDescription
siteYesSite slug, found in site settings
revisionNoSource control revision id of the code being deployed (e.g. git hash or tag name)
repositoryNoBase URL of the repository containing the source code being deployed (e.g. https://github.com/calibreapp/app)
usernameNoName of the user who deployed the code
createdAtNoThe ISO8601 timestamp when the deploy was created

List deploys

Required API Permission: Read Sites

You can list deploys with the CLI, Node.js API, HTTP Site API or GraphQL API.

Example Response
ParameterRequiredDescription
siteYesSite slug, found in site settings
countNoThe number of records to return, maximum: 500
cursorNoThe cursor to fetch records after

Delete deploy

Required API Permission: Delete Deploys

You can delete a deploy with the CLI, Node.js API or GraphQL API.

Example Response
ParameterRequiredDescription
siteYesSite slug, found in site settings
uuidYesThe uuid of the deploy

Retrieve deploy

You can retrieve a deploy with the HTTP Site API.

Example Response
ParameterRequiredDescription
siteYesSite slug, found in site settings
uuidYesThe uuid of the deploy

Heroku deployment tracking

You can track deploys with Heroku's free deploy hooks addon. To add a deploy hook, install the Heroku CLI and run the following command:

You should replace the following with your own values:

ParameterRequiredDescription
appYesThe name of your Heroku app
siteYesSite slug, found in site settings
repositoryNoBase URL of the repository containing the source code being deployed (e.g. https://github.com/calibreapp/app)

Related Articles