Games (LOL)

League Of Legends

This documentation provides information specifically for the League Of Legends discipline.

GET /tournaments/{tournament_id}/matches/{match_id}/games

Returns a collection of games from one match. Only match type "duel" or "ffa" supported a game. If the match type is "ffa", games are limited to the first 4 opponents ordered by their position.

On stand by

The LOL stats feature has been paused with the release of the Toornament version 2. We are working on its return.

Resource URL

https://api.toornament.com/v1/tournaments/{tournament_id}/matches/{match_id}/games

Path parameters

  • tournament_id
    string

    The id of the match's tournament.

  • match_id
    string

    The id of the game's match.

Query Parameters

  • with_stats
    boolean

    When set to '1', it will include a summary of stats of the game.

    Allowed values: 1, 0

    Default: 1

Request Body

This endpoint doesn't require a request body.

Response

[200] Success

Example
[
    {
        "number": 1,
        "status": "completed",
        "opponents": [
            {
                "number": 1,
                "position": 1,
                "participant": {
                    "id": "378426939508809728",
                    "name": "Evil Geniuses",
                    "country": "US"
                },
                "result": 1,
                "score": null,
                "forfeit": false,
                "lineup": [
                    {
                        "name": "Patrick",
                        "champion": "Yasuo",
                        "items": [
                            "Trinity Force",
                            "Statikk Shiv",
                            "Infinity Edge"
                        ],
                        "level": 18,
                        "kills": 4,
                        "deaths": 0,
                        "assists": 6,
                        "last_hits": 187,
                        "gold": 9520
                    }
                ]
            }
        ],
        "duration": 2349
    }
]
Structure (collection)
  • number
    integer

    Game's number.

    Example: 1

  • status
    string

    Game's status: "pending" means it hasn’t started yet; "running" means it has started but not ended yet; "completed" indicates the game is finished.

    Possible values: pending, running, completed

  • opponents
    array[object]

  • duration
    integer|null

    League Of LegendsOptional

    Amount of time in seconds the game lasts.

    Example: 2349

GET /tournaments/{tournament_id}/matches/{match_id}/games/{number}

Returns detailed information about one game. Only match type "duel" or "ffa" supported a game. If the match type is "ffa", a game returns a maximum of 100 opponents.

On stand by

The LOL stats feature has been paused with the release of the Toornament version 2. We are working on its return.

Resource URL

https://api.toornament.com/v1/tournaments/{tournament_id}/matches/{match_id}/games/{number}

Path parameters

  • tournament_id
    string

    The id of the match's tournament.

  • match_id
    string

    The id of the game's match.

  • number
    integer

    The game number of the match

Query Parameters

  • with_stats
    boolean

    When set to '1', it will include a summary of stats of the game.

    Allowed values: 1, 0

    Default: 1

Request Body

This endpoint doesn't require a request body.

Response

[200] Success

Example
{
    "number": 1,
    "status": "completed",
    "opponents": [
        {
            "number": 1,
            "position": 1,
            "participant": {
                "id": "378426939508809728",
                "name": "Evil Geniuses",
                "country": "US"
            },
            "result": 1,
            "score": null,
            "forfeit": false,
            "lineup": [
                {
                    "name": "Patrick",
                    "champion": "Yasuo",
                    "items": [
                        "Trinity Force",
                        "Statikk Shiv",
                        "Infinity Edge"
                    ],
                    "level": 18,
                    "kills": 4,
                    "deaths": 0,
                    "assists": 6,
                    "last_hits": 187,
                    "gold": 9520
                }
            ]
        }
    ],
    "duration": 2349
}
Structure (object)
  • number
    integer

    Game's number.

    Example: 1

  • status
    string

    Game's status: "pending" means it hasn’t started yet; "running" means it has started but not ended yet; "completed" indicates the game is finished.

    Possible values: pending, running, completed

  • opponents
    array[object]

  • duration
    integer|null

    League Of LegendsOptional

    Amount of time in seconds the game lasts.

    Example: 2349

PATCH /tournaments/{tournament_id}/matches/{match_id}/games/{number}

Authorized Access

If you need to make changes on your game data, you are able to do so by patching one or several fields of your game. Only match type "duel" or "ffa" supported a game.

Warning! This endpoint can only be used with an Authorized Access.

On stand by

The LOL stats feature has been paused with the release of the Toornament version 2. We are working on its return.

Resource URL

https://api.toornament.com/v1/tournaments/{tournament_id}/matches/{match_id}/games/{number}

Path parameters

  • tournament_id
    string

    The id of the match's tournament.

  • match_id
    string

    The id of the game's match.

  • number
    integer

    The game number of the match

Query Parameters

This endpoint doesn't have any query parameters.

Request Body

Game data

Example
{
    "game_id": 1001740004,
    "region": "TRLH1",
    "hash": "80d74cc3683eba13"
}
Structure (object)
  • game_id
    string|null

    League Of LegendsOptional

    This is the LeagueOfLegends game id used to retrieve match information from riot APIs

    Example: "1001740004"

  • region
    string|null

    League Of LegendsOptional

    Specify the shard server where to collect data.

    Example: "TRLH1"

  • hash
    string|null

    League Of LegendsOptional

    Additional game hash to retrieve the match, only mandatory on esports matches.

    Example: "80d74cc3683eba13"

Response

[200] Success

Example
{
    "number": 1,
    "status": "completed",
    "opponents": [
        {
            "number": 1,
            "position": 1,
            "participant": {
                "id": "378426939508809728",
                "name": "Evil Geniuses",
                "country": "US"
            },
            "result": 1,
            "score": null,
            "forfeit": false,
            "lineup": [
                {
                    "name": "Patrick",
                    "champion": "Yasuo",
                    "items": [
                        "Trinity Force",
                        "Statikk Shiv",
                        "Infinity Edge"
                    ],
                    "level": 18,
                    "kills": 4,
                    "deaths": 0,
                    "assists": 6,
                    "last_hits": 187,
                    "gold": 9520
                }
            ]
        }
    ],
    "duration": 2349
}
Structure (object)
  • number
    integer

    Game's number.

    Example: 1

  • status
    string

    Game's status: "pending" means it hasn’t started yet; "running" means it has started but not ended yet; "completed" indicates the game is finished.

    Possible values: pending, running, completed

  • opponents
    array[object]

  • duration
    integer|null

    League Of LegendsOptional

    Amount of time in seconds the game lasts.

    Example: 2349

GET /tournaments/{tournament_id}/matches/{match_id}/games/{number}/result

Returns detailed result about one specific game. Only match type "duel" supported the result endpoint.

Resource URL

https://api.toornament.com/v1/tournaments/{tournament_id}/matches/{match_id}/games/{number}/result

Path parameters

  • tournament_id
    string

    The id of the match's tournament.

  • match_id
    string

    The id of the game's match.

  • number
    integer

    The game number of the match.

Query Parameters

This endpoint doesn't have any query parameters.

Request Body

This endpoint doesn't require a request body.

Response

[200] Success

Example
{
    "status": "completed",
    "opponents": [
        {
            "number": 1,
            "result": 1,
            "score": null,
            "forfeit": false
        }
    ]
}
Structure (object)
  • status
    string

    Game's status: "pending" means it hasn’t started yet; "running" means it has started but not ended yet; "completed" indicates the game is finished.

    Possible values: pending, running, completed

  • opponents
    array[object]

PUT /tournaments/{tournament_id}/matches/{match_id}/games/{number}/result

Authorized Access

Updates or creates detailed result about one game. Only match type "duel" supported the result endpoint.

Warning! This endpoint can only be used with an Authorized Access.

Resource URL

https://api.toornament.com/v1/tournaments/{tournament_id}/matches/{match_id}/games/{number}/result

Path parameters

  • tournament_id
    string

    The id of the match's tournament.

  • match_id
    string

    The id of the game's match.

  • number
    integer

    The game number of the match.

Query Parameters

  • update_match
    boolean

    When set to "1", also updates result match of this game. When set to '0', updates only game result.

    Allowed values: 0, 1

    Default: 1

Request Body

Update or create

Example
{
    "status": "completed",
    "opponents": [
        {
            "number": 1,
            "result": 1,
            "score": null,
            "forfeit": false
        }
    ]
}
Structure (object)
  • status
    string

    Game's status: "pending" means it hasn’t started yet; "running" means it has started but not ended yet; "completed" indicates the game is finished.

    Possible values: pending, running, completed

  • opponents
    array[object]

Response

[200] Success

Example
{
    "status": "completed",
    "opponents": [
        {
            "number": 1,
            "result": 1,
            "score": null,
            "forfeit": false
        }
    ]
}
Structure (object)
  • status
    string

    Game's status: "pending" means it hasn’t started yet; "running" means it has started but not ended yet; "completed" indicates the game is finished.

    Possible values: pending, running, completed

  • opponents
    array[object]