rest-api-design

Solid

Designs RESTful APIs with proper resource naming, HTTP methods, status codes, and response formats. Use when building new APIs, establishing API conventions, or designing developer-friendly interfaces.

API & Backend 162 stars 25 forks Updated 2 weeks ago MIT

Install

View on GitHub

Quality Score: 86/100

Stars 20%
74
Recency 20%
90
Frontmatter 20%
70
Documentation 15%
97
Issue Health 10%
80
License 10%
100
Description 5%
100

Skill Content

# REST API Design Design RESTful APIs with proper conventions and developer experience. ## Resource Naming ``` # Good - nouns, plural, hierarchical GET /api/users GET /api/users/123 GET /api/users/123/orders POST /api/users PATCH /api/users/123 DELETE /api/users/123 # Bad - verbs, actions in URL GET /api/getUsers POST /api/createUser POST /api/users/123/delete ``` ## HTTP Methods | Method | Purpose | Idempotent | |--------|---------|------------| | GET | Read resource | Yes | | POST | Create resource | No | | PUT | Replace resource | Yes | | PATCH | Partial update | Yes | | DELETE | Remove resource | Yes | ## Status Codes | Code | Meaning | Use For | |------|---------|---------| | 200 | OK | Successful GET, PATCH | | 201 | Created | Successful POST | | 204 | No Content | Successful DELETE | | 400 | Bad Request | Validation errors | | 401 | Unauthorized | Missing auth | | 403 | Forbidden | Insufficient permissions | | 404 | Not Found | Resource doesn't exist | | 429 | Too Many Requests | Rate limited | ## Response Format ```json { "data": { "id": "123", "type": "user", "attributes": { "name": "John", "email": "john@example.com" } }, "meta": { "requestId": "req_abc123" } } ``` ## Collection Response ```json { "data": [...], "pagination": { "page": 1, "limit": 20, "total": 150, "totalPages": 8 }, "links": { "self": "/api/users?page=1", "next": "/api/users?page=2" } } ``` ## ...

Details

Author
secondsky
Repository
secondsky/claude-skills
Created
6 months ago
Last Updated
2 weeks ago
Language
TypeScript
License
MIT

Integrates with

Similar Skills

Semantically similar based on skill content — not just same category