Agent skill

cmux Backend Rules

by manaflow-ai in manaflow-ai/cmux

Sets the backend TypeScript and Cloud VM rules for cmux: Effect-based services, thin route handlers, Postgres as source of truth, migrations and provider secrets.

Custom licenceAuto-check passedBackend & APIs

Install cmux Backend Rules

skills CLI
$ npx skills add manaflow-ai/cmux --skill cmux-backend -a claude-code

Project install by default; add -g for ~/.claude/skills/.

GitHub CLI
$ gh skill install manaflow-ai/cmux cmux-backend --agent claude-code

Project scope by default; add --scope user for a personal install. Needs GitHub CLI 2.90.0 or later (public preview).

Manual copy
$ git clone --depth 1 https://github.com/manaflow-ai/cmux.git skills-src && mkdir -p .claude/skills && cp -r skills-src/skills/cmux-backend .claude/skills/cmux-backend && rm -rf skills-src

Use ~/.claude/skills/ instead of .claude/skills for a personal install. The folder must contain SKILL.md.

Claude Code skills documentation · loads skills from .claude/skills/

Facts

Skill name
cmux-backend
GitHub stars
28k
Used in
1 other repo
Token cost
~682 tokens
SKILL.md length
288 words
Files
4 (incl. references)
Skills in repo
22
Repo updated
First seen
Licence
Custom licence

At a glance

Sets the backend TypeScript and Cloud VM rules for cmux: Effect-based services, thin route handlers, Postgres as source of truth, migrations and provider secrets.

  • Editing API routes or services under web/app/api and web/services
  • SKILL.md covers Core rules, Secrets and Detailed references
  • Calls bun; needs FREESTYLE_API_KEY
  • Changing the Cloud VM lifecycle or provider integrations

What it does

Backend TypeScript under web/app/api, web/services and provider-facing scripts defaults to Effect, with Next route handlers kept thin: parse the request, run one Effect program at the boundary, map typed errors to HTTP responses and treat unexpected defects separately. Plain TypeScript stays for trivial data shapes, constants, config files, frontend React and small glue where Effect adds ceremony.

Cloud VM logic lives in Vercel route handlers and Effect services backed by Postgres, which is the source of truth for VM lifecycle, active VM limits, idempotency and usage events. Production and staging use a PlanetScale PostgreSQL database read through DATABASE_URL, and migrations run with the cloud-vm migrate script for staging and then production, never from a Vercel build or route startup. Pricing gates use Stack Auth team payment items when enabled.

Provider secrets such as the Freestyle API key and R2 upload variables are read from a secrets env file in the home directory, loaded before local dev. Two reference notes cover Effect boundaries and the Cloud VM control plane.

When your agent uses it

  • Editing API routes or services under web/app/api and web/services
  • Changing the Cloud VM lifecycle or provider integrations
  • Writing or running Postgres migrations for Cloud VM data
  • Adding a Stack Auth pricing gate to VM creation

Example prompts

  • “Add a route that lists a user's active VMs, using an Effect program at the boundary.”
  • “Write the migration for a new VM usage events column and tell me how to run it for staging.”
  • “Update the VM create handler to respect the Stack Auth pricing gate.”

Requirements

  • Provider secrets in ~/.secrets/cmux.env
  • A Postgres database for Cloud VM state

What it can do on your machine

Read from SKILL.md and the folder at commit bbb3633. It shows what the files ask for, not the result of running them.

  • Tool permissions

    Pre-approves nothing: there is no allowed-tools line, so your agent's usual permission prompts apply.

    From allowed-tools in the SKILL.md frontmatter.

  • Runs code

    Shell commands in SKILL.md call:

    • bun

    From the folder's file list and the shell code blocks in SKILL.md.

  • Network

    No URLs in SKILL.md.

    From URLs in SKILL.md, links to its own repository left out.

  • Credentials

    Names these keys or tokens, usually read from environment variables:

    • FREESTYLE_API_KEY

    From names ending in _API_KEY, _TOKEN, _SECRET, _KEY or _PASSWORD in SKILL.md.

Context cost

cmux Backend Rules loads about 682 tokens when it runs, and up to ~1.7k if it reads all its reference files. Until then it costs about 64 tokens; SKILL.md has 288 words of instructions outside code blocks.

Always · name and description, kept in context so the agent knows when to use it
~64
When it runs · the whole SKILL.md, loaded when a task matches
~682
With references · SKILL.md plus every file in references/, read only if the agent opens them
~1.7k

Estimates: characters ÷ 4, the usual rule of thumb; real counts depend on the model's tokenizer. Scripts and assets cost tokens only if the agent reads them.

Safety

Auto-check passed

The automated check found no risky patterns in SKILL.md.

Automated static check — not a guarantee. Review scripts before installing. It scans the text of SKILL.md for risky patterns (piping downloads into a shell, reading credential files, hidden Unicode, destructive commands); files beside SKILL.md are not scanned.

SKILL.md

Its licence (Custom licence) doesn't allow us to republish the file, so here is its outline and opening line. It has 288 words (~682 tokens).

“Cloud VM build, test, and local dev scripts read provider secrets from ~/.secrets/cmux.env: FREESTYLE_API_KEY and the R2 upload vars web/scripts/build-cloud-vm-images.ts needs when creating Freestyle snapshots.”

— opening of SKILL.md by manaflow-ai, Custom licence
name
cmux-backend

Read the full SKILL.md on GitHub

Files

SKILL.md and 3 other files (references) in skills/cmux-backend of manaflow-ai/cmux.

  • SKILL.md
  • agents/openai.yaml
  • references/cloud-vm-control-plane.md
  • references/effect-boundaries.md

Open the folder on GitHubat commit bbb3633

Used in 1 other repository

We found 1 copy of this SKILL.md (exact, near-identical or edited) in other folders, from 1 other GitHub owner. This page covers the copy in manaflow-ai/cmux, which our catalogue first saw on October 7, 2026.

Compare with similar skills

cmux Backend Rules next to the 5 skills that share the most tags, products or categories with it. Stars are the repository's; “used in” counts other GitHub owners with a copy.

cmux Backend Rules compared with similar skills
SkillStarsUsed inTokensAuto-checkLicenceRepo updated
cmux Backend Rules this skillmanaflow-ai/cmux28k1 repos~682Automated safety check: PassCustom licence
Backend Guidelightly-ai/lightly-studio896—~1.2kAutomated safety check: PassApache-2.0
Fastapi Appccplugins/awesome-claude-code-plugins970—~1.1kAutomated safety check: NotesApache-2.0
Database Migrationsaffaan-m/ECC276k4 repos~3kAutomated safety check: PassMIT
Twenty Entity Runner Actionstwentyhq/twenty58k—~3.1kAutomated safety check: PassCustom licence
Node Backend Development Guidelinesdiet103/claude-code-infrastructure-showcase10k2 repos~2kAutomated safety check: PassMIT

Similar skills

  • Backend Guide

    lightly-ai/lightly-studio

    Read before adding or changing backend code in lightlystudio - FastAPI routes, services, resolvers, SQLModel tables, or database access.

    896 GitHub stars~1.2k tokensUpdated yesterday
    Backend & APIsAuto-check passed
  • Fastapi App

    ccplugins/awesome-claude-code-plugins

    Bootstrap a new FastAPI backend with async SQLAlchemy 2.0, asyncpg, Alembic, Pydantic v2, and no deprecated APIs.

    970 GitHub stars~1.1k tokensUpdated 1 mo ago
    Backend & APIsAuto-check: notes
  • Safe, reversible database migration patterns: forward-only production changes, expand-contract zero-downtime renames, concurrent indexes, batched backfills, and per-tool workflows for PostgreSQL…

    276k GitHub starsUsed in 4 repos~3k tokens
    DatabasesAuto-check passed
  • Step four of adding a syncable entity in the Twenty server: write create, update and delete action handlers that run workspace migrations against the database.

    58k GitHub stars~3.1k tokensUpdated today
    Backend & APIsAuto-check passed
  • Node Backend Development Guidelines

    diet103/claude-code-infrastructure-showcase

    Sets layered architecture and coding rules for Node.js, Express and TypeScript microservices, covering routes, controllers, services, repositories, Prisma, Sentry and Zod.

    10k GitHub starsUsed in 2 repos~2k tokens
    Backend & APIsAuto-check passed
  • Registers a new syncable entity in three NestJS modules and adds its service and GraphQL resolver layers when contributing to the Twenty server.

    58k GitHub stars~2.9k tokensUpdated today
    Backend & APIsAuto-check passed

More from manaflow-ai/cmux

All 22 skills in this repo
  • cmux Diagnostics

    manaflow-ai/cmux

    Runs a read-only health check for cmux and explains what it finds, covering the CLI and socket, settings, agent hooks, session restore and notifications.

    28k GitHub starsUsed in 1 repo~819 tokens
    Auto-check passed
  • cmux Settings Editor

    manaflow-ai/cmux

    Reads and changes cmux preferences in `~/.config/cmux/cmux.json` through a helper that validates each change before writing, covering terminal, browser, viewers and shortcuts.

    28k GitHub stars~2.3k tokensUpdated today
    Auto-check passed
  • Cmux Debugging Guide

    manaflow-ai/cmux

    Covers debug logging, the Debug menu, profiling rules and runtime pitfalls for working on the cmux macOS terminal app.

    28k GitHub starsUsed in 1 repo~1.1k tokens
    Auto-check passed
  • Workflow rules for the Ghostty submodule in cmux: rebuilding GhosttyKit.xcframework, pushing fork changes and updating the parent submodule pointer safely.

    28k GitHub starsUsed in 1 repo~580 tokens
    Auto-check passed
  • Cmux Release Workflow

    manaflow-ai/cmux

    Runs the cmux release process: gathers per-PR changelog lines since the last tag, bumps the version, guards against a bad tag, then tags and pushes the macOS DMG release.

    28k GitHub starsUsed in 1 repo~856 tokens
    Auto-check passed
  • Opens, inspects, and drives a browser surface through the cmux CLI without stealing the user's focus, always targeting an explicit surface handle.

    28k GitHub stars~2.7k tokensUpdated today
    Auto-check passed

Questions about cmux Backend Rules

What does cmux Backend Rules do?

Sets the backend TypeScript and Cloud VM rules for cmux: Effect-based services, thin route handlers, Postgres as source of truth, migrations and provider secrets. Backend TypeScript under web/app/api, web/services and provider-facing scripts defaults to Effect, with Next route handlers kept thin: parse the request, run one Effect program at the boundary, map typed errors to HTTP responses and treat unexpected defects separately. Plain TypeScript stays for trivial data shapes, constants, config files, frontend React and small glue where Effect adds ceremony.

When should I use cmux Backend Rules?

cmux Backend Rules fits situations like: editing API routes or services under web/app/api and web/services; changing the Cloud VM lifecycle or provider integrations; writing or running Postgres migrations for Cloud VM data; adding a Stack Auth pricing gate to VM creation.

How do I install cmux Backend Rules in Claude Code?

Run `npx skills add manaflow-ai/cmux --skill cmux-backend -a claude-code`. Or copy the skill folder (skills/cmux-backend in manaflow-ai/cmux) into .claude/skills/cmux-backend in your project. Claude Code loads it when a task matches its description.

How do I install cmux Backend Rules in Codex?

Run `npx skills add manaflow-ai/cmux --skill cmux-backend -a codex`. Or copy the skill folder (skills/cmux-backend in manaflow-ai/cmux) into .agents/skills/cmux-backend in your project. Codex loads it when a task matches its description.

Can I use cmux Backend Rules in Cursor, Gemini CLI or GitHub Copilot?

Cursor, Gemini CLI, GitHub Copilot and OpenCode also load SKILL.md folders. With the skills CLI, run `npx skills add manaflow-ai/cmux --skill cmux-backend -a cursor` (or -a gemini-cli, github-copilot or opencode for the others). To copy it by hand, put the folder in .cursor/skills/cmux-backend, .gemini/skills/cmux-backend, .github/skills/cmux-backend and .opencode/skills/cmux-backend in your project.

What does cmux Backend Rules need to run?

Going by SKILL.md and its folder, cmux Backend Rules needs the command-line tools its instructions call (bun) and credentials named FREESTYLE_API_KEY. Our summary lists: Provider secrets in ~/.secrets/cmux.env; A Postgres database for Cloud VM state.

Does cmux Backend Rules access the network?

SKILL.md contains no URLs. Any network use would come from the scripts or tools the agent runs. This is read from the text; nothing was executed.

Is cmux Backend Rules safe to install?

Our automated static check of SKILL.md found no risky patterns, such as piping downloads into a shell, reading credential files or hidden Unicode. It is not a guarantee. Review the folder before installing.

What licence does cmux Backend Rules use?

cmux Backend Rules has a licence file (the repository's licence) that doesn't match a standard licence. Read it on GitHub before reusing the skill.

How many tokens does cmux Backend Rules use?

About 682 tokens (SKILL.md is roughly 2.7k characters). Agents keep only the skill's name and description in context until a task matches; then they load SKILL.md in full. Its references folder adds about 1k tokens, read only when the agent opens those files.

What are the alternatives to cmux Backend Rules?

Skills that share tags, products or a category with cmux Backend Rules: Backend Guide (lightly-ai/lightly-studio, 896 stars), Fastapi App (ccplugins/awesome-claude-code-plugins, 970 stars), Database Migrations (affaan-m/ECC, 276k stars) and Twenty Entity Runner Actions (twentyhq/twenty, 58k stars). The comparison table on this page puts their stars, adoption, token cost, safety result and licence side by side.

Who maintains cmux Backend Rules?

manaflow-ai (a GitHub organization) maintains it in manaflow-ai/cmux, which has 28,076 GitHub stars. The repository holds 22 skills in this directory. The repository was last updated on October 10, 2026.

Source: manaflow-ai/cmux on GitHub. Facts on this page come from the repository at the commit we read; the author's words are quoted as theirs.