Przejdź do treści
Biblioteka skilli
Programowanie · Planowanie

api-patterns

/api-patterns

Podpowiada wybór REST, GraphQL lub tRPC oraz odpowiedzi, wersjonowanie, uwierzytelnianie i limity zapytań.

Repozytorium
redevkit ↗
Licencja
MIT
Ostatnia zmiana repozytorium
12.11.2026

Ocena i bezpieczeństwo

90/ 100Klasa: dobry
Format25 / 25
Frontmatter z nazwą i opisem, poprawna nazwa, opis do 1024 znaków, nazwa zgodna z folderem.
Odkrywalność25 / 25
Opis mówi, kiedy użyć skilla, ma sensowną długość i jest w 3. osobie.
Treść25 / 35
Co najmniej 150 słów i do 500 linii, nagłówki, listy kroków, przykłady albo kod.
Higiena15 / 15
Bez zaślepek typu TODO, bez ścieżek Windows, z licencją.
Ryzykobrak sygnałów w skanie
Pliki w paczce
11
Skrypty
0
Komentarze HTML
0
Adresy URL w SKILL.md
0
Przestarzałość

Brak sygnałów. Repozytorium zmienione 12.11.2026, bez odwołań do wycofanych modeli i API.

Licencja

MIT, otwarta: można używać i zmieniać, z zachowaniem informacji o autorze.

Co robi i kiedy

Podpowiada wybór REST, GraphQL lub tRPC oraz odpowiedzi, wersjonowanie, uwierzytelnianie i limity zapytań.

Oryginalny opis (EN)

API design decisions - REST vs GraphQL vs tRPC, responses, versioning, auth, rate limits. Use when designing an API.

Jak działa

  1. Selective Reading Rule
  2. Content Map
  3. Related Skills
  4. Decision Checklist
  5. Anti-Patterns
  6. Audit
Sekcje z nagłówków SKILL.md, w oryginale · 73 linii, 414 słów
Podgląd SKILL.md
---
name: api-patterns
description: API design decisions - REST vs GraphQL vs tRPC, responses, versioning, auth, rate limits. Use when designing an API.
---

# API Patterns

> API design principles and decision-making.
> **Learn to THINK, not copy fixed patterns.**

## Selective Reading Rule

Read ONLY the references relevant to the request. Check the content map and open what you need.

## Content Map

| Reference | Description | When to read |
| --- | --- | --- |
| [api-style](references/api-style.md) | REST vs GraphQL vs tRPC decision tree | Choosing the API type |
| [rest](references/rest.md) | Resource naming, HTTP methods, status codes | Designing a REST API |
| [response](references/response.md) | Envelope pattern, error format, pagination | Response structure |
| [graphql](references/graphql.md) | Schema design, when to use, security | Considering GraphQL |
| [trpc](references/trpc.md) | TypeScript monorepo, type safety | TS full-stack projects |
| [versioning](references/versioning.md) | URI/Header/Query versioning | Planning API evolution |
| [auth](references/auth.md) | JWT, OAuth, Passkey, API keys | Choosing an auth pattern |
| [rate-limiting](references/rate-limiting.md) | Token bucket, sliding window | API protection |
| [documentation](references/documentation.md) | OpenAPI/Swagger best practices | Documentation |
| [security-testing](references/security-testing.md) | OWASP API Top 10, auth/authz testing | Security reviews |

## Related Skills

| Need | Skill |
| --- | --- |
| API implementation | `{{SKILL:nodejs-best-practices}}`, `{{SKILL:python-patterns}}` |
| Data structure | `{{SKILL:database-design}}` |
| Security details | `{{SKILL:vulnerability-scanner}}` |

## Decision Checklist

Before designing an API:

- [ ] **Asked about the API consumers?**
- [ ] **Chosen the API style for THIS context?** (REST/GraphQL/tRPC)
- [ ] **Defined a consistent response format?**
- [ ] **Planned the versioning strategy?**
- [ ] **Considered authentication needs?**
- [ ] **Planned rate limiting?**
- [ ] **Defined the documentation approach?**

## Anti-Patterns

**DON'T:**

- Default to REST for everything
- Use verbs in REST endpoints (`/getUsers`)
- Return inconsistent response formats
- Expose internal errors to clients
- Skip rate limiting

**DO:**

- Choose the API style based on context
- Ask about client requirements
- Document thoroughly
- Use appropriate status codes

## Audit

| Audit | Purpose |
| --- | --- |
| `api_validator.py` | API endpoint checks: OpenAPI specs, response formats, common issues |

In the verify command's audit step (not during implementation), when its orchestrator did not already run it, run `.redevkit/audits/api_validator.py <project_path>` with the Python interpreter detected
per `.redevkit/audits/README.md`. If no Python is available, the audit is
`SKIPPED (no Python)`: say so and fall back to the project's own commands (contract tests,
OpenAPI linting, the test suite). Never report a skipped audit as PASS.
Pliki w paczce (11)
  • SKILL.md 3 KB
  • references/api-style.md 1 KB
  • references/auth.md 1 KB
  • references/documentation.md 1 KB
  • references/graphql.md 1 KB
  • references/rate-limiting.md 1 KB
  • references/response.md 1 KB
  • references/rest.md 1 KB
  • references/security-testing.md 3 KB
  • references/trpc.md 1 KB
  • references/versioning.md 1 KB

Wersje

RepozytoriumWynikLicencja
Ta strona · Reprograme/redevkit90MIT
bybren-llc/safe-agentic-workflow100MIT
bybren-llc/safe-agentic-workflow100MIT
ThibautBaissac/rails_ai_agents100MIT
jeffersonvalente/cardume90MIT

Migawka bazy z 13.11.2026 · wersja paczki 48e4c36a3052 (skrót SHA-256 całej paczki)

Pobrania w ostatnich 30 dniach: 0 · ranking

Zgłoś problem z tym skillem: szkodliwa treść, błędny opis albo prośba autora o usunięcie.

Podobne skille

  • 100design-api
    Projektuje API REST i GraphQL: nazewnictwo, wersjonowanie, kształt błędów i uwierzytelnianie.
  • 100api
    Prowadzi projektowanie API REST, GraphQL i gRPC: wersjonowanie, kształt błędów, uwierzytelnianie, idempotencja, paginacja i limity, z wynikiem w postaci specyfikacji i szkieletu.
  • 100designing-apis
    Projektuje API REST i GraphQL, w tym endpointy, obsługę błędów, wersjonowanie i dokumentację, oraz ocenia kontrakty API.
  • 90api-design
    Podpowiada wzorce projektowania API: nazewnictwo REST, paginację, błędy, schematy GraphQL, strumienie gRPC i wersjonowanie.
  • 100api-design-expert
    Wspiera projektowanie API na poziomie eksperckim: REST, GraphQL, wersjonowanie i bezpieczeństwo, style API i dokumentacja.
  • 100trpc
    Pomaga budować typowane end-to-end API w tRPC: routery, procedury, middleware, kontekst i integrację z React Query oraz Next.js.

Uwagi i zgłoszenia

Wiadomość trafi do Bartosza Sokolińskiego. Adres e-mail jest potrzebny tylko do odpowiedzi. Szczegóły w polityce prywatności.