---
title: "Revoke a database share"
method: DELETE
path: "/spaces/{space_id}/shares/{share_token}"
---

# Revoke a database share

`DELETE /spaces/{space_id}/shares/{share_token}`

Revokes a shared snapshot, deleting the underlying storage snapshot. The share is identified by its share token.

## Path parameters

- `space_id` string, required
- `share_token` string, required

## Response `200`

Share revoked

- DatabaseShare — A shareable snapshot of a database. Can be used to create a new database from the snapshot in another space.
  - `share_token` string, required — Token passed to `createDatabase` (via `share_token`) to create a new database from the shared snapshot in another space. Also used to revoke the share via `revokeShare`. Always begins with `gs_`.
  - `database_id` string, required — ID of the source database.
  - `database_name` string, required — Name of the source database.
  - `created_at` string, date-time, required — Time the share was created.
  - `expires_at` string, date-time — Time the share expires. Absent if the share does not expire.
  - `revoked_at` string, date-time — Time the share was revoked. Absent if the share is still active.

## Other responses

- `default` — Error response

---

[API](https://skmtc.net/timescale/apis/ghost-api.md) · [All operations](https://skmtc.net/timescale/apis/ghost-api/llms.txt) · [OpenAPI document](https://skmtc-service-staging.skmtc.workers.dev/v1/apis/timescale/ghost-api/versions/808022f897be/schema)
