curl --request GET \
--url https://api.korve.dev/v1/orgs/{orgId}/projects/{projectId}/databases/{databaseId} \
--header 'Authorization: Bearer <token>'import requests
url = "https://api.korve.dev/v1/orgs/{orgId}/projects/{projectId}/databases/{databaseId}"
headers = {"Authorization": "Bearer <token>"}
response = requests.get(url, headers=headers)
print(response.text)const options = {method: 'GET', headers: {Authorization: 'Bearer <token>'}};
fetch('https://api.korve.dev/v1/orgs/{orgId}/projects/{projectId}/databases/{databaseId}', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://api.korve.dev/v1/orgs/{orgId}/projects/{projectId}/databases/{databaseId}",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"net/http"
"io"
)
func main() {
url := "https://api.korve.dev/v1/orgs/{orgId}/projects/{projectId}/databases/{databaseId}"
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("Authorization", "Bearer <token>")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.get("https://api.korve.dev/v1/orgs/{orgId}/projects/{projectId}/databases/{databaseId}")
.header("Authorization", "Bearer <token>")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.korve.dev/v1/orgs/{orgId}/projects/{projectId}/databases/{databaseId}")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
request["Authorization"] = 'Bearer <token>'
response = http.request(request)
puts response.read_body{
"id": "<string>",
"name": "<string>",
"environment": "<string>",
"status": "provisioning",
"region": "<string>",
"replicas": 0,
"host": "<string>",
"port": 123,
"poolerPort": 123,
"dbName": "<string>",
"user": "<string>",
"provider": "<string>",
"sku": "<string>",
"targetSku": "<string>",
"allocatedStorageGb": 123,
"resize": {
"direction": "up",
"phase": "queued",
"progressPercent": 123,
"startedAt": "2023-11-07T05:31:56Z",
"estimatedCompletedAt": "2023-11-07T05:31:56Z"
},
"liveStatus": "live",
"lastSeenAt": "2023-11-07T05:31:56Z",
"sizeBytes": 123,
"nodes": [
{
"ordinal": 123,
"role": "primary",
"region": "<string>",
"status": "<string>",
"metrics": {
"sampledAt": "2023-11-07T05:31:56Z",
"qps": 123,
"readIops": 123,
"writeIops": 123,
"cpuPercent": 123,
"memoryUsedBytes": 123,
"memoryLimitBytes": 123,
"directConnections": 123,
"pgbouncer": {
"clientActive": 123,
"clientWaiting": 123,
"serverActive": 123,
"serverIdle": 123,
"maxClientConnections": 123
}
}
}
],
"metrics": {
"sampledAt": "2023-11-07T05:31:56Z",
"qps": 123,
"readIops": 123,
"writeIops": 123,
"cpuPercent": 123,
"memoryUsedBytes": 123,
"memoryLimitBytes": 123,
"directConnections": 123,
"pgbouncer": {
"clientActive": 123,
"clientWaiting": 123,
"serverActive": 123,
"serverIdle": 123,
"maxClientConnections": 123
}
},
"createdAt": "2023-11-07T05:31:56Z"
}Get
Get one database’s status and connection details (never the password).
curl --request GET \
--url https://api.korve.dev/v1/orgs/{orgId}/projects/{projectId}/databases/{databaseId} \
--header 'Authorization: Bearer <token>'import requests
url = "https://api.korve.dev/v1/orgs/{orgId}/projects/{projectId}/databases/{databaseId}"
headers = {"Authorization": "Bearer <token>"}
response = requests.get(url, headers=headers)
print(response.text)const options = {method: 'GET', headers: {Authorization: 'Bearer <token>'}};
fetch('https://api.korve.dev/v1/orgs/{orgId}/projects/{projectId}/databases/{databaseId}', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://api.korve.dev/v1/orgs/{orgId}/projects/{projectId}/databases/{databaseId}",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"net/http"
"io"
)
func main() {
url := "https://api.korve.dev/v1/orgs/{orgId}/projects/{projectId}/databases/{databaseId}"
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("Authorization", "Bearer <token>")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.get("https://api.korve.dev/v1/orgs/{orgId}/projects/{projectId}/databases/{databaseId}")
.header("Authorization", "Bearer <token>")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.korve.dev/v1/orgs/{orgId}/projects/{projectId}/databases/{databaseId}")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
request["Authorization"] = 'Bearer <token>'
response = http.request(request)
puts response.read_body{
"id": "<string>",
"name": "<string>",
"environment": "<string>",
"status": "provisioning",
"region": "<string>",
"replicas": 0,
"host": "<string>",
"port": 123,
"poolerPort": 123,
"dbName": "<string>",
"user": "<string>",
"provider": "<string>",
"sku": "<string>",
"targetSku": "<string>",
"allocatedStorageGb": 123,
"resize": {
"direction": "up",
"phase": "queued",
"progressPercent": 123,
"startedAt": "2023-11-07T05:31:56Z",
"estimatedCompletedAt": "2023-11-07T05:31:56Z"
},
"liveStatus": "live",
"lastSeenAt": "2023-11-07T05:31:56Z",
"sizeBytes": 123,
"nodes": [
{
"ordinal": 123,
"role": "primary",
"region": "<string>",
"status": "<string>",
"metrics": {
"sampledAt": "2023-11-07T05:31:56Z",
"qps": 123,
"readIops": 123,
"writeIops": 123,
"cpuPercent": 123,
"memoryUsedBytes": 123,
"memoryLimitBytes": 123,
"directConnections": 123,
"pgbouncer": {
"clientActive": 123,
"clientWaiting": 123,
"serverActive": 123,
"serverIdle": 123,
"maxClientConnections": 123
}
}
}
],
"metrics": {
"sampledAt": "2023-11-07T05:31:56Z",
"qps": 123,
"readIops": 123,
"writeIops": 123,
"cpuPercent": 123,
"memoryUsedBytes": 123,
"memoryLimitBytes": 123,
"directConnections": 123,
"pgbouncer": {
"clientActive": 123,
"clientWaiting": 123,
"serverActive": 123,
"serverIdle": 123,
"maxClientConnections": 123
}
},
"createdAt": "2023-11-07T05:31:56Z"
}Authorizations
Bearer authentication header of the form Bearer <token>, where <token> is your auth token.
Path Parameters
The organization's id (UUID) or slug — either form is accepted.
The project's id (UUID) or slug — either form is accepted.
The database's id (UUID), from databases.list.
Response
The database.
Customer-chosen database name — unique within the environment. 2-62 chars of lowercase letters, digits, and hyphens, starting with a letter.
^[a-z][a-z0-9-]{1,61}$Slug of the environment the database belongs to.
^[a-z][a-z0-9-]{0,38}$provisioning, resizing, ready, failed Database region id (see regions.list). Immutable after provisioning.
Topology: 0 creates a single-node database; 2 creates one primary plus two data replicas with synchronous quorum commits and continuous recovery.
0, 2 Managed database endpoint — the in-platform hostname for SKU databases, "db.korve.app" for legacy ones.
PgBouncer transaction-pooling port. The primary port remains available for session-mode clients.
Database backend generation the row lives on. Set at provisioning.
Database SKU id (see the rate card via billing.get); null on legacy databases.
Requested SKU while a zero-downtime HA resize is running; otherwise null.
Actual allocated data-disk capacity. It grows with larger SKUs and remains allocated after a compute downsize because durable volumes cannot shrink.
Durable progress for an active rolling resize; null when no resize is running.
Show child attributes
Show child attributes
Liveness from the instance's heartbeat: live when the last report is recent, stale once it lapses, unknown before the instance has ever reported.
live, stale, unknown When the instance last reported in; null until the first heartbeat.
On-disk size in bytes from the latest heartbeat; null until the first report.
Instance topology for managed databases. Empty for legacy databases.
Show child attributes
Show child attributes
Latest one-minute operational sample; null until the node agent reports one.
Show child attributes
Show child attributes