ClickHouse Postgres API

The Postgres API from ClickHouse — 12 operation(s) for postgres.

Business capability
IT Infrastructure Management BC-600.50

Operations 17

Each operation below carries the questions people ask an LLM about it and the instructions they give an agent to run it. Generated by API Evangelist overlay

POST /v1/organizations/{organizationId}/postgres Create a managed Postgres service · Create new Postgres service #
Ask an LLM
“How do I spin up a new managed Postgres database?”
“Can I choose the Postgres version and high-availability setup when creating a database?”
Tell an agent
Create a Postgres service named {name} on {provider} in {region} with size {size} in org {org}.
Provision Postgres {postgresVersion} database {name} in {region} on {provider}, size {size}, HA type {haType}, for organization {org}.
GET /v1/organizations/{organizationId}/postgres List managed Postgres services · List of organization Postgres services #
Ask an LLM
“Which managed Postgres databases do we run in ClickHouse Cloud?”
“Can I see all the Postgres services in my organization?”
Tell an agent
List all Postgres services in org {org}.
Show every managed PostgreSQL database in organization {org}.
GET /v1/organizations/{organizationId}/postgres/{postgresId} Get a Postgres service's details · Get PostgreSQL service details #
Ask an LLM
“What's the current status of one of my Postgres databases?”
“What size and HA type is a particular Postgres service running?”
Tell an agent
Show Postgres service {postgres} in org {org}.
Get the details of PostgreSQL database {postgres} in organization {org}.
DELETE /v1/organizations/{organizationId}/postgres/{postgresId} Delete a Postgres service · Delete a PostgreSQL service #
Ask an LLM
“How do I permanently delete a managed Postgres database?”
“Can I tear down a Postgres service I no longer need?”
Tell an agent destructive · confirm first
Delete Postgres service {postgres} in org {org}.
Permanently remove PostgreSQL database {postgres} from organization {org}.
PATCH /v1/organizations/{organizationId}/postgres/{postgresId} Rename or resize a Postgres service · Update a PostgreSQL service #
Ask an LLM
“How do I resize an existing Postgres database?”
“Does renaming a Postgres service change its host name and certificates?”
Tell an agent
Resize Postgres service {postgres} in org {org} to {size}.
Rename PostgreSQL database {postgres} in organization {org} to {name} and set HA type {haType}.
GET /v1/organizations/{organizationId}/postgres/{postgresId}/caCertificates Download a Postgres service's CA certificates · Get Postgres CA certs #
Ask an LLM
“Where do I get the CA certificate to connect to my Postgres database over TLS?”
“Can I download the certs needed to verify my Postgres server?”
Tell an agent
Download the CA certificates for Postgres service {postgres} in org {org}.
Get the TLS CA certs for PostgreSQL database {postgres} in organization {org}.
POST /v1/organizations/{organizationId}/postgres/{postgresId}/restoredService Restore a Postgres service to a new service · Restore a Postgres service #
Ask an LLM
“How do I restore my Postgres database to a specific point in time?”
“Can I recover a Postgres database from continuous backup into a new service?”
Tell an agent
Restore Postgres service {postgres} in org {org} into a new service {name} at restore target {restoreTarget}.
Do a point-in-time recovery of PostgreSQL database {postgres} in organization {org} to {restoreTarget}, naming it {name}.
PATCH /v1/organizations/{organizationId}/postgres/{postgresId}/password Reset a Postgres superuser password · Update Postgres superuser password #
Ask an LLM
“How do I reset the superuser password on my managed Postgres database?”
“Can I rotate the Postgres admin password through the API?”
Tell an agent
Set a new superuser password {password} on Postgres service {postgres} in org {org}.
Rotate the superuser password for PostgreSQL database {postgres} in organization {org}.
PATCH /v1/organizations/{organizationId}/postgres/{postgresId}/state Restart, promote or switch over a Postgres service · Update Postgres service state #
Ask an LLM
“How do I restart a managed Postgres database?”
“Can I promote a Postgres read replica to become the primary?”
Tell an agent
Restart Postgres service {postgres} in org {org}.
Run command {command} on PostgreSQL service {postgres} in organization {org}.
POST /v1/organizations/{organizationId}/postgres/{postgresId}/readReplica Create a read replica of a Postgres service · Create a read replica for a Postgres service #
Ask an LLM
“How do I add a read replica to offload reads from my Postgres database?”
“Can a Postgres read replica have its own configuration and tags?”
Tell an agent
Create a read replica named {name} of Postgres service {postgres} in org {org}.
Add read replica {name} tagged {tags} to PostgreSQL database {postgres} in organization {org}.
GET /v1/organizations/{organizationId}/postgres/{postgresId}/config Get Postgres and PgBouncer configuration · Get PostgreSQL service configuration #
Ask an LLM
“What Postgres parameters and PgBouncer settings is my database using?”
“How is connection pooling configured on my Postgres service?”
Tell an agent
Show the Postgres and PgBouncer configuration for service {postgres} in org {org}.
Get the current pg config of PostgreSQL database {postgres} in organization {org}.
POST /v1/organizations/{organizationId}/postgres/{postgresId}/config Replace all Postgres and PgBouncer configuration · Replace Postgres service configuration #
Ask an LLM
“How do I overwrite the entire Postgres and PgBouncer configuration at once?”
“Can I reset my database config by replacing it wholesale?”
Tell an agent
Replace the full config of Postgres service {postgres} in org {org} with pg config {pgConfig} and PgBouncer config {pgBouncerConfig}.
Overwrite all settings on PostgreSQL database {postgres} in organization {org} with {pgConfig} and {pgBouncerConfig}.
PATCH /v1/organizations/{organizationId}/postgres/{postgresId}/config Change some Postgres or PgBouncer settings · Update Postgres service configuration #
Ask an LLM
“How do I tweak a few Postgres parameters without replacing the whole config?”
“Can I adjust just the PgBouncer pool settings on my database?”
Tell an agent
Update Postgres service {postgres} in org {org}, merging pg config {pgConfig} and PgBouncer config {pgBouncerConfig}.
Tweak settings {pgConfig} and pooling {pgBouncerConfig} on PostgreSQL database {postgres} in organization {org}, leaving the rest.
GET /v1/organizations/{organizationId}/postgres/{postgresId}/metrics Get time-series metrics for a Postgres service · Get Postgres time-series metrics #
Ask an LLM
“How has my Postgres database's resource usage trended over the last day?”
“Can I choose the bucket size for Postgres time-series metrics?”
Tell an agent
Get metrics for Postgres service {postgres} in org {org} from {from_date} to {to_date}.
Chart PostgreSQL database {postgres} in organization {org} between {from_date} and {to_date} in {bucket_size_seconds}-second buckets.
GET /v1/organizations/{organizationId}/postgres/{postgresId}/slowQueryPatterns List the slowest query patterns on Postgres · List Postgres slow query patterns #
Ask an LLM
“Which queries are slowing down my Postgres database?”
“Can I narrow slow query patterns to one database, user or application?”
Tell an agent
List slow query patterns on Postgres service {postgres} in org {org} from {from_date} to {to_date}.
Show the slowest queries in database {db_name} run by {db_user} on {postgres} in organization {org} between {from_date} and {to_date}.
GET /v1/organizations/{organizationId}/postgres/{postgresId}/slowQueryPatterns/{queryId} Get one slow query pattern and recent runs · Get a Postgres slow query pattern with recent executions #
Ask an LLM
“What were the most recent executions of a particular slow query?”
“How long does one specific slow query pattern take on average?”
Tell an agent
Get slow query pattern {queryId} on Postgres service {postgres} in org {org} for database {db_name}, user {db_user}, operation {db_operation}.
Show recent executions of query {queryId} by {db_user} ({db_operation} on {db_name}) for {postgres} in organization {org}.
GET /v1/organizations/{organizationId}/postgres/{postgresId}/logs Search Postgres server logs · List Postgres server logs #
Ask an LLM
“How do I pull Postgres server logs for a time window?”
“Can I filter Postgres logs to errors or to lines containing some text?”
Tell an agent
Get server logs for Postgres service {postgres} in org {org} from {from_date} to {to_date}.
Find {severity} log lines containing {body_contains} on {postgres} in organization {org} between {from_date} and {to_date}.

Work with this as data

Every API here is available over the APIs.io API and to AI agents over MCP.

MCP server

One button, every client — Claude, Cursor, VS Code and the rest.

https://apis.io/mcp

Tools for apis

7 MCP tools reach this
  • find_apisBrowse and filter every API in the catalog.
  • get_api_artifactsOne API's artifacts, grouped by type.
  • get_openapiThe primary OpenAPI for this API.
  • find_similar_apisAPIs that look like this one.
  • apis_io_searchSTART HERE — APIs, providers and tags for one query, each with its total.
  • resolveTurn a domain, URL or GitHub org into the provider it belongs to.
  • find_cohortsEvery scored population of providers in the catalog.
All 92 tools →

Call it yourself

curl for this page
This API
curl "https://apis.io/api/v1/apis/clickhouse:clickhouse-postgres-api"
All apis
curl "https://apis.io/api/v1/apis?limit=25"

Discovery needs no key. Ratings and market analysis are Pro.

Get an API key

Free tier, no form to fill in. Signing in shares your email address with us — we store it to create your key and to recognise you if you sign in with another provider. See our Privacy Policy and Terms.

A second provider on the same verified email joins the account you already have.

OpenAPI Specification

clickhouse-postgres-api-openapi.yml Raw ↑
openapi: 3.2.0
info:
  title: OpenAPI spec for ClickHouse Cloud Postgres API
  version: '1.0'
  contact:
    name: ClickHouse Support
    url: https://clickhouse.com/docs/en/cloud/manage/openapi?referrer=openapi-1107336
    email: support@clickhouse.com
servers:
- url: https://api.clickhouse.cloud
security:
- basicAuth: []
tags:


# --- truncated at 32 KB (90 KB total) ---
# Full source: https://raw.githubusercontent.com/api-evangelist/clickhouse/refs/heads/main/openapi/clickhouse-postgres-api-openapi.yml