Create a New Release for an Organization

Create a new release for the given organization. Releases are used by Sentry to improve its error reporting abilities by correlating first seen events with the release that might have introduced the problem. Releases are also necessary for source maps and other debug features that require manual upload for functioning well.

Path Parameters

organization_slug (string)
REQUIRED

The slug of the organization.

Body Parameters

version (string)
REQUIRED

A version identifier for this release. Can be a version number, a commit hash, etc.

ref (string)

An optional commit reference. This is useful if a tagged version has been provided.

url (string)

A URL that points to the release. This can be the path to an online interface to the source code for instance

projects (array)
REQUIRED

A list of project slugs that are involved in this release.

dateReleased (string)

An optional date that indicates when the release went live. If not provided the current time is assumed.

commits (array)

An optional list of commit data to be associated with the release. Commits must include parameters id (the SHA of the commit), and can optionally include repository, message, patch_set, author_name, author_email, and timestamp.

refs (array)

An optional way to indicate the start and end commits for each repository included in a release. Head commits must include parameters repository and commit (the HEAD sha). They can optionally include previousCommit (the sha of the HEAD of the previous release), which should be specified if this is the first time you've sent commit data. commit may contain a range in the form of previousCommit..commit.

Scopes

<auth_token> requires the following scopes:
  • project:releases
POST /api/0/organizations/{organization_slug}/releases/
curl https://sentry.io/api/0/organizations/{organization_slug}/releases/ \
 -H 'Authorization: Bearer <auth_token>' \
 -H 'Content-Type: application/json' \
 -d '{"version":"2.0rc2","ref":"6ba09a7c53235ee8a8fa5ee4c1ca8ca886e7fdbb","projects":["pump-station"]}'
RESPONSESCHEMA
{
  "authors": [],
  "commitCount": 0,
  "data": {},
  "dateCreated": "2019-01-03T00:12:55.109Z",
  "dateReleased": null,
  "deployCount": 0,
  "firstEvent": null,
  "lastCommit": null,
  "lastDeploy": null,
  "lastEvent": null,
  "newGroups": 0,
  "owner": null,
  "projects": [
    {
      "name": "Pump Station",
      "slug": "pump-station"
    }
  ],
  "ref": "6ba09a7c53235ee8a8fa5ee4c1ca8ca886e7fdbb",
  "shortVersion": "2.0rc2",
  "url": null,
  "version": "2.0rc2"
}