Skip to main content

Get Player Info

Get detailed information about an Xbox Live player by their gamertag.

Endpoint

GET /api/xbox/{gamertag}

Path Parameters

gamertag
string
required
Xbox Live gamertag

Example Request

cURL
curl -X GET "https://rocks.rive.wtf/api/xbox/MajorNelson" \
  -H "Authorization: Bearer YOUR_API_KEY"
JavaScript
const response = await fetch('https://rocks.rive.wtf/api/xbox/MajorNelson', {
  headers: {
    'Authorization': 'Bearer YOUR_API_KEY'
  }
});

const data = await response.json();
console.log(data);
Python
import requests

headers = {'Authorization': 'Bearer YOUR_API_KEY'}

response = requests.get(
    'https://rocks.rive.wtf/api/xbox/MajorNelson',
    headers=headers
)

print(response.json())

Response Example

{
  "avatar": "https://avatar-ssl.xboxlive.com/avatar/Major Nelson/avatarpic-l.png",
  "id": "2584878536129841",
  "meta": {
    "accountTier": null,
    "bio": "",
    "gamerscore": "143771",
    "reputation": null,
    "tenure": null,
    "tier": null
  },
  "username": "Major Nelson"
}

Response Fields

avatar
string
URL to the player’s Xbox Live avatar image
id
string
Xbox User ID (XUID) - unique identifier for the player
username
string
The player’s Xbox Live gamertag
meta
object
Additional metadata about the player’s account
Privacy settings on Xbox Live profiles may limit the information available through the API. Some users may have restricted profile visibility, which can result in null values for certain fields.
The gamerscore field is returned as a string. Make sure to parse it as a number if you need to perform numerical operations.