---
title: "(preview) List versions"
method: POST
path: "/v1/databases/{db_id}/list_versions"
tags: ["Database"]
---

# (preview) List versions

`POST /v1/databases/{db_id}/list_versions`

## Request

- Base URL: `https://api.bunny.net/database`
- URL: `https://api.bunny.net/database/v1/databases/{db_id}/list_versions`
- Auth: one of:
  - API key in header `Authorization`
  - API key in header `AccessKey`
- TypeScript: <https://skmtc.dev/bunny/apis/bunny-database-backend-api/docs/v1/databases/:db_id/list_versions/post.ts> (a function with typed inputs; its response is checked against the schema)

List versions for a Database

## Path parameters

- `db_id` string, required: [DatabaseId] is a `db_<ulid>`

## Request body

- ListVersionsDatabaseGroupPayload
  - `limit` integer, nullable
  - `older_than` string, date, nullable
  - `newer_than` string, date, nullable

## Response `200`

- ListVersionsDatabaseGroupResponse
  - `generations` Generation[], required
    - `created_at` string, date-time, required
    - `generation` string, uuid, required
  - `count` integer, required

## Other responses

- `401`: A default error response for most API errors.
- `500`: A default error response for most API errors.

---

[API](https://skmtc.dev/bunny/apis/bunny-database-backend-api.md) - [All operations](https://skmtc.dev/bunny/apis/bunny-database-backend-api/llms.txt) - [OpenAPI document](https://skmtc.dev/bunny/apis/bunny-database-backend-api/revisions/f3bb69bad6b6?raw)
