# Return an entry to an earlier version as a new version

`POST /cms/entries/{id}/rollback` · Rivier · content

Return an entry to an earlier version as a new version.

- Scope: content:write
- Mcp: rivier_cms_rollback
- Graphql: Mutation.contentEntryRollback
- Sdk: content.entry.rollback
- Cli: content entry rollback

## Parameters

- `id` (path, required), string

## Request body

`application/json`

```json
{
  "type": "object",
  "properties": {
    "toVersion": {
      "type": "integer",
      "minimum": 1
    },
    "dryRun": {
      "type": "boolean"
    },
    "reason": {
      "type": "string",
      "maxLength": 300
    },
    "idempotencyKey": {
      "type": "string",
      "minLength": 1,
      "maxLength": 120
    }
  },
  "required": [
    "toVersion"
  ],
  "additionalProperties": false
}
```

## Responses

- `200`: Success
- `400`: The request was malformed
- `401`: No valid credential
- `403`: The credential lacks the scope, origin or address
- `429`: Over the key's rate limit; see Retry-After

## Example

```sh
curl -X POST 'https://api.rivier.ai/cms/entries/{id}/rollback' \
  -H 'Authorization: Bearer $KEY' \
  -H 'Content-Type: application/json' \
  -d '{
  "toVersion": 0
}'
```
