Endpoints
Authenticated endpoints require Authorization: Bearer <API_KEY>. Demo endpoints (below) are public and do not need a key.
curl -H "Authorization: Bearer <API_KEY>" \
https://api.baselinerank.com/me
{
"org": "Acme Tennis Agency",
"plan": "starter",
"rate_limit_per_minute": 600,
"usage": {
"this_month": 1842,
"today": 47
},
"top_endpoints": [
{ "path": "/players/a0e2", "count": "312" },
{ "path": "/rankings", "count": "204" }
],
"key_created_at": "2026-03-01T10:00:00Z",
"last_used_at": "2026-04-05T08:22:11Z",
"renewal_date": "2026-05-01"
}
curl -H "Authorization: Bearer <API_KEY>" \
"https://api.baselinerank.com/rankings?limit=10"
{
"data": [
{ "atp_id": "s0ag", "name_short": "J. Sinner", "country": "Italy", "rank": 1, "points": 10400, "movement": null },
{ "atp_id": "a0e2", "name_short": "C. Alcaraz", "country": "Spain", "rank": 2, "points": 13550, "movement": null },
{ "atp_id": "z355", "name_short": "A. Zverev", "country": "Germany","rank": 3, "points": 4555, "movement": null }
],
"meta": { "count": 3, "type": "singles", "updated_at": "2026-06-01" }
}
curl -H "Authorization: Bearer <API_KEY>" \
https://api.baselinerank.com/rankings/doubles
{
"data": [
{ "atp_id": "va08", "name_short": "A. Vavassori", "country": "Italy", "rank": 17, "updated_at": "2026-03-02" },
{ "atp_id": "mo55", "name_short": "L. Miedler", "country": "Austria", "rank": 22, "updated_at": "2026-03-02" }
],
"meta": { "count": 2, "type": "doubles", "updated_at": "2026-03-02" }
}
curl -H "Authorization: Bearer <API_KEY>" \
"https://api.baselinerank.com/players?search=sinner"
{
"data": [
{ "atp_id": "s0ag", "name_short": "J. Sinner", "country": "Italy", "rank": 1 }
],
"meta": { "page": 1, "limit": 50, "total": 1 }
}
curl -H "Authorization: Bearer <API_KEY>" \
https://api.baselinerank.com/players/a0e2
{
"data": {
"atp_id": "a0e2",
"name_short": "C. Alcaraz",
"country": "Spain",
"dob": "2003-05-05T00:00:00.000Z",
"height_cm": 183,
"weight_kg": 74,
"plays": "Right-Handed, Two-Handed Backhand",
"coach": "Samuel Lopez",
"turned_pro": 2018,
"rank": 2,
"points": 13550,
"movement": null,
"tournaments_played": null,
"career_high_rank": 1,
"career_wins": 292,
"career_losses": 65,
"career_titles": 26,
"ytd_prize_money": "$3,301,730",
"career_prize_money": "$63,333,776",
"scraped_at": "2026-06-01T06:00:02.378Z"
}
}
{
"error": "Player not found"
}
curl -H "Authorization: Bearer <API_KEY>" \
https://api.baselinerank.com/players/su87/ranking
{
"data": {
"rank": 70,
"updated_at": "2026-06-01"
}
}
curl -H "Authorization: Bearer <API_KEY>" \
"https://api.baselinerank.com/players/su87/ranking/history?limit=52"
{
"data": {
"atpId": "su87",
"type": "singles",
"history": [
{ "date": "2026-06-01", "rank": 70 },
{ "date": "2026-05-25", "rank": 70 },
{ "date": "2026-05-18", "rank": 69 },
{ "date": "2026-05-11", "rank": 66 },
{ "date": "2026-05-04", "rank": 66 },
{ "date": "2026-04-29", "rank": 62 }
]
}
}
{
"error": "Player not found"
}
curl -X POST \
-H "Authorization: Bearer <API_KEY>" \
-H "Content-Type: application/json" \
-d '{"url":"https://yoursite.com/hooks/rankings"}' \
https://api.baselinerank.com/webhook/register
{
"webhook_url": "https://yoursite.com/hooks/rankings",
"webhook_secret": "whsec_br_a3f8...",
"message": "Webhook registered. Store the secret — it won't be shown again. Use it to verify incoming requests via X-Baseline-Signature."
}
curl -X DELETE \
-H "Authorization: Bearer <API_KEY>" \
https://api.baselinerank.com/webhook/register
{
"message": "Webhook disabled."
}
{
"data": {
"atp_id": "s0ag",
"name_short": "J. Sinner",
"country": "Italy",
"dob": "2001-08-16T00:00:00.000Z",
"height_cm": 191,
"weight_kg": 77,
"plays": "Right-Handed, Two-Handed Backhand",
"coach": "Simone Vagnozzi, Darren Cahill",
"turned_pro": 2018,
"rank": 1,
"points": 10400,
"movement": null,
"tournaments_played": null,
"career_high_rank": 1,
"career_wins": 328,
"career_losses": 88,
"career_titles": 24,
"ytd_prize_money": "$912,500",
"career_prize_money": "$57,544,926",
"scraped_at": "2026-06-01T06:00:02.378Z"
}
}
Demo endpoints (no API key)
The Try it live widget below uses unauthenticated demo routes so visitors can preview responses without a key. Rate-limited to 30 requests/minute per IP.
curl "https://api.baselinerank.com/demo/players?search=sinner&limit=8"
curl "https://api.baselinerank.com/demo/players/a0e2"
Search by player name — select one to get a live response from the API.
// Search for a player above to get a live response
Reference
Authentication, rate limits, errors, and SDKs.
Authentication
Use Bearer tokens for server or client-side requests.
Authorization: Bearer <API_KEY>
Rate limits
Default: 600 requests / minute per key.
X-RateLimit-Limit: 600
X-RateLimit-Remaining: 542
Error handling
Plain-text error messages with consistent HTTP status codes.
{
"error": "Player not found"
}
SDKs Coming soon
Native clients for JavaScript and Python are in development. Until then, the API is fully usable with fetch, curl, or any HTTP client.
const res = await fetch(
"https://api.baselinerank.com/players/a0e2",
{ headers: { Authorization: "Bearer " + API_KEY } }
);
const { data } = await res.json();
Response schema
Field definitions for /players/{atpId}.
a0e2.
C. Alcaraz.
Spain.
2003-05-05T00:00:00.000Z).
null when unavailable.
null when unavailable.
$3,301,730.
Ranking history schema
Field definitions for /players/{atpId}/ranking/history.
singles or doubles.
2026-03-02.
Error responses
Errors return a single error string. HTTP status indicates the category.
- 401 —
"Missing or invalid Authorization header"or"Invalid or revoked API key" - 404 —
"Player not found" - 429 —
"Rate limit exceeded. Try again in a moment."(includescode: "rate_limited") - 400 — Validation errors, e.g.
"url is required"or"URL must use HTTPS"
Webhook payload
Sent every Monday to your registered endpoint. Verify authenticity using X-Baseline-Signature.
rankings.updated.
singles.
const sig = req.headers['x-baseline-signature'];
const expected = 'sha256=' + crypto
.createHmac('sha256', WEBHOOK_SECRET)
.update(rawBody)
.digest('hex');
if (sig !== expected) return res.status(401).end();
Versioning
The API is currently unversioned at /. Future breaking changes will be
announced in the changelog with a deprecation window before removal.