Connections

Create Connection

Creates a new ClickHouse connection

post/api/v2/connections

Request body

namestring required

Display name for the connection.

hoststring required

ClickHouse HTTP endpoint URL.

usernamestring required

ClickHouse username.

passwordstring

ClickHouse password. Never returned by the API.

hyperdxSettingPrefixstring nullable

Optional prefix for HyperDX-specific ClickHouse settings. Must only contain alphanumeric characters and underscores.

prometheusEndpointstring

Optional Prometheus-compatible API endpoint. When set, PromQL queries are proxied to this endpoint.

Example request

{
  "name": "Production ClickHouse",
  "host": "https://clickhouse.example.com:8443",
  "username": "default",
  "password": "my-secret-password",
  "hyperdxSettingPrefix": "hyperdx_",
  "prometheusEndpoint": "http://prometheus:9090"
}

Response

Successfully created connection

Example response

{
  "data": {
    "id": "507f1f77bcf86cd799439012",
    "name": "Production ClickHouse",
    "host": "https://clickhouse.example.com:8443",
    "username": "default",
    "hyperdxSettingPrefix": "hyperdx_",
    "prometheusEndpoint": "http://prometheus:9090",
    "createdAt": "2025-01-01T00:00:00.000Z",
    "updatedAt": "2025-06-15T10:30:00.000Z"
  }
}

Changes