crear-endpoint
Usar al crear un nuevo endpoint API en blueprints/main.py
npx skills add majiayu000/claude-skill-registry --skill crear-endpoint --agent claude-code
Same command for any agent — swap --agent for codex, cursor, copilot.
Weekly change comes from our own snapshots, not the repository page — it measures attention, not adoption.
## Cuándo usar esta skill - Al crear un nuevo endpoint `/api/[recurso]` - Cuando se necesite exponer datos de un servicio externo - Para añadir nuevas rutas al blueprint principal ## Contexto necesario antes de empezar 1. Leer `blueprints/main.py` para ver patrones existentes 2. Verificar si ya existe un cliente para el servicio 3. Comprobar configuración necesaria en `config.py` ## Pasos ### 1. Definir el endpoint - Ruta: `/api/[recurso]` - Método: GET (lectura), POST (crear), DELETE (eliminar) - Respuesta: JSON ### 2. Añadir configuración (si es necesario) ```python # En config.py, clase Config NUEVO_SERVICIO_URL = env_target('NUEVO_SERVICIO_URL', 'http://local', 'http://docker') NUEVO_SERVICIO_TOKEN = env_str('NUEVO_SERVICIO_TOKEN') ``` ### 3. Crear cliente (si hay API externa) - Usar skill `@crear-cliente` ### 4. Implementar endpoint en `blueprints/main.py` ```python @main_bp.route('/api/nuevo') @cache.cached(timeout=180) def api_nuevo(): """Descripción del endpoint""" try: url = current_app.config.get('NUEVO_SERVICIO_URL') token = current_app.config.get('NUEVO_SERVICIO_TOKEN') if not url: return jsonify({'error': 'NUEVO_SERVICIO_URL no configurado'}), 500 client = NuevoClient(
- Cuándo usar esta skill
- Contexto necesario antes de empezar
- Pasos
- 1. Definir el endpoint
- 2. Añadir configuración (si es necesario)
- 3. Crear cliente (si hay API externa)
- 4. Implementar endpoint en blueprints/main.py
- 5. Validar
- Checklist de validación
ruff check blueprints/main.py python -c "from app import app"
What does the crear-endpoint skill do?
Usar al crear un nuevo endpoint API en blueprints/main.py
How do I install it?
Run `npx skills add majiayu000/claude-skill-registry --skill crear-endpoint --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.
