# List template versions

`GET /v1/templates/{id}/versions`

The versions of one template, newest first. Every publish that changes something makes one, and the last 50 are kept.

Needs the scope: `templates:read`

## Path parameters

- `id` (string, required): The id of the item. Up to 64 characters.

## Query parameters

- `limit` (integer): How many items to return, from 1 to 100. Without it you get 25.
- `offset` (integer): How many items to skip. Use it with `limit` to read the next page. Default: `0`.

## Returns

- `object` ("list"): Always `list`.
- `data` (object[]): The items on this page.
- `data[].object` ("template_version"): Always `template_version`.
- `data[].templateId` (string): The id of the template it is a version of.
- `data[].version` (integer): The number of the version. The first publish is 1.
- `data[].subject` (string): The subject line of that version.
- `data[].publishedAt` (string): When that version was published.
- `data[].live` (boolean): `true` for the version emails are built from now.
- `total` (integer): How many items match in all, on every page together.
- `hasMore` (boolean): Whether more items follow this page.

## Example

cURL:

```bash
curl "$OPENSEND_API_URL/v1/templates/tmpl_06/versions" \
  -H "Authorization: Bearer $OPENSEND_API_KEY"
```

TypeScript:

```ts
await opensend.templates.versions('tmpl_06')
```

CLI:

```bash
opensend templates versions tmpl_06
```

MCP:

```json
{
  "name": "templates_versions",
  "arguments": {
    "id": "tmpl_06"
  }
}
```

Answer:

```json
{
  "object": "list",
  "data": [
    {
      "object": "template_version",
      "templateId": "tmpl_06",
      "version": 1,
      "subject": "Welcome to Acme",
      "publishedAt": "2026-11-27T09:30:00.000Z",
      "live": true
    }
  ],
  "total": 1,
  "hasMore": false
}
```
