/lunora:lunora-create-packagefrom Lunora
Builds a reusable Lunora capability as a registry item or workspace package, packaging schema, functions, wrangler bindings, and env vars for other apps.
Ships in Lunora. Installing the plugin adds it to Claude Code.
What the skill costs in Claude's context, stage by stage
Name and description: Claude knows it exists.
SKILL.md joins the conversation and stays.
None: SKILL.md is the whole skill.
Pick the shape by whether the code is copied into the user's lunora/ or
imported as a dependency:
| Shape | Distribution | Use for |
|---|---|---|
| Registry item | lunora registry add <name> | App-owned code (schema/functions) the user edits |
| Workspace pkg | import … from "@lunora/<name>" | Library code consumed as a versioned dependency |
Many capabilities use both: a @lunora/<name> package holds the runtime and a
registry item scaffolds the glue (files under lunora/<name>/, bindings, env
vars). auth, mail, ratelimit and storage follow this pattern.
Skip this skill for a one-off feature in a single app (write it in lunora/),
or when the capability already exists (lunora registry list).
An item is a directory registry/<name>/ holding registry.json, the source
files it copies, and a README.md. Validate against
registry/schema/registry-item.schema.json.
// registry/<name>/registry.json
{
"$schema": "../schema/registry-item.schema.json",
"name": "<name>",
"title": "Human Title",
"description": "One-paragraph summary shown in `lunora registry list`.",
"docs": "Post-install steps printed after `lunora registry add`.",
"requires": [], // other items, installed first (e.g. auth-clerk requires auth)
"deps": { "@lunora/server": "workspace:*" },
"devDependencies": {},
"bindings": [
// structural edits applied to wrangler.jsonc
{ "path": ["d1_databases"], "value": [{ "binding": "DB", "database_name": "REPLACE_ME-db", "database_id": "<replace-with-d1-create-id>" }] },
],
"envVars": [{ "name": "MY_SECRET", "description": "What it is and how to generate it.", "secret": true }],
"files": [
{ "from": "schema.ts", "to": "lunora/<name>/schema.ts", "merge": "schema-extension" },
{ "from": "<name>.ts", "to": "lunora/<name>/index.ts", "merge": "create-or-skip" },
],
}
files[].merge: create-or-skip writes whole files and never clobbers a file
the user edited; schema-extension AST-merges into lunora/schema.ts.envVars land in .dev.vars. Non-secret vars get their value; secrets get
an empty placeholder plus a wrangler secret put <NAME> reminder.entrypointReexports ([{ "module": "_generated/workflows" }]) injects
export * from './lunora/<module>' into the worker entry of framework
(class B/C) projects, for items whose generated classes the worker must
export. No shipped item uses it yet.#lunora/_generated/server.js, the
module codegen emits in a consumer project. registry/tsconfig.json stubs
that module so the item typechecks here.deps ranges are copied verbatim into the user's package.json. Use
workspace:* for @lunora/* (resolved at publish); any other range must
admit the version the workspace resolves, or pnpm install fails
(scripts/check-registry-catalog-ranges.js).Verify:
lunora registry build --from ./registry # regenerate registry/index.json from the item dirs
lunora registry build --from ./registry --check # CI: index is current
pnpm run lint:types:registry # tsc over every item (builds packages first)
pnpm run lint:registry:items # manifest + generated-deps tests
lunora registry view <name> --from <repo>/registry # preview
lunora registry add <name> --from <repo>/registry --dry-run # in a scratch app
registry/index.json is generated; do not hand-edit it.
vis generate lunora-package --name=search --description='Typed full-text search over Lunora tables' --category=add-on
Pass every option as --name=value; vis reads --name search as
--name=true plus a stray positional.
This writes packages/search/ with package.json (ESM-only,
"sideEffects": false, catalog versions), src/index.ts, tsconfig.json,
vitest.config.ts, packem.config.ts, eslint.config.js,
prettier.config.js, project.json (tags type:package +
category:<category>) and README.md. It does not create __tests__/ or
LICENSE.md, and no release config — vis release releases every non-private
package from the root vis.config.ts. Then:
cp packages/config/LICENSE.md packages/search/LICENSE.md (packem and
files expect it)..agents/docs/packages.md, and list the directory in one tier
of scripts/api-snapshot.js and the matching tier in ROADMAP.md. The
pnpm install postinstall checks (check-agents-md-packages,
check-roadmap-tiers) fail until both are done.pnpm install, then add tests under __tests__/.Repo conventions: relative imports without .js, named exports only (a
default only as a file's sole export), dependency versions via catalog:*
from pnpm-workspace.yaml.
Verify:
pnpm --filter "@lunora/search..." run build
pnpm --filter "@lunora/search" run lint:types
pnpm --filter "@lunora/search" run test
pnpm run lint:package-json
pnpm run api:update # writes api-snapshots/search.api.md from the fresh build; commit it
ctx.* capability into codegenCodegen decides which ctx.* fields exist by detecting usage, so a new
binding-backed helper is a literal row in CAPABILITY_ROWS
(packages/codegen/src/capabilities.ts; CAPABILITIES is a read-only view of
it): its package, ctx property, tier
("every" or "action"-only), ctx type fragment, ShardDO binding, and
defineApp method. Rate the feature for every target in the
PlatformCapabilities matrices in @lunora/platform
(packages/platform/src/capabilities/) as native, emulated or
unsupported in the same change. A feature a target leaves unrated is dropped
from that target's generated surface with a diagnostic. Declaration-gated
surfaces (flags, notify, containers, workflows, queues, agents) also have their
own emitters; some of them (flags, notify, containers, workflows) keep a row too,
for usage probing, so a row and a dedicated emitter can coexist.
Document in the README any lunora/*.ts declaration the user must add for
codegen to emit the typed surface.
What SKILL.md sets; muted values are Claude Code's defaults
Three short reads, in order
15 skills in this plugin
/lunoraRoutes general Lunora requests to the right Lunora skill and gives the shared mental model (codegen loop, generated `api`/`internal` references, review commands, add-on capabilities, the `@lunora/mcp` server). Use when the user asks which Lunora skill to use, gives an underspecified task in a project with a `lunora/` directory or `lunorash`/`@lunora/*` dependencies, asks to review or audit Lunora code, asks about an add-on without its own skill (queues, workflows, agents, AI, flags, payments, notifications), or wants to expose a deployment to an AI agent over MCP./lunora-cloudflare-auditAudits a Lunora app for Cloudflare cost and reliability risk before launch or after a surprise bill. Chains the read-only `lunora doctor`, `lunora advisor` and `lunora insights` signals, then traces what they cannot see — retry and fan-out loops, cron cadence, public routes that reach a metered product (Workers AI, Browser, Containers, Vectorize, R2, D1), preview environments with paid bindings, and missing usage alerts (`lunora cloudflare alerts`). Reports each finding with the billing meter it moves, the smallest fix, and how to verify. Use when the user asks to "audit before launch", "what could blow up our Cloudflare bill", "why did the bill spike", "is this safe to put on the public internet", or "review our cron / queue / AI / workflow cost". For a slow query or OCC conflict use `lunora-performance-audit`; for a failing deploy use `lunora-deploy`.npx claudepluginhub anolilab/lunora --plugin lunoraOther plugins' skills for the same job