L
laravel:api-surface-evolution
About laravel:api-surface-evolution
A Laravel skill for evolving APIs while preserving released client contracts. It covers versioning, DTO transformations, deprecation practices, and compatibility testing.
Key features
- 01URI or header-based versioning
- 02Versioned DTOs and transformers
- 03Deprecation timelines and usage metrics
- 04Contract and backward-compatibility tests
Use cases
- 01Adding API fields without breaking clients
- 02Managing deprecated fields across API versions
- 03Verifying request and response contracts
Install
Copy the command and run it in a terminal.
$
npx skills add https:/ / github.com/ jpcaparas/ superpowers-laravel --skill laravel:api-surface-evolutionAfter installing, type/laravel:api-surface-evolutionin Claude Code to confirm it loaded.
Details
From the project READMEAPI Surface Evolution
Design for change without breaking clients.
Versioning Strategy
- Choose explicit versioning (URI
/v1/...or header negotiation) - Default to additive changes; never break a released contract
DTOs & Transformers
- Define versioned DTOs; map from models/services via transformers
- Keep controller thin—validate → transform → respond
Deprecations
- Mark fields as deprecated in docs and responses (e.g., headers)
- Provide sunset timelines; add metrics to see remaining usage
Testing
- Contract tests per version (request/response shapes)
- Backward compatibility tests for commonly used flows
Comments
Markdown supported