Skip to content

User Profile Management API

M♢NTΛSIM edited this page Aug 17, 2024 · 1 revision

User Profile Management API Documentation

Retrieve User Profile by Username

  • GET /{username}
    • Summary: Fetches the user profile based on the provided username. This endpoint respects the user's privacy settings and only returns information allowed under those settings.
    • Parameters:
      • Path Parameter:
        • Name: username
        • Description: The username of the user whose profile is being requested.
        • Schema:
          {
            "type": "string"
          }
    • Security: Bearer Authentication
    • Responses:
      • 200 OK:
        • Description: User profile retrieved successfully.
        • Content:
          • Content-Type: application/json
          • Schema:
            {
              "type": "object",
              "properties": {
                "username": {
                  "type": "string"
                },
                "email": {
                  "type": "string"
                },
                "bio": {
                  "type": "string"
                }
              },
              "example": {
                "username": "johndoe",
                "email": "johndoe@example.com",
                "bio": "Here is a little about me..."
              }
            }
      • 404 Not Found: User not found.
      • 403 Forbidden: Access to the profile is forbidden.
    • Tags:
      • User Profile Management

Handles Unsupported Methods

  • All Other Methods on /{username}
    • Summary: Handles unsupported methods for the endpoint.
    • Responses:
      • 405 Method Not Allowed: Method not supported.
    • Tags:
      • User Profile Management