Implement auth and profile APIs
SpeakSoftware Engineer · OnsiteLast updated
This question evaluates backend API design competencies such as authentication and bearer-token access control, user profile data modeling, input validation, error handling, and state management for an in-memory service within the System Design category.
Implement an in-memory HTTP API for user authentication and profile management. Support: register (email + password), authenticate (login), retrieve and update a user profile, and delete a user account. Model the data structures you would use, define request/response schemas, and outline basic validation and error handling. Assume password hashing is a mocked placeholder and no database is needed; focus on an MVP. Provide example endpoints and discuss trade-offs and how you’d extend it later (sessions/tokens, password resets, audit logs).
Solution walkthrough is for members
Get the full walkthrough with reference code and complexity analysis, plus Kitty Coach at 300 messages a day. Hints, the code runner and community answers stay free.