Skip to main content

Player Profile API

Manage your user profile, update personal information, and configure preferences.

Get My Profile

Retrieve the authenticated user’s profile information.

Endpoint

GET /api/me

Response

id
string (UUID)
required
Unique identifier for the user
email
string
required
User’s email address
displayName
string
required
Display name shown to other users
description
string
User’s bio or description
phoneNumber
string
User’s phone number
avatarUrl
string
URL to the user’s avatar image
role
string
required
User role: PLAYER, OWNER, ADMIN
ownerRequestStatus
string
Status of venue owner role request: PENDING, APPROVED, REJECTED
preferredSport
string
Preferred sport: PADEL, TENNIS, PICKLEBALL
skillLevel
string
Player skill level: BEGINNER, INTERMEDIATE, ADVANCED, PROFESSIONAL
city
string
City where the user is located
countryCode
string
ISO country code (e.g., ES, US, FR)
onboardingCompleted
boolean
required
Whether the user has completed onboarding
lastLoginAt
string (timestamp)
Timestamp of the user’s last login
noShowCount
integer
required
Number of times the user didn’t show up to a match
matchBannedUntil
string (timestamp)
Timestamp until which the user is banned from match-making (if applicable)
matchNotificationsEnabled
boolean
required
Whether the user receives match invitation notifications

Example Request

curl -X GET "https://api.hub.example.com/api/me" \
  -H "Authorization: Bearer YOUR_JWT_TOKEN"

Example Response

{
  "id": "770e8400-e29b-41d4-a716-446655440002",
  "email": "[email protected]",
  "displayName": "Carlos Rodriguez",
  "description": "Passionate padel player looking for competitive matches!",
  "phoneNumber": "+34612345678",
  "avatarUrl": "https://cdn.hub.example.com/avatars/player123.jpg",
  "role": "PLAYER",
  "ownerRequestStatus": null,
  "preferredSport": "PADEL",
  "skillLevel": "INTERMEDIATE",
  "city": "Madrid",
  "countryCode": "ES",
  "onboardingCompleted": true,
  "lastLoginAt": "2026-03-08T10:30:00Z",
  "noShowCount": 0,
  "matchBannedUntil": null,
  "matchNotificationsEnabled": true
}

Update Profile

Update the authenticated user’s profile information.

Endpoint

PUT /api/me

Request Body

displayName
string
required
Display name (cannot be blank)
description
string
User bio or description
phoneNumber
string
Phone number
city
string
City of residence
countryCode
string
ISO country code
preferredSport
string
Preferred sport: PADEL, TENNIS, PICKLEBALL
skillLevel
string
Skill level: BEGINNER, INTERMEDIATE, ADVANCED, PROFESSIONAL
matchNotificationsEnabled
boolean
Enable or disable match invitation notifications

Response

Returns the updated user profile object (same structure as Get My Profile).

Example Request

curl -X PUT "https://api.hub.example.com/api/me" \
  -H "Authorization: Bearer YOUR_JWT_TOKEN" \
  -H "Content-Type: application/json" \
  -d '{
    "displayName": "Carlos Rodriguez",
    "description": "Experienced padel player, available for matches on weekends",
    "phoneNumber": "+34612345678",
    "city": "Madrid",
    "countryCode": "ES",
    "preferredSport": "PADEL",
    "skillLevel": "ADVANCED",
    "matchNotificationsEnabled": true
  }'

Example Response

{
  "id": "770e8400-e29b-41d4-a716-446655440002",
  "email": "[email protected]",
  "displayName": "Carlos Rodriguez",
  "description": "Experienced padel player, available for matches on weekends",
  "phoneNumber": "+34612345678",
  "avatarUrl": "https://cdn.hub.example.com/avatars/player123.jpg",
  "role": "PLAYER",
  "ownerRequestStatus": null,
  "preferredSport": "PADEL",
  "skillLevel": "ADVANCED",
  "city": "Madrid",
  "countryCode": "ES",
  "onboardingCompleted": true,
  "lastLoginAt": "2026-03-08T10:30:00Z",
  "noShowCount": 0,
  "matchBannedUntil": null,
  "matchNotificationsEnabled": true
}

Update Avatar

Update the user’s avatar image.

Endpoint

PATCH /api/me/avatar

Request Body

publicId
string
required
Public ID of the uploaded image (from your CDN/image service)
url
string
required
Public URL of the avatar image

Response

Returns the updated user profile object.

Example Request

curl -X PATCH "https://api.hub.example.com/api/me/avatar" \
  -H "Authorization: Bearer YOUR_JWT_TOKEN" \
  -H "Content-Type: application/json" \
  -d '{
    "publicId": "avatars/player123_v2",
    "url": "https://cdn.hub.example.com/avatars/player123_v2.jpg"
  }'
You’ll need to upload the image to your CDN or image hosting service first, then provide the public ID and URL to this endpoint. The Hub platform expects images to be already uploaded and accessible.

Request Owner Role

Submit a request to upgrade your account to a venue owner role.

Endpoint

POST /api/me/request-owner

Response

Returns 202 Accepted on success. Your request will be reviewed by administrators.

Example Request

curl -X POST "https://api.hub.example.com/api/me/request-owner" \
  -H "Authorization: Bearer YOUR_JWT_TOKEN"
After submitting a request, your profile’s ownerRequestStatus will change to PENDING. You’ll be notified once an administrator reviews your request. Once approved, you’ll gain access to venue management features.

Build docs developers (and LLMs) love