Conventions
Identifiers
Integer primary keys (1, 2, …) per collection. Foreign keys use the
<singular>Id camelCase pattern (userId, productId).
Naming
All JSON field names are camelCase. Collection identifiers in URLs are
kebab-case (e.g. /api/v1/order-items).
Timestamps
Every record has createdAt and updatedAt as ISO 8601 strings.
Pagination
List endpoints accept ?page=N&limit=M. Default limit is 25, max 100.
Responses include a meta object with page, limit, total, totalPages.
Sorting
?sort=field for ascending, ?sort=-field for descending.
Multi-key: ?sort=category,-price.
Filtering
- Exact match:
?status=delivered - Range:
?price_gte=10&price_lt=100 - In:
?status_in=pending,confirmed - Substring:
?title_like=spicy - Text search:
?q=…