---
title: "Get a database"
method: GET
path: "/spaces/{space_id}/databases/{database_ref}"
---

# Get a database

`GET /spaces/{space_id}/databases/{database_ref}`

Gets a single database by ID or name.

## Path parameters

- `space_id` string, required
- `database_ref` string, required

## Response `200`

Database details

- Database — A Ghost database.
  - `id` string, required — Database ID.
  - `name` string, required — Database name. Unique within the space.
  - `type` 'standard' | 'dedicated', required — Database deployment model. - `standard` — shared-resource databases subject to the space's compute and storage limits. - `dedicated` — per-instance paid databases with guaranteed resources, exempt from space-level auto-pause.
  - `size` '1x' | '2x' | '4x' | '8x' — Compute size for dedicated databases. Each step up allocates proportionally more vCPU and RAM.
  - `status` 'queued' | 'configuring' | 'running' | 'pausing' | 'paused' | 'resuming' | 'deleting' | 'deleted' | 'upgrading' | 'unstable' | 'unknown', required — Current lifecycle status of the database.
  - `host` string, required — PostgreSQL hostname for connections.
  - `port` integer, required — PostgreSQL port for connections.
  - `password` string, nullable — PostgreSQL password for the default user. Returned on every GET for authorized callers.
  - `storage_mib` integer, nullable — Current disk usage in MiB. Null if not yet available.

## Other responses

- `default` — Error response

## Changes

> 21 revisions in range; 16 could not be searched.

- **2026-04-17** `a7becb6668ec` — 2 breaking, 1 warning
  - the response property `size` became nullable for the status `200`
  - the `storage_mib` response's property type/format changed from `integer`/`int64` to `integer`/`` for status `200`
  - removed the optional property `code` from the response with the `default` status

[Change history](https://skmtc.dev/timescale/apis/ghost-api/changes/spaces/:space_id/databases/:database_ref/get.md)

---

[API](https://skmtc.dev/timescale/apis/ghost-api.md) · [All operations](https://skmtc.dev/timescale/apis/ghost-api/llms.txt) · [OpenAPI document](https://skmtc-service-production.skmtc.workers.dev/v1/apis/timescale/ghost-api/revisions/42816b90d8d6/schema)
