Skip to main content

Get Current User

Retrieve information about the currently authenticated user.

Endpoint

GET /api/me

Headers

Authorization
string
required
Bearer token for authentication

Response

user
object
User information

Example Request

curl https://your-umami-instance.com/api/me \
  -H "Authorization: Bearer YOUR_TOKEN"

Example Response

{
  "user": {
    "id": "660e8400-e29b-41d4-a716-446655440001",
    "username": "john.doe",
    "role": "admin",
    "createdAt": "2024-01-10T08:00:00.000Z"
  }
}

User Roles

admin
Full system access including:
  • Manage all websites
  • Manage all teams
  • Manage all users
  • Access all analytics data
  • System configuration
user
Standard user access:
  • Manage own websites
  • Create and join teams
  • View team resources based on team role
  • Cannot manage other users

Use Cases

  • Verify authentication status
  • Display user information in UI
  • Check user permissions
  • Validate token before making other API calls

Error Responses

401
error
Unauthorized - Invalid or expired token
This endpoint returns the user information associated with the provided Bearer token. Use this to verify authentication and retrieve the current user’s details.

Build docs developers (and LLMs) love