Get User Profile
User Management
Get User Profile
Retrieve the authenticated user profile information
POST
Get User Profile
Overview
This endpoint returns the profile information for the currently authenticated user. Authentication is required via JWT token.Authentication
This endpoint requires authentication. Include a valid JWT access token in the Authorization header:Request
Endpoint
Headers
Request Body
No request body required. The user is identified from the authentication token.Response
Success Response (200 OK)
Returns the user profile data serialized usingUsersSerializer:
Response Fields
Error Responses
401 Unauthorized
Returned when the authentication token is missing or invalid:404 Not Found
Returned when the authenticated user cannot be found in the database:500 Internal Server Error
Returned when an unexpected error occurs:Example Request
Example Response
Implementation Details
This endpoint is implemented in/apps/users/views.py:84 as the profile function view:
- Decorated with
@permission_classes([IsAuthenticated])to require authentication - Uses
UsersSerializerto serialize the user data fromrequest.user - Returns all fields from the Users model (which extends Django’s AbstractUser)
Related Endpoints
- Update Profile - Update user profile information
- Delete User - Delete user account
