smithery/terrylica

clickhouse-cloud-service-setup

Fetch ClickHouse Cloud service details from API (organization ID, service endpoints, configuration). Use when setting up new ClickHouse Cloud services, discovering endpoints, or validating service metadata for gapless-crypto-clickhouse project.

Installation

$ npx skills add smithery/terrylica --skill clickhouse-cloud-service-setup

Similar popular skills

Related neighbors and high-traction skills in the same topics — useful to compare before installing.

Also in this package

Other skills from smithery/terrylica · top by installs.

npx skills add smithery/terrylica

Browse all from smithery/terrylica

More details

Agent compatibility

Declared targets from SKILL.md / docs. Unmarked agents are not listed — the skill may still install via the CLI.

Claude Code Not declared
Cursor Not declared
Codex Not declared
GitHub Copilot Not declared
Windsurf Not declared
Gemini CLI Not declared
Cline Not declared
OpenCode Not declared

Package contents

Files included with this skill beyond the listing page.

  • skill md SKILL.md 5,361 B
  • docs SUMMARY.md 282 B

History

  1. First recorded snapshot · 0 installs

SKILL.md

ClickHouse Cloud Service Setup

Automate service metadata discovery via ClickHouse Cloud API for gapless-crypto-clickhouse project.

Purpose

Fetch and store ClickHouse Cloud service details using the ClickHouse Cloud REST API. This skill guides the workflow of:

  1. Authenticating with ClickHouse Cloud API
  2. Resolving Organization ID
  3. Fetching service metadata
  4. Extracting connection endpoints
  5. Storing configuration in Doppler

When to Use

Use this skill when:

  • Initial service provisioning: Setting up a new ClickHouse Cloud service
  • Service discovery: Finding endpoints and configuration for existing service
  • Endpoint resolution: Determining HTTPS (port 8443) or Native (port 9440) endpoints
  • Configuration validation: Verifying idle scaling, memory tier, IP access settings

Triggers: User mentions "ClickHouse Cloud service", "fetch service details", "organization ID", "service endpoints"

Prerequisites

Required Credentials (stored in Doppler aws-credentials/prd project):

  • CLICKHOUSECLOUDKEY_ID: API Key ID (format: xnIdJM3n42LDImsZ9zzg)
  • CLICKHOUSECLOUDKEY_SECRET: API Key Secret (secured in Doppler)

Service Context:

  • Service ID: <CLICKHOUSESERVICEID> (gapless-crypto-clickhouse service)
  • Organization: "<CLICKHOUSEORGNAME>"

Workflow

Step 1: Authenticate with ClickHouse Cloud API

# Retrieve API credentials from Doppler
KEY_ID=$(doppler secrets get CLICKHOUSE_CLOUD_KEY_ID --project aws-credentials --config prd --plain)
KEY_SECRET=$(doppler secrets get CLICKHOUSE_CLOUD_KEY_SECRET --project aws-credentials --config prd --plain)

API Authentication: HTTP Basic Auth with KEYID:KEYSECRET

Step 2: Resolve Organization ID

# Fetch organizations
curl -s -u "$KEY_ID:$KEY_SECRET" https://api.clickhouse.cloud/v1/organizations | jq -r '.[0].id'

Expected Output: UUID format (e.g., <CLICKHOUSEORGID>)

Store in Doppler:

doppler secrets set CLICKHOUSE_CLOUD_ORG_ID "<org_id>" --project aws-credentials --config prd

Step 3: Fetch Service Details

# Get service metadata
SERVICE_ID="<CLICKHOUSE_SERVICE_ID>"  # gapless-crypto-clickhouse service
ORG_ID=$(doppler secrets get CLICKHOUSE_CLOUD_ORG_ID --project aws-credentials --config prd --plain)

curl -s -u "$KEY_ID:$KEY_SECRET" \
  "https://api.clickhouse.cloud/v1/organizations/$ORG_ID/services/$SERVICE_ID" | jq '.'

Response Schema: See [references/api-endpoints.md](./references/api-endpoints.md)

Step 4: Extract Connection Endpoints

From API response, extract:

HTTPS Endpoint (recommended for clickhouse-connect):

  • Host: <CLICKHOUSESERVICEHOST>
  • Port: 8443

Native Protocol Endpoint (for clickhouse-client):

  • Host: <CLICKHOUSESERVICEHOST>
  • Port: 9440

Store in Doppler:

doppler secrets set CLICKHOUSE_HOST "<CLICKHOUSE_SERVICE_HOST>" --project aws-credentials --config prd
doppler secrets set CLICKHOUSE_PORT "8443" --project aws-credentials --config prd
doppler secrets set CLICKHOUSE_USER "default" --project aws-credentials --config prd

Step 5: Extract Service Configuration

Configuration Details:

  • Idle Scaling: Enabled (15 minutes timeout)
  • Memory Tier: 8-24 GB (development tier)
  • Region: us-west-2 (AWS)
  • ClickHouse Version: 25.8.1.8702
  • IP Access: 0.0.0.0/0 (open to world, consider restricting for production)

State Validation: Ensure service state is running

Success Criteria

  • ✅ Organization ID retrieved and stored in Doppler
  • ✅ Service details fetched successfully
  • ✅ Connection endpoints extracted (HTTPS 8443 confirmed)
  • ✅ Configuration parameters validated (idle scaling enabled, region us-west-2)
  • ✅ Service state confirmed as running

Troubleshooting

Issue: "Could not authenticate with ClickHouse Cloud API"

  • Check: Verify CLICKHOUSECLOUDKEYID and CLICKHOUSECLOUDKEYSECRET in Doppler
  • Verify: API keys not expired (check https://clickhouse.cloud/ → Settings → API Keys)

Issue: "Service not found"

  • Check: Verify service ID matches gapless-crypto-clickhouse service
  • Expected: <CLICKHOUSESERVICEID>

Issue: "Service state is not running"

References

Next Steps

After service setup, proceed to:

  1. [clickhouse-cloud-credentials](../clickhouse-cloud-credentials/SKILL.md) - Store all credentials in Doppler + 1Password
  2. [clickhouse-cloud-connection](../clickhouse-cloud-connection/SKILL.md) - Test connection to ClickHouse Cloud