Connection details
- ClickHouse
- PostgreSQL
To connect a client, you must create a Propel Application and give it the
DATAPOOL_QUERY scope.
ClickHouse clients and SDKs
ClickHouse HTTPS interface
The official HTTPS interface.
Python
The official Python client.
JavaScript
The official JavaScript client.
Go
The official Golang client.
Java
The official Java client.
Rust
The official Rust client.
ClickHouse HTTPS interface
The ClickHouse HTTPS interface provides a simple way to query Propel’s Serverless ClickHouse using HTTP requests. Since it uses standard HTTP, you can use it with:- Any programming language with HTTP support
- Command line tools like cURL
- API testing tools like Postman
Python
To get started with the ClickHouse Python client:1
Install the package
2
Import and create a client
3
Execute queries
APPLICATION_ID and APPLICATION_SECRET environment variables before running the application.
For more detailed documentation, refer to the ClickHouse Python client documentation.
JavaScript
The official JS client. It’s written in TypeScript and provides type definitions and has zero dependencies. Two versions are available:@clickhouse/clientfor Node.js@clickhouse/client-webfor browsers and Cloudflare workers
1
Install the package
- JavaScript
- JavaScript (web)
2
Import and create a client
- JavaScript
- JavaScript (web)
3
Execute queries
When using TypeScript, at least version 4.5+ is required.
APPLICATION_ID and APPLICATION_SECRET environment variables before running the application.
ClickHouse JS supports various query formats, data streaming, and advanced features like query cancellation and custom settings. For more detailed documentation, refer to the ClickHouse JS client documentation.
Go
To get started with the ClickHouse Go client:1
Install the ClickHouse Go driver
2
Import and create a connection
3
Execute queries
APPLICATION_ID and APPLICATION_SECRET environment variables before running the application.
For more detailed documentation, refer to the ClickHouse Go driver documentation.
Java
To get started with the ClickHouse Java client:1
Add the dependency
2
Connect to the database
3
Execute queries
APPLICATION_ID and APPLICATION_SECRET environment variables before running the application.
For more detailed documentation, refer to the ClickHouse Java client documentation.
Rust
To get started with the ClickHouse Rust client:1
Add the dependency
2
Create a client instance
3
Execute queries
- The
?fieldsplaceholder is replaced with the fields specified in the Row struct (no, namein the example above). - The
?placeholders are replaced with values from subsequentbind()calls in order. - Convenience methods
fetch_one::<Row>()andfetch_all::<Row>()are available to get a single row or all rows. - Use
sql::Identifierto safely bind table names.
PostgreSQL clients and SDKs
psql
The official PostgreSQL CLI.
Postgres.js
A full-featured client for Node.js.
psql (PostgreSQL CLI)
To get started with the PostgreSQL CLI, psql, follow the steps below.
Postgres.js
To get started with the Postgres.js client:1
Install the package
2
Create connection file
3
Set environment variables
Create
APPLICATION_ID and APPLICATION_SECRET environment variables with your actual credentials.4
Execute queries