Connect Clickhouse to AI agents

Connect Clickhouse to Claude, Codex, Cursor, or other AI agents for your entire team. Metorial security, governance, observability, and gives your team a unified Magic MCP url to connect.

Supported Tools

list_backups

List Backups

List all backups for a ClickHouse service, with the most recent backups listed first. Includes backup status, timestamps, and size.

update_member

Update Member

Update an organization member's role or assigned roles. Use this to promote, demote, or change permissions for a member.

control_service_state

Control Service State

Start, stop, or wake an idle ClickHouse service. A service must be stopped before it can be deleted.

delete_query_endpoint

Delete Query Endpoint

Delete the query endpoint configuration for a service.

get_backup_configuration

Get Backup Configuration

Retrieve the current backup configuration for a service, including backup schedule and retention settings.

get_clickpipe_settings

Get ClickPipe Settings

Retrieve tunable settings for a ClickPipe.

update_clickstack_dashboard

Update ClickStack Dashboard

Update a ClickStack dashboard. The official API expects a full dashboard body including name and tiles.

update_clickpipe

Update ClickPipe

Update a ClickPipe's name, source, destination, field mappings, or settings. This uses the official ClickPipes PATCH endpoint.

list_clickstack_sources

List ClickStack Sources

List ClickStack data sources for a service. Source IDs are needed when creating or updating dashboard tiles.

update_api_key

Update API Key

Update a ClickHouse Cloud API key's name, state, role assignments, expiration, or IP allow list.

configure_clickpipe_scaling

Configure ClickPipe Scaling

Configure scaling for a Kafka, object storage, or streaming ClickPipe.

delete_service

Delete Service

Delete a ClickHouse service. The service **must be stopped** before deletion. Deletion is asynchronous and cannot be undone.

list_invitations

List Invitations

List all pending invitations for the organization. Shows who has been invited, their assigned roles, deprecated role, and expiration dates.

create_invitation

Create Invitation

Invite a new member to the organization by email. Specify the role and optional assigned role IDs.

upsert_query_endpoint

Upsert Query Endpoint

Create or update a query endpoint for a service. Query endpoints allow creating API endpoints directly from saved SQL queries. Supports parameterized queries, custom API key access, and CORS policies.

delete_invitation

Delete Invitation

Revoke a pending invitation. The invitee will no longer be able to join the organization using this invitation.

get_usage

Get Usage & Costs

Retrieve usage and cost information for the organization over a date range. Covers Storage, Compute, Data Transfer, ClickPipes, and Backup costs. Maximum queryable range is 31 days.

delete_api_key

Delete API Key

Permanently delete an API key. The key used to authenticate the current request cannot be deleted.

update_clickstack_alert

Update ClickStack Alert

Update a ClickStack alert. Pass the alert fields supported by the official ClickStack alert update request.

get_clickpipe

Get ClickPipe

Retrieve detailed information about a specific ClickPipe, including its source configuration, destination, state, and scaling settings.

create_api_key

Create API Key

Create a new API key for the organization. Specify the key name, permissions/roles, expiration, and optional IP restrictions. The key secret is only returned once — store it securely.

create_clickstack_dashboard

Create ClickStack Dashboard

Create a new ClickStack observability dashboard for a service. Dashboards can contain tiles with charts configured with SQL or Lucene queries and aggregation functions.

get_clickstack_dashboard

Get ClickStack Dashboard

Retrieve a ClickStack dashboard, including tiles, tags, filters, and saved query defaults.

get_organization

Get Organization

Retrieve the details of the ClickHouse Cloud organization, including its name, creation date, private endpoints, and BYOC configuration.

list_clickstack_alerts

List ClickStack Alerts

List all ClickStack alerts configured for a service. Alerts support webhook notifications to services like Slack and PagerDuty.

list_reverse_private_endpoints

List Reverse Private Endpoints

List all reverse private endpoints for a service. Reverse private endpoints allow ClickHouse Cloud to securely initiate connections to private customer resources.

get_service

Get Service

Retrieve detailed information about a specific ClickHouse service, including its state, scaling configuration, endpoints, IP access list, tags, and encryption settings.

delete_byoc_infrastructure

Delete BYOC Infrastructure

Delete a BYOC infrastructure from the organization.

create_service

Create Service

Create a new ClickHouse Cloud service. Specify the cloud provider, region, scaling settings, and other configuration. The response includes the generated database password — store it securely as it cannot be retrieved later.

list_api_keys

List API Keys

List all API keys in the organization. Shows key names, states, expiration dates, and assigned roles.

list_activities

List Activities

Retrieve the audit log of organization activities. Optionally filter by date range to see who performed what actions and when.

get_private_endpoint_config

Get Private Endpoint Config

Retrieve the private endpoint configuration for a specific service. Shows available private endpoint service IDs for connecting from your cloud VPC.

insert_rows

Insert Rows

Insert JSON object rows into a ClickHouse table over the HTTP interface using FORMAT JSONEachRow.

configure_scaling

Configure Scaling

Update the scaling configuration for a ClickHouse service. Adjust replica memory ranges, number of replicas, idle scaling behavior, and idle timeout.

get_api_key

Get API Key

Retrieve details for a ClickHouse Cloud API key. The key secret is not returned by the Cloud API after creation.

create_reverse_private_endpoint

Create Reverse Private Endpoint

Create a new reverse private endpoint for a service, enabling ClickHouse Cloud to securely connect to your private resources.

delete_clickstack_alert

Delete ClickStack Alert

Delete a ClickStack alert from a service.

configure_cdc_clickpipes_scaling

Configure CDC ClickPipes Scaling

Configure shared CPU and memory scaling for database CDC ClickPipes on a service.

run_query_endpoint

Run Query Endpoint

Execute a saved ClickHouse Cloud Query API endpoint using OpenAPI key Basic Auth. Supports endpoint versions, ClickHouse response formats, query variables, request timeout, and ClickHouse settings.

get_cdc_clickpipes_scaling

Get CDC ClickPipes Scaling

Retrieve shared scaling configuration for database CDC ClickPipes on a service.

list_tables

List Tables

List tables visible to the supplied ClickHouse database user, optionally scoped to one database.

get_clickstack_alert

Get ClickStack Alert

Retrieve a ClickStack alert, including state, schedule, threshold, and notification channel details.

list_clickpipes

List ClickPipes

List all ClickPipes (data ingestion pipelines) for a service. Shows pipeline names, states, scaling settings, and source configurations.

update_service

Update Service

Update a ClickHouse service's configuration, including its name, IP access list, tags, release channel, and endpoint settings. Use separate tools for scaling and state changes.

remove_member

Remove Member

Remove a member from the organization. This action is irreversible.

describe_table

Describe Table

Describe a ClickHouse table and return column metadata.

create_byoc_infrastructure

Create BYOC Infrastructure

Create new Bring Your Own Cloud (BYOC) infrastructure in the organization. BYOC lets you deploy ClickHouse services in your own cloud account.

delete_clickstack_dashboard

Delete ClickStack Dashboard

Delete a ClickStack dashboard from a service.

delete_reverse_private_endpoint

Delete Reverse Private Endpoint

Delete a reverse private endpoint from a service.

update_backup_configuration

Update Backup Configuration

Update the backup configuration for a service. Modify backup schedules, retention periods, and other backup settings.

update_byoc_infrastructure

Update BYOC Infrastructure

Update an existing BYOC infrastructure configuration, such as its display name.

get_prometheus_metrics

Get Prometheus Metrics

Retrieve Prometheus-format metrics for all services or a specific service. Includes metrics from system.metrics, system.events, and system.asynchronous_metrics. Idle services only return the ClickHouse_ServiceInfo gauge.

create_clickpipe

Create ClickPipe

Create a new ClickPipe data ingestion pipeline for a service. ClickPipes support sources like Apache Kafka, object storage, Amazon Kinesis, PostgreSQL, MySQL, BigQuery, and MongoDB. Provide the source configuration and destination table settings.

list_clickstack_dashboards

List ClickStack Dashboards

List all ClickStack observability dashboards for a service. ClickStack is the built-in observability platform for ClickHouse Cloud.

control_clickpipe_state

Control ClickPipe State

Change the state of a ClickPipe. Start, stop, or resync a data ingestion pipeline.

list_services

List Services

List all ClickHouse services in the organization. Optionally filter services by tags. Returns service names, states, cloud provider, region, scaling configuration, and endpoints.

execute_query

Execute Query

Execute a read-only SQL query against a ClickHouse service over the HTTP interface. Mutating statements are rejected; use insert_rows for inserts.

list_databases

List Databases

List databases available to the supplied ClickHouse database user via the HTTP interface.

delete_clickpipe

Delete ClickPipe

Delete a ClickPipe data ingestion pipeline from a service.

list_members

List Members

List all members in the organization. Returns each member's user ID, name, email, assigned roles, deprecated role, and join date.

get_backup

Get Backup

Retrieve details for a specific ClickHouse service backup.

update_clickpipe_settings

Update ClickPipe Settings

Replace tunable settings for a ClickPipe. The request body is passed to the official ClickPipe settings PUT endpoint.

list_clickstack_webhooks

List ClickStack Webhooks

List ClickStack webhook destinations for a service. Webhook IDs are needed for alert notification channels.

create_clickstack_alert

Create ClickStack Alert

Create a new ClickStack alert for a service. Alerts monitor metrics and send notifications via webhooks (Slack, PagerDuty, etc.) when thresholds are breached.

get_query_endpoint

Get Query Endpoint

Retrieve the query endpoint configuration for a service. Query endpoints expose saved SQL queries as HTTP API endpoints.

get_role

Get Role

Retrieve a ClickHouse Cloud organization role by ID.

list_roles

List Roles

List organization roles available for assignment to members and API keys.

More integrations teams use with Clickhouse

GitHub

Manage repositories, issues, and pull requests. Create and configure branches, star repositories, review code, and merge changes. Automate CI/CD workflows with GitHub Actions, manage workflow runs, secrets, and artifacts. Track issues with labels, milestones, and assignees. Search across code, repositories, issues, and users. Manage organizations, teams, and memberships. Create and manage projects, gists, packages, deployments, and environments. Access security alerts including code scanning, secret scanning, and Dependabot alerts. Read and write file contents in repositories. Manage webhooks, notifications, and codespaces.

Sharepoint

Manage SharePoint sites, document libraries, lists, and files. Create, read, update, and delete lists and list items with custom columns. Upload, download, move, copy, and version files in document libraries. Search across sites, files, folders, lists, and list items using Microsoft Search. Manage permissions at site, list, and item levels with granular access control. Define and manage content types and site columns. Subscribe to webhooks for list and library change notifications. Retrieve site properties and search for sites across Microsoft 365.

Salesforce

Manage CRM data including Accounts, Contacts, Leads, Opportunities, Cases, and custom objects. Create, read, update, and delete records. Query data using SOQL and search across objects using SOSL. Perform bulk data operations for large-scale imports, exports, and migrations. Execute composite requests to batch multiple operations in a single API call. Access analytics, reports, and dashboards. Manage files and attachments associated with records. Interact with Chatter feeds, posts, and groups for social collaboration. Subscribe to real-time change events via Change Data Capture and Platform Events. Manage org metadata including custom objects, fields, layouts, and workflows. Query data using GraphQL for precise data retrieval across related objects.

Airtable

Create, read, update, and delete records in Airtable bases and tables. Manage base schemas including creating tables and fields. Filter records using formulas, sort by fields, and scope queries to specific views. Upsert records to find, create, or update in a single call. Upload attachments to records, read and write record comments, list accessible bases, and receive real-time base change events through webhooks.

Bitbucket

Manage Git repositories, pull requests, and CI/CD pipelines on Bitbucket Cloud. Create, fork, and configure repositories within workspaces and projects. Create, review, approve, merge, and decline pull requests with inline code comments. Browse source code, list commits, and manage branches and tags. Track issues with the built-in issue tracker. Trigger, monitor, and manage Bitbucket Pipelines. List workspace members, configure repository default reviewers and branch restrictions, create and manage repository webhooks, and search code across repositories.

Heroku

Deploy, manage, and scale applications on Heroku's cloud platform. Create and configure apps, scale dynos, provision add-ons (databases, caching, etc.), manage configuration variables, build and release code, add custom domains and SSL certificates, manage collaborators and team permissions, configure pipelines for continuous delivery, set up log drains, and sync data with Salesforce via Heroku Connect. Subscribe to webhooks for real-time notifications on app changes, builds, releases, dyno lifecycle events, and more.

Technical notes for Clickhouse

Manage ClickHouse Cloud organizations, services, and infrastructure via the REST API. Create, start, stop, and delete analytical database services. Configure scaling policies, replicas, and resource allocation. Manage backups, API keys, and organization members. Create and manage ClickPipes data ingestion pipelines from sources like Kafka, S3, Kinesis, PostgreSQL, and MySQL. Set up query API endpoints from saved SQL queries. Manage private endpoints, retrieve usage and cost metrics, fetch Prometheus metrics, and configure BYOC (Bring Your Own Cloud) infrastructure. Create and manage observability dashboards, alerts, and webhook notifications via ClickStack.

Connect Clickhouse to production AI agents

See how Metorial gives Clickhouse access the governance, tracing, and security controls teams need.

Frequently asked questions

Common questions about connecting Clickhouse to AI agents with Metorial.

  1. Can Metorial connect Clickhouse to AI agents?
    Yes. Metorial connects AI agents to Clickhouse through a governed integration layer, so teams can use the provider while keeping access controlled and observable.
  2. Metorial is MCP compatible and lets teams expose approved provider tools to MCP-capable agents and clients through a controlled access layer.
  3. Metorial applies policies across users, groups, providers, agents, and individual tools, then records the context around every agent interaction.
  4. Yes. Metorial records provider activity so teams can inspect tool calls, troubleshoot integrations, and give security teams the visibility they need.