# Deployment Revisions

**Deployment revisions represent previous configurations of a Deployment.**

Deployment revisions are created automatically for every successful Deployment and can be used to inspect earlier configurations or roll back a Deployment to a previous version.

## Get DeploymentRevision

### Get DeploymentRevision by Deployment ID

[endpoint definition](/search.md?urn=ctp:connect:endpoint:/{projectKey}/deployments/{id}/revisions/{revision}:GET).

### Get DeploymentRevision by Deployment Key

[endpoint definition](/search.md?urn=ctp:connect:endpoint:/{projectKey}/deployments/key={key}/revisions/{revision}:GET).

## Query DeploymentRevisions

Returns the revisions of a Deployment, most recent first. Only versions that were deployed successfully are returned, so every result is a valid rollback target.

### Query DeploymentRevisions by Deployment ID

[endpoint definition](/search.md?urn=ctp:connect:endpoint:/{projectKey}/deployments/{id}/revisions:GET).

### Query DeploymentRevisions by Deployment Key

[endpoint definition](/search.md?urn=ctp:connect:endpoint:/{projectKey}/deployments/key={key}/revisions:GET).

## Rollback DeploymentRevision

Restores a [DeploymentRevision](/search.md?urn=ctp:connect:type:DeploymentRevision) as a new Deployment version. The Connector version and all application configurations from the revision are applied to the new Deployment.

The rollback creates a new Deployment version rather than removing the current one, so the current Deployment remains available as a revision.

### Rollback DeploymentRevision by Deployment ID

[endpoint definition](/search.md?urn=ctp:connect:endpoint:/{projectKey}/deployments/{id}/revisions/{revision}/rollback:POST).

### Rollback DeploymentRevision by Deployment Key

[endpoint definition](/search.md?urn=ctp:connect:endpoint:/{projectKey}/deployments/key={key}/revisions/{revision}/rollback:POST).

## Representations

#### DeploymentRevision

[type definition](/search.md?urn=ctp:connect:type:DeploymentRevision).

#### DeploymentRevisionConnector

[type definition](/search.md?urn=ctp:connect:type:DeploymentRevisionConnector).

#### DeploymentRevisionApplication

[type definition](/search.md?urn=ctp:connect:type:DeploymentRevisionApplication).

#### DeploymentRollback

[type definition](/search.md?urn=ctp:connect:type:DeploymentRollback).

## Related pages

- [Area overview page with navigation](/connect.md)
- [Previous page: Deployment Logs](/connect/deployment-logs.md)
- [Search documentation and API specs](/search.md)