cloudbase-rules

A routing guide for CloudBase development rules, telling an AI coding assistant which local instructions and existing application code to inspect.

In plain words
What is it for?
Use it when implementing or fixing existing CloudBase applications, especially login, CRUD operations, routes, and service handlers.
Why use it?
It prevents unrelated exploration and helps changes follow the project's established routes, services, authentication, and handlers.

Cursor rule

Install

Getting it into your agent

One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.

agentmods
npx agentmods add rules/tencentcloudbase/cloudbase-ai-toolkit/cloudbase-rules
Clone the repo
git clone --depth 1 https://github.com/TencentCloudBase/CloudBase-AI-Toolkit
Per session 2,664 This file is loaded in full into every session.
When invoked 2,664 The same file — it is already loaded in full.
Security scan A 0 findings. Scan, not verified.
Origin original No closer match found in the catalogue.
Token cost

What it costs to keep this loaded

Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.

ModelPer sessionOnce invoked
Fable 5 $0.02664 $0.02664
Opus 5 $0.01332 $0.01332
Sonnet 5 $0.00533 $0.00533
Haiku 4.5 $0.00266 $0.00266

Measured yesterday against content hash f7246e531485, method: parsed. Prices are Anthropic first-party input rates as of 2026-08-30, from the pricing page.

Security

Grade A, and why

cloudbase-rules scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured yesterday.

A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.

Nothing flagged

None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.

config/source/editor-config/guides/cloudbase-rules.mdc · 141 lines

How it starts

The opening of the file, as written. The whole thing — 141 lines — stays where its author put it; the contents beside it link to each section on GitHub.

CloudBase AI Development Rules Guide

Activation Contract

This file is a compatibility projection of the CloudBase routing contract. Keep semantics aligned with the CloudBase source guideline. Prefer stable skill identifiers; load full skill bodies on demand (local rules/ / .codebuddy/skills/ / searchKnowledgeBase(mode="skill")) — do not expand this entry into a full skill dump.

Existing Implementation First

When the workspace already has an application with TODOs, fixed routes, or pre-created pages/services:

  • Do not start with ui-design / visual exploration unless the user asks for redesign.
  • Do not broad-read unrelated skills first.
  • Inspect surfaces that already own the flow (src/lib/backend.*, auth.*, *service.*, route guards, submit handlers).
  • Prefer patching TODOs in-place over parallel helpers or detached demos.
  • Login + CRUD: inspect → verify providers if needed → patch active handlers → validate.

Path resolution

When this document references {skill-id} or a rule name, resolve in order:

  1. .codebuddy/skills/{skill-id}/SKILL.md or .claude/skills/{skill-id}/SKILL.md
  2. .codebuddy/rules/tcb/rules/{skill-id}/rule.md
  3. rules/{skill-id}/rule.md (or rules/{skill-id}/SKILL.md)
  4. Search: *{skill-id}*SKILL.md / *{skill-id}*rule.md

Files already written as rules/... work across editors.

Shorthand Skill / rule id
auth-tool auth-tool-cloudbase
auth-web auth-web-cloudbase
auth-wechat auth-wechat-miniprogram
auth-nodejs auth-nodejs-cloudbase
web-development web-development
miniprogram-development miniprogram-development
cloudrun-development cloudrun-development
cloud-functions cloud-functions
http-api http-api-cloudbase
no-sql-web-sdk cloudbase-document-database-web-sdk
no-sql-wx-mp-sdk cloudbase-document-database-in-wechat-miniprogram
relational-database-tool relational-database-mcp-cloudbase
relational-database-web relational-database-web-cloudbase
postgresql-development postgresql-development-cloudbase
cloud-storage-web cloud-storage-web
ui-design ui-design
minimal-web-baas-demo minimal-web-baas-demo
cloudbase-platform cloudbase-platform
spec-workflow spec-workflow

Read the full file on GitHub · 141 lines

Changes

What this file has done since we first saw it

Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.

  1. yesterday First seen · 141 lines · 2,664 tokens per session scan A f7246e531485

Subscribe to this mod's changes

cloudbase-rules is a cursor rule published in the GitHub repository TencentCloudBase/CloudBase-AI-Toolkit (1,087 stars, last pushed yesterday), licensed MIT. It adds 2,664 tokens to every session, about $0.0133 per session on Opus 5. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-30.