Deployments
You can track deployments of individual repositories by simply sending a request to the API. Our codebase gem includes support for Capistrano, but there is no reason why you can't add support for any other deployment mechanism by simply using the API as detailed below.
API URLs
Data | Method | URL |
Create a deployment | POST | /project/repository/deployments |
Creating a deployment
To create a new deployment, you should simply submit the following XML to the URL shown in the table above. This will automatically add the deployment to your activity feed and carry out any post-deployment activities as defined in your account. Requests should be authenticated as normal using your username and API key.
POST /project/repository/deployments
<deployment>
<branch>master</branch>
<revision>deac8ba2675d6da4c8c9df4525da0a92fcea6c1a</revision>
<environment>production</environment>
<servers>app.myapp.com</servers>
</deployment>
branch
required - The branch which you are deployingrevision
required - The reference of the revision/commit you are deploying. This must already exist in your repository and have been pushed to Codebase.environment
- The environment you are pushing to (used for reference only)servers
required - List of servers which you are deploying to (multiple servers should be comma separated, e.g.app1.myapp.com, app2.myapp.com, app3.myapp.com
) - server data is required.