Arcana / node-dota2

A node-steam plugin for Dota 2.
MIT License
546 stars 191 forks source link

Practice matches are not available via GetMatchDetails #442

Closed chrisedington closed 7 years ago

chrisedington commented 7 years ago

Hey guys,

Hoping someone can shed some light on something for me.

I created a lobby with my bot and then played the game, and im getting this message when trying to make this request:

REQUEST:

https://api.steampowered.com/IDOTA2Match_570/GetMatchDetails/V001/?match_id=2997320481&key=xxxxx

RESPONSE:

{
    "result": {
        "error": "Practice matches are not available via GetMatchDetails"
    }
}

Would/should lobbies that my bot creates with the following settings, be availble on the GetMatchHistory and GetMatchDetails endpoints?

                    var properties = {
                        "game_name": "Lobby 5124",
                        "server_region": 11,
                        "game_mode": 1,
                        "series_type": 2,
                        "game_version": 1,
                        "allow_cheats": false,
                        "fill_with_bots": false,
                        "allow_spectating": true,
                        "pass_key": lobbyPassword,
                        "radiant_series_wins": 0,
                        "dire_series_wins": 0,
                        "allchat": true,
                        "league_id": ""
                    }
Crazy-Duck commented 7 years ago

Well, the GC's response is pretty clear.. Stats from practice lobbies will never be made available through the API. This is done a.o. to protect pro-player scrims (remember the scandal with the leaked scrim drafts?). If you want your lobbies to show up in the API, you need to ticket them

chrisedington commented 7 years ago

Thanks alot for the quick response, can you give me a little more detail on what you mean to "ticket" them?

Crazy-Duck commented 7 years ago

Only lobbies that are played "on a ticket" figure in the API, i.e. only matches that are created as part of a recognized league. If you've got a league with a sufficiently large user base, or you're organizing a tournament with a sufficiently large/high tier participant pool, you can apply for a ticket with Valve. Once your ticket got attributed, the admin of your league can, upon creation of a new lobby, specify that the match that will be played in that lobby, is part of the league and hence "add it to the ticket". From then on the match result will, once the match has finished, be available via the API.

Crazy-Duck commented 7 years ago

@chriscapetown can you close this issue if you've got no further questions?

chrisedington commented 7 years ago

Thanks for the help @Crazy-Duck !

chrisedington commented 7 years ago

Hey @Crazy-Duck, sorry to re-open this issue but just wanted to check something.

Is "ticketing" the same as just having a league? I applied for my league and it got accepted, but still getting the same result when doing createPracticeLobby and using my league ID in the "league" parameter given to createPracticeLobby.

http://api.steampowered.com/IDOTA2Match_570/GetMatchDetails/v1?match_id=3491092220&key=xxx

The match with the ID 3491092220 was part of a league.

For testing purposes, bots were included in the game. Could that possibly have affected the results from the API call?

chrisedington commented 7 years ago

Solved - the answer is (I stand to be corrected) that a league == ticket.

The reason I couldn't getMatchDetails on the above matchID is because I couldn't see that matchID when i ran getMatchHistory and specified my league ID as a query param.

When I call the getMatchDetails on an ID that shows under getMatchHistory(specifying my league ID), then it works.