Agent skill · Backend & API

api-route

Generate API route handlers for Express or Analog.js

majiayu000github.com/majiayu000GitHub ↗
claude-codeMIT
Install
npx skills add majiayu000/claude-skill-registry --skill api-route-donaldmurillo-momentum-cms --agent claude-code

Same command for any agent — swap --agent for codex, cursor, copilot.

Facts
Files in the skill folder: 2
SKILL.md size: 2 KB
Bundled scripts: none
Path: skills/api/api-route-donaldmurillo-momentum-cms/SKILL.md
Open the folder on GitHub →
Where it comes from
Stars: 534
Language: HTML

Weekly change comes from our own snapshots, not the repository page — it measures attention, not adoption.

From the SKILL.md

# Generate API Route Create API route handlers for either Express (Angular SSR) or Analog.js. ## Arguments - First argument: Framework - "express" or "analog" - Second argument: Route name (e.g., "health", "custom-endpoint") ## For Express (Angular SSR) Create handler in `apps/cms-admin/src/api/<route-name>.ts`: ```typescript import { Router, Request, Response } from 'express'; import type { CollectionConfig } from '@momentumcms/core'; export function create<PascalName>Routes(collections: CollectionConfig[]): Router { const router = Router(); router.get('/<route-name>', async (req: Request, res: Response) => { try { // Implementation res.json({ success: true }); } catch (error) { res.status(500).json({ error: 'Internal server error' }); } }); return router; } ``` Register in `apps/cms-admin/src/server.ts`: ```typescript import { create<PascalName>Routes } from './api/<route-name>'; app.use('/api', create<PascalName>Routes(collections)); ``` ## For Analog.js Create file-based route in `src/server/routes/api/<route-name>.get.ts`: ```typescript import { defineEventHandler, getQuery } from 'h3'; export default defineEventHandler(async (event) => { const query = getQuery(event); try { /

What's inside
Steps it walks through
  1. Arguments
  2. For Express (Angular SSR)
  3. For Analog.js
  4. HTTP Method Suffixes (Analog.js)
  5. h3 Utilities
Ships with 1 file
  • metadata.json
More from claude-skill-registry
All skills →
About this skill
What does the api-route skill do?

Generate API route handlers for Express or Analog.js

How do I install it?

Run `npx skills add majiayu000/claude-skill-registry --skill api-route-donaldmurillo-momentum-cms --agent claude-code` — it drops the skill into your project so the agent can pick it up. Swap the --agent value for codex, cursor or copilot if you use one of those.

Where does this skill come from?

From majiayu000/claude-skill-registry, a repository with 534 stars. We read it straight from the repository tree rather than a submitted listing, so what you see here is what is actually published.

Is a popular skill a good skill?

Not necessarily. Stars measure attention, not adoption — a repository can trend for a week and be abandoned. That is why we show the weekly change from our own snapshots next to the total, instead of a single flattering number.

Keep going