Base URL
The API runs locally on:Authentication
All API endpoints require a Riot Games API key for authentication. The key must be provided in the request headers:The API uses the Riot Games API key stored in the server’s environment variables (
RIOT_API_KEY). Client requests don’t need to provide the key directly - the server handles authentication with Riot’s services.Response Format
All endpoints return JSON-formatted responses.Success Responses
Successful requests return status code200 with the requested data in JSON format.
Error Responses
Errors return status code500 with the following structure:
Available Endpoints
The LoL Tracker API provides two main endpoints:Get Player Statistics
Retrieve ranked statistics and profile information for a League of Legends player
Get Match History
Fetch detailed match history with game statistics and participant information
Endpoints Quick Reference
| Endpoint | Method | Description |
|---|---|---|
/api/jugador/:nombre/:tag | GET | Get player statistics including rank, wins, losses, and level |
/api/historial/:nombre/:tag | GET | Get match history with detailed game information (supports pagination) |
Common Patterns
Player Identification
Both endpoints use Riot ID format for player identification:- nombre: The player’s in-game name
- tag: The player’s tagline (without the # symbol)
Regional Routing
The API uses the following Riot Games regional endpoints:- Americas (
americas.api.riotgames.com): Account data and match history - LA2 (
la2.api.riotgames.com): Latin America summoner and league data
Queue Types
The API tracks the following queue types:| Queue ID | Queue Name |
|---|---|
| 420 | Clasificatoria Solo/Dúo |
| 400 | Normal Reclutamiento |
| 430 | Normal Selección Oculta |
| 440 | Clasificatoria Flexible |
| 450 | ARAM |
| 700 | Clash |
Data Processing
- Rank Information: Player endpoint filters for Solo/Duo ranked queue (
RANKED_SOLO_5x5) - Match Duration: Converted from seconds to
MM:SSformat - Team IDs: Team Blue =
100, Team Red =200 - Unranked Players: Returns
"UNRANKED"tier with0LP, wins, and losses