Agent skill
tidbx-serverless-driver
Guidance for using the TiDB Cloud Serverless Driver (Beta) in Node.js, serverless, and edge environments. Use when connecting to TiDB Cloud Starter/Essential over HTTP with @tidbcloud/serverless, or when integrating with Prisma/Kysely/Drizzle serverless adapters in Vercel/Cloudflare/Netlify/Deno/Bun. Use this skill for serverless driver setup and edge runtime guidance.
Install this agent skill to your Project
npx add-skill https://github.com/pingcap/agent-rules/tree/main/skills/tidbx-serverless-driver
SKILL.md
TiDB Cloud Serverless Driver (Beta)
Use this skill to guide users who need the TiDB Cloud serverless driver (Beta) in serverless or edge environments.
Introduction
Serverless and edge runtimes often do not support long-lived TCP connections. Traditional MySQL drivers expect TCP, so they are a poor fit there. The TiDB Cloud serverless driver (Beta) uses HTTP instead, so it works in serverless and edge environments while keeping a similar developer experience.
Install
npm install @tidbcloud/serverless
Tutorials (References)
Use the reference file for the canonical driver overview, examples, configuration, and limitations. Load only what you need, and use the table of contents to jump to the right section:
- Source of truth:
references/serverless-driver.md
Usage Guidance
- Confirm the cluster type: Starter or Essential.
- Ask which runtime they use: Node.js, Vercel Edge, Cloudflare Workers, Netlify, Deno, Bun.
- Use the connection string from the TiDB Cloud console. In Connect, choose Serverless Driver, then generate/reset the password before copying
DATABASE_URL. - For provisioning or cluster CRUD, use the
tidbxskill.
Recommended Agent Skills
Expand your agent's capabilities with these related and highly-rated skills.
tidbx-kysely
Set up Kysely with TiDB Cloud (TiDB X), including @tidbcloud/kysely over the TiDB Cloud serverless HTTP driver for serverless or edge environments, plus standard TCP usage. Use for Kysely + TiDB Cloud connection setup, demo snippets, and environment-specific guidance.
pytidb
PyTiDB (pytidb) setup and usage for TiDB from Python. Covers connecting, table modeling (TableModel), CRUD, raw SQL, transactions, vector/full-text/hybrid search, auto-embedding, custom embedding functions, and reference templates/snippets (vector/hybrid/image) plus agent-oriented examples (RAG/memory/text2sql).
tidb-query-tuning
Diagnose and optimize slow TiDB queries using optimizer hints, session variables, join strategy selection, subquery optimization, and index tuning. Use when a query is slow, produces a bad plan, or needs performance guidance on TiDB.
tidbx-javascript-mysqljs
tidbx
Provision TiDB Cloud Serverless clusters and related resources. Use when creating, deleting, or listing clusters/branches, or managing SQL users via the console.
tidb-cloud-zero
Provision a disposable MySQL-compatible database instantly with no auth required. Includes a claim URL to convert Zero instances into regular TiDB Starter instances when the user needs persistence or more quota.
Didn't find tool you were looking for?