Coding & developmentArchitecturetext
Design a production-ready API
Produces an API contract with validation, errors, security, observability and test cases.
Ready to use
Prompt
Design a production-ready [REST/GRAPHQL/EVENT] API for [CAPABILITY]. Consumers are [CLIENTS]. The system of record is [DATA SOURCE].
Provide: resource model, endpoints or operations, example requests and responses, authentication and authorization, validation rules, idempotency, pagination, filtering, rate limits, error schema, audit events, observability, versioning and deprecation policy. Include threat cases, privacy boundaries and retry behaviour. Finish with an OpenAPI-style outline and acceptance tests.
Constraints and existing stack:
[CONSTRAINTS]
Do not invent infrastructure that conflicts with the stated stack. Mark unresolved design choices.