What are the key factors to consider when designing a RESTful API?
- Consistency in naming and responses.
- Error handling with meaningful messages.
- Security (HTTPS, JWT, OAuth2).
- Scalability (statelessness, caching).
- Performance (pagination, filtering).
- Documentation (Swagger/OpenAPI).