Skip to content

Examples

Start with the game you are building for. These recipes use the workflow services to resolve Riot IDs and fetch player data. Complete getting started first to install the package and set your API key.

  • League of Legends

    Look up a player, summarize recent matches, and inspect champion mastery. The code is included directly from the repository's examples/ files.

    Player profile · Match history · Champion mastery

  • Teamfight Tactics

    Retrieve a TFT profile, ranked entries, and recent match summaries using a platform route such as EUW1.

    TFT examples

  • VALORANT

    Resolve a player profile, fetch recent matches, and request an act leaderboard using a VALORANT route such as EU.

    VALORANT examples

Adapt a recipe

To change Use
The player A full Riot ID in GameName#TagLine format
The server or region The appropriate route family
Async calls to blocking calls SyncRiotClient, with, and calls without await
Timeout, retries, or caching Client configuration
An endpoint or field outside a workflow The generated raw API

match_history returns up to 20 summaries and fetches match details with bounded concurrency. For League of Legends and TFT, match_ids also accepts start and count to page through IDs before fetching individual matches.

For Legends of Runeterra, Riftbound, and the complete operation catalog, use the API reference. Operations that require player authorization are covered in Riot Sign On.