convex-backend
Skill1.4k starsChanged 11 months agoMITView on GitHub
Convex backend development guidelines. Use when writing Convex functions, schemas, queries, mutations, actions, or any backend code in a Convex project. Triggers on tasks involving Convex database operations, real-time subscriptions, file storage, or serverless functions.
1 other project uses a version of this.
Trending
More talk lately.thin dataabout the whole repository
Most recently taken up by
- nilecui/SkillsBasetheir own version, first seen Dec 27, 2025
Who's talking about CloudAI-X/claude-workflow-v2
- @tom-doerr.bsky.social“https://github.com/CloudAI-X/claude-workflow-v2”Bluesky · Feb 21, 2026 · 1 likes
- LeszekKantorek/skills-library“Import: some development skills”GitHub · Oct 5, 2026
- sudosubin/agents.nix“codex-plugins.github.cloudai-x.claude-workflow-v2: init at 2.0.7”GitHub · Oct 4, 2026
- sudosubin/agents.nix“claude-code-plugins.github.cloudai-x.claude-workflow-v2: init at 2.0.7”GitHub · Oct 4, 2026
- sudosubin/agents.nix“claude-code-marketplaces.github.cloudai-x.claude-workflow-v2: init at 2.0.7”GitHub · Oct 4, 2026
The biggest 5 of 11 mentions linking to the repository that our crawl found. Each line is their own headline.
See all 11
Talked about on GitHub and Bluesky (11 times).
On GitHub · 10
- Oct 5, 2026Import: some development skills — LeszekKantorek/skills-library0 reactions · 1 comment
- Oct 4, 2026codex-plugins.github.cloudai-x.claude-workflow-v2: init at 2.0.7 — sudosubin/agents.nix0 reactions
- Oct 4, 2026claude-code-plugins.github.cloudai-x.claude-workflow-v2: init at 2.0.7 — sudosubin/agents.nix0 reactions
- Oct 4, 2026claude-code-marketplaces.github.cloudai-x.claude-workflow-v2: init at 2.0.7 — sudosubin/agents.nix0 reactions
- Oct 3, 2026agent-skills.github.cloudai-x.claude-workflow-v2: 0-unstable-2026-06-02 → 2.0.7 — sudosubin/agents.nix0 reactions
5 more on GitHub
- Sep 26, 2026[Candidate] cloudai-x/claude-workflow-v2/skills/convex-backend - convex-backend — ProSkillsMD/proskills0 reactions · 2 comments
- Sep 26, 2026[Candidate] cloudai-x/claude-workflow-v2/skills/analyzing-projects - analyzing-projects — ProSkillsMD/proskills0 reactions · 1 comment
- Sep 26, 2026agent-skills.github.cloudai-x.claude-workflow-v2: init at 0-unstable-2026-06-02 — sudosubin/agents.nix0 reactions
- Apr 6, 2026Audit candidate: CloudAI-X/claude-workflow-v2 — xiaolai/nlpm0 reactions · 3 comments
- Jan 10, 2026New plugins: 41 skills from skills (low risk) — aiskillstore/marketplace0 reactions
On Bluesky · 1
- Feb 21, 2026https://github.com/CloudAI-X/claude-workflow-v2 — @tom-doerr.bsky.social1 likes and repost
Other versions1 project uses a version of this.
Word for word · 0
None found.
Edited · 0
None found.
Wrote their own version · 1
- nilecui/SkillsBase★ 27same name
How matches are found. Word for word: the exact same text. Edited: shares passages with this file (“99% same” means 99% of its five-word phrases also appear here; 10% or more counts). Their own version: similar meaning, or, weakest, the same name. We can’t tell which project had it first. Projects are counted among the 200 most-starred candidates, and mentions are links to the repository we found, up to 50 per site, so both counts are a floor.
In this repository16 other files it gives its agents.
- skills/convex-backend/AGENTS.mdAGENTS.md
- skills/vercel-react-best-practices/AGENTS.mdAGENTS.md
- CLAUDE.mdCLAUDE.md
- analyzing-projectsSkill
- database-designSkill
- designing-apisSkill
- designing-architectureSkill
- designing-testsSkill
- devops-infrastructureSkill
- error-handlingSkill
- managing-gitSkill
- optimizing-performanceSkill
- parallel-executionSkill
- security-patternsSkill
- vercel-react-best-practicesSkill
- web-design-guidelinesSkill
The file
We split this skill into the rules it gives an agent
3 rules. About 0 are common, 1 is distinctive, and 2 are very specific to this project.
≈0
Common · estimate
Many files like this have a rule of this kind.
≈1
Distinctive · estimate
This author's own choices. Worth a look.
2
Very specific
Tied to their project's names, files or tools. Probably skip.
- Common
- Distinctive
- Very specific
- Very specific: line 111
Use
v.null()for void returns: - never omit return validator - Very specific: line 114
Actions cannot access
ctx.db: - use runQuery/runMutation instead - Distinctive: line 115
Include type annotations: when calling functions in same file
≈ “Common” is an estimate: at least 1 in 5 of the 213,897 skill files we read have a rule of the same kind, not the same words. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.
Files
Convex Backend Guidelines
When to Load
- Trigger: Convex-specific development, writing Convex functions, schemas, queries, mutations, actions, or real-time subscriptions
- Skip: Project does not use Convex as its backend
Comprehensive guide for building Convex backends with TypeScript. Covers function syntax, validators, schemas, queries, mutations, actions, scheduling, and file storage.
When to Apply
Reference these guidelines when:
- Writing new Convex functions (queries, mutations, actions)
- Defining database schemas and validators
- Implementing real-time data fetching
- Setting up cron jobs or scheduled functions
- Working with file storage
- Designing API structure
Rule Categories
| Category | Impact | Description |
| Function Syntax | CRITICAL | New function syntax with args/returns/handler |
| Validators | CRITICAL | Type-safe argument and return validation |
| Schema Design | HIGH | Table definitions, indexes, system fields |
| Query Patterns | HIGH | Efficient data fetching with indexes |
| Mutation Patterns | MEDIUM | Database writes, patch vs replace |
| Action Patterns | MEDIUM | External API calls, Node.js runtime |
| Scheduling | MEDIUM | Crons and delayed function execution |
| File Storage | LOW | Blob storage and metadata |
Quick Reference
Function Registration
// Public functions (exposed to clients)
import { query, mutation, action } from "./_generated/server";
// Internal functions (only callable from other Convex functions)
import {
internalQuery,
internalMutation,
internalAction,
} from "./_generated/server";Function Syntax (Always Use This)
export const myFunction = query({
args: { name: v.string() },
returns: v.string(),
handler: async (ctx, args) => {
return "Hello " + args.name;
},
});Common Validators
| Type | Validator | Example |
| String | v.string() | "hello" |
| Number | v.number() | 3.14 |
| Boolean | v.boolean() | true |
| ID | v.id("tableName") | doc._id |
| Array | v.array(v.string()) | ["a", "b"] |
| Object | v.object({...}) | {name: "x"} |
| Optional | v.optional(v.string()) | undefined |
| Union | v.union(v.string(), v.number()) | "x" or 1 |
| Literal | v.literal("status") | "status" |
| Null | v.null() | null |
Function References
// Public functions
import { api } from "./_generated/api";
api.example.myQuery; // convex/example.ts → myQuery
// Internal functions
import { internal } from "./_generated/api";
internal.example.myInternalMutation;Query with Index
// Schema
messages: defineTable({...}).index("by_channel", ["channelId"])
// Query
await ctx.db
.query("messages")
.withIndex("by_channel", (q) => q.eq("channelId", channelId))
.order("desc")
.take(10);Key Rules
- Always include
argsandreturnsvalidators on all functions - Use
v.null()for void returns - never omit return validator - Use
withIndex()notfilter()- define indexes in schema - Use
internalQuery/Mutation/Actionfor private functions - Actions cannot access
ctx.db- use runQuery/runMutation instead - Include type annotations when calling functions in same file
Full Compiled Document
For the complete guide with all rules and detailed code examples, see AGENTS.md.
Does it work?
Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.
No reviews yet
People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.
- It worked
- Partly
- It didn't
Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.
Your trail
Files you open will collect here, so you can find them again.
Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.
Now do this for your own.
Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.

