soulbound-node-dota2
Version:
A node-steam plugin for Dota 2.
633 lines (536 loc) • 122 kB
Markdown
node-dota2
========
[](https://npmjs.org/package/dota2 "View this project on NPM")
[](https://travis-ci.org/Arcana/node-dota2 "View this project's build information")
[](https://david-dm.org/Arcana/node-dota2 "Check this project's dependencies")
[](https://greenkeeper.io/)
A node-steam plugin for Dota 2, consider it in alpha state.
Check out @RJacksonm1's blog post (his only blog post), [Extending node-dota2](https://blog.rjackson.me/extending-node-dota2/), for a rough overview of adding new functionality to the library.
A fair warning, while the way you search for new functionality is still the same, quite a lot has changed (and been simplified) implementation wise.
It is now easier to implement new functionality than it was back when this blog was written.
## Installation and setup
* `npm install` in the repository root
* Copy `config.js.example` to `config.js` and edit appropriately
* Run the example script: `node example.js`
* If you receive Error 63 you need to provide a Steam Guard code by setting the Steam Guard code in `config.js` and launching again.
* Make sure to use at least version 4.4.5 of node js
## Initializing
Parameters:
* `steamClient` - Pass a SteamClient instance to use to send & receive GC messages.
* `debug` - A boolean noting whether to print information about operations to console.
* `debugMore` - A boolean noting whether to print extended debug information. Activating this will log messages for each proto message exchanged with the GC.
```js
var Steam = require('steam'),
steamClient = new Steam.SteamClient(),
dota2 = require('dota2'),
Dota2 = new dota2.Dota2Client(steamClient, true, false);
```
## Disclaimer
We do not in any way encourage people to use their own accounts when using this library.
This library tries to mimic the behavior of the Dota 2 client to allow people to programmatically interact with the Dota 2 GC,
however we make no efforts to hide this fact and it's pretty easy for Valve to detect clients using this library based on the generated traffic.
While Valve has not yet expressed a dislike regarding reverse engineering projects like this one,
it's not unimaginable that this might one day change and result in VAC bans.
## Examples
The `examples` directory contains two Dota2 bots as an example. One contains commented-out dota2 methods, the other has boolean activated methods.
Both examples show how to interact with the library.
## Testing
There is a partial automated test suite for node-dota2, which is located in the test directory.
You need to configure the `STEAM_USERNAME` and `STEAM_PASSWORD` environment variables to be able to run it.
You can launch the tests by running the file with mocha.
# API
The API doc can be consulted here or at [doclets.io](https://doclets.io/Arcana/node-dota2)
<a name="module_Dota2"></a>
## Dota2
Dota 2 module
* [Dota2](#module_Dota2)
* _static_
* [.Dota2Client](#module_Dota2.Dota2Client) ⇐ <code>EventEmitter</code>
* [new Dota2.Dota2Client(steamClient, debug, debugMore)](#new_module_Dota2.Dota2Client_new)
* _instance_
* [.Logger](#module_Dota2.Dota2Client+Logger) : <code>winston.Logger</code>
* [.Inventory](#module_Dota2.Dota2Client+Inventory) : <code>Array.<CSOEconItem></code>
* [.chatChannels](#module_Dota2.Dota2Client+chatChannels) : <code>Array.<CMsgDOTAJoinChatChannelResponse></code>
* [.Lobby](#module_Dota2.Dota2Client+Lobby) : <code>CSODOTALobby</code>
* [.Options](#module_Dota2.Dota2Client+Lobby.Options) : <code>Object</code>
* [.LobbyInvite](#module_Dota2.Dota2Client+LobbyInvite) : <code>CSODOTALobbyInvite</code>
* [.Party](#module_Dota2.Dota2Client+Party) : <code>CSODOTAParty</code>
* [.PartyInvite](#module_Dota2.Dota2Client+PartyInvite) : <code>CSODOTAPartyInvite</code>
* [.launch()](#module_Dota2.Dota2Client+launch)
* [.exit()](#module_Dota2.Dota2Client+exit)
* [.joinChat(channel_name, [channel_type])](#module_Dota2.Dota2Client+joinChat)
* [.leaveChat(channel_name, [channel_type])](#module_Dota2.Dota2Client+leaveChat)
* [.sendMessage(message, channel_name, [channel_type])](#module_Dota2.Dota2Client+sendMessage)
* [.shareLobby(channel_name, [channel_type])](#module_Dota2.Dota2Client+shareLobby)
* [.flipCoin(channel_name, [channel_type])](#module_Dota2.Dota2Client+flipCoin)
* [.rollDice(min, max, channel_name, [channel_type])](#module_Dota2.Dota2Client+rollDice)
* [.requestChatChannels()](#module_Dota2.Dota2Client+requestChatChannels)
* [.requestPlayerMatchHistory(account_id, [options], [callback])](#module_Dota2.Dota2Client+requestPlayerMatchHistory)
* [.requestProfileCard(account_id, [callback])](#module_Dota2.Dota2Client+requestProfileCard)
* [.requestProfile(account_id, [callback])](#module_Dota2.Dota2Client+requestProfile)
* [.requestHallOfFame(week, [callback])](#module_Dota2.Dota2Client+requestHallOfFame)
* [.requestPlayerInfo(account_ids)](#module_Dota2.Dota2Client+requestPlayerInfo)
* [.requestTrophyList(account_id, [callback])](#module_Dota2.Dota2Client+requestTrophyList)
* [.requestPlayerStats(account_id, [callback])](#module_Dota2.Dota2Client+requestPlayerStats)
* [.tipPlayer(account_id, steam_id, steam_id)](#module_Dota2.Dota2Client+tipPlayer)
* [.requestJoinableCustomGameModes([server_region])](#module_Dota2.Dota2Client+requestJoinableCustomGameModes)
* [.requestPlayerCardsByPlayer()](#module_Dota2.Dota2Client+requestPlayerCardsByPlayer) ⇒ <code>Array.<FantasyPlayer></code>
* [.FantasyPlayer](#module_Dota2.Dota2Client+requestPlayerCardsByPlayer.FantasyPlayer) : <code>Object</code>
* [.requestPlayerCardRoster(league_id, timestamp, [callback])](#module_Dota2.Dota2Client+requestPlayerCardRoster)
* [.draftPlayerCard(league_id, timestamp, slot, player_card_id, [callback])](#module_Dota2.Dota2Client+draftPlayerCard)
* [.setItemPositions(item_positions)](#module_Dota2.Dota2Client+setItemPositions)
* [.deleteItem(item_id)](#module_Dota2.Dota2Client+deleteItem)
* [.requestLeagueInfo()](#module_Dota2.Dota2Client+requestLeagueInfo)
* [.requestTopLeagueMatches()](#module_Dota2.Dota2Client+requestTopLeagueMatches)
* [.createPracticeLobby(options, [callback])](#module_Dota2.Dota2Client+createPracticeLobby)
* ~~[._createPracticeLobby()](#module_Dota2.Dota2Client+_createPracticeLobby)~~
* ~~[.createTournamentLobby()](#module_Dota2.Dota2Client+createTournamentLobby)~~
* [.configPracticeLobby(lobby_id, options, [callback])](#module_Dota2.Dota2Client+configPracticeLobby)
* [.requestPracticeLobbyList([callback])](#module_Dota2.Dota2Client+requestPracticeLobbyList)
* [.requestFriendPracticeLobbyList([callback])](#module_Dota2.Dota2Client+requestFriendPracticeLobbyList)
* [.balancedShuffleLobby([callback])](#module_Dota2.Dota2Client+balancedShuffleLobby)
* [.flipLobbyTeams([callback])](#module_Dota2.Dota2Client+flipLobbyTeams)
* [.inviteToLobby(steam_id)](#module_Dota2.Dota2Client+inviteToLobby)
* [.practiceLobbyKick(account_id, [callback])](#module_Dota2.Dota2Client+practiceLobbyKick)
* [.practiceLobbyKickFromTeam(account_id, [callback])](#module_Dota2.Dota2Client+practiceLobbyKickFromTeam)
* [.joinPracticeLobby(id, password, [callback])](#module_Dota2.Dota2Client+joinPracticeLobby)
* [.leavePracticeLobby([callback])](#module_Dota2.Dota2Client+leavePracticeLobby)
* [.destroyLobby([callback])](#module_Dota2.Dota2Client+destroyLobby)
* [.abandonCurrentGame([callback])](#module_Dota2.Dota2Client+abandonCurrentGame)
* [.launchPracticeLobby([callback])](#module_Dota2.Dota2Client+launchPracticeLobby)
* [.joinPracticeLobbyTeam(slot, team, [callback])](#module_Dota2.Dota2Client+joinPracticeLobbyTeam)
* [.joinPracticeLobbyBroadcastChannel([channel], [callback])](#module_Dota2.Dota2Client+joinPracticeLobbyBroadcastChannel)
* [.addBotToPracticeLobby(slot, team, bot_difficulty, [callback])](#module_Dota2.Dota2Client+addBotToPracticeLobby)
* [.respondLobbyInvite(id, accept)](#module_Dota2.Dota2Client+respondLobbyInvite)
* [.requestMatches([criteria], [callback])](#module_Dota2.Dota2Client+requestMatches)
* [.requestMatchDetails(match_id, [callback])](#module_Dota2.Dota2Client+requestMatchDetails)
* [.requestMatchMinimalDetails(match_id, [callback])](#module_Dota2.Dota2Client+requestMatchMinimalDetails)
* [.requestMatchmakingStats()](#module_Dota2.Dota2Client+requestMatchmakingStats)
* [.requestTopFriendMatches()](#module_Dota2.Dota2Client+requestTopFriendMatches)
* [.respondPartyInvite(id, [accept], [ping_data])](#module_Dota2.Dota2Client+respondPartyInvite)
* [.leaveParty()](#module_Dota2.Dota2Client+leaveParty)
* [.setPartyLeader(steam_id)](#module_Dota2.Dota2Client+setPartyLeader)
* [.setPartyCoach(coach)](#module_Dota2.Dota2Client+setPartyCoach)
* [.inviteToParty(steam_id)](#module_Dota2.Dota2Client+inviteToParty)
* [.kickFromParty(steam_id)](#module_Dota2.Dota2Client+kickFromParty)
* [.requestSourceTVGames(filter_options)](#module_Dota2.Dota2Client+requestSourceTVGames)
* [.requestMyTeams([callback])](#module_Dota2.Dota2Client+requestMyTeams)
* ["ready"](#module_Dota2.Dota2Client+event_ready)
* ["unhandled" (kMsg, kMsg_name)](#module_Dota2.Dota2Client+event_unhandled)
* ["hellotimeout"](#module_Dota2.Dota2Client+event_hellotimeout)
* ["inventoryUpdate" (inventory)](#module_Dota2.Dota2Client+event_inventoryUpdate)
* ["gotItem" (item)](#module_Dota2.Dota2Client+event_gotItem)
* ["gaveItem" (item)](#module_Dota2.Dota2Client+event_gaveItem)
* ["practiceLobbyUpdate" (lobby)](#module_Dota2.Dota2Client+event_practiceLobbyUpdate)
* ["practiceLobbyCleared"](#module_Dota2.Dota2Client+event_practiceLobbyCleared)
* ["lobbyInviteUpdate" (lobbyInvite)](#module_Dota2.Dota2Client+event_lobbyInviteUpdate)
* ["lobbyInviteCleared"](#module_Dota2.Dota2Client+event_lobbyInviteCleared)
* ["partyUpdate" (party)](#module_Dota2.Dota2Client+event_partyUpdate)
* ["partyCleared"](#module_Dota2.Dota2Client+event_partyCleared)
* ["partyInviteUpdate" (partyInvite)](#module_Dota2.Dota2Client+event_partyInviteUpdate)
* ["partyInviteCleared"](#module_Dota2.Dota2Client+event_partyInviteCleared)
* ["chatJoined" (channelData)](#module_Dota2.Dota2Client+event_chatJoined)
* ["chatJoin" (channel, joiner_name, joiner_steam_id, otherJoined_object)](#module_Dota2.Dota2Client+event_chatJoin)
* ["chatLeave" (channel, leaver_steam_id, otherLeft_object)](#module_Dota2.Dota2Client+event_chatLeave)
* ["chatLeft" (channel)](#module_Dota2.Dota2Client+event_chatLeft)
* ["chatMessage" (channel, sender_name, message, chatData)](#module_Dota2.Dota2Client+event_chatMessage)
* ["chatChannelsData" (channels)](#module_Dota2.Dota2Client+event_chatChannelsData)
* ["playerMatchHistoryData" (requestId, matchHistoryResponse)](#module_Dota2.Dota2Client+event_playerMatchHistoryData)
* ["profileCardData" (account_id, profileCardResponse)](#module_Dota2.Dota2Client+event_profileCardData)
* ["profileData" (profileResponse)](#module_Dota2.Dota2Client+event_profileData)
* ["hallOfFameData" (week, featured_players, featured_farmer, hallOfFameResponse)](#module_Dota2.Dota2Client+event_hallOfFameData)
* ["playerInfoData" (playerInfoData)](#module_Dota2.Dota2Client+event_playerInfoData)
* ["trophyListData" (trophyListResponse)](#module_Dota2.Dota2Client+event_trophyListData)
* ["playerStatsData" (account_id, playerStatsResponse)](#module_Dota2.Dota2Client+event_playerStatsData)
* ["tipResponse" (tipResponse)](#module_Dota2.Dota2Client+event_tipResponse)
* ["tipped" (tipper_account_id, tipper_name, recipient_account_id, recipient_name, event_id)](#module_Dota2.Dota2Client+event_tipped)
* ["joinableCustomGameModes" (joinableCustomGameModes)](#module_Dota2.Dota2Client+event_joinableCustomGameModes)
* ["playerCardRoster" (playerCardRoster)](#module_Dota2.Dota2Client+event_playerCardRoster)
* ["playerCardDrafted" (playerCardRoster)](#module_Dota2.Dota2Client+event_playerCardDrafted)
* ["popup" (id, popup)](#module_Dota2.Dota2Client+event_popup)
* ["liveLeagueGamesUpdate" (live_league_games)](#module_Dota2.Dota2Client+event_liveLeagueGamesUpdate)
* ["leagueData" (leagues)](#module_Dota2.Dota2Client+event_leagueData)
* ["topLeagueMatchesData" (matches)](#module_Dota2.Dota2Client+event_topLeagueMatchesData)
* ["lobbyDestroyed" (result, response)](#module_Dota2.Dota2Client+event_lobbyDestroyed)
* ["practiceLobbyJoinResponse" (result, response)](#module_Dota2.Dota2Client+event_practiceLobbyJoinResponse)
* ["practiceLobbyListData" (practiceLobbyListResponse)](#module_Dota2.Dota2Client+event_practiceLobbyListData)
* ["practiceLobbyResponse" (result, response)](#module_Dota2.Dota2Client+event_practiceLobbyResponse)
* ["friendPracticeLobbyListData" (practiceLobbyListResponse)](#module_Dota2.Dota2Client+event_friendPracticeLobbyListData)
* ["inviteCreated" (steam_id, group_id, is_online)](#module_Dota2.Dota2Client+event_inviteCreated)
* ["matchesData" (requestId, total_results, results_remaining, matches, series, matchResponse)](#module_Dota2.Dota2Client+event_matchesData)
* ["matchDetailsData" (match_id, matchDetailsResponse)](#module_Dota2.Dota2Client+event_matchDetailsData)
* ["matchMinimalDetailsData" (last_match, matchMinimalDetailsResponse)](#module_Dota2.Dota2Client+event_matchMinimalDetailsData)
* ["matchmakingStatsData" (matchgroups_version, match_groups, matchmakingStatsResponse)](#module_Dota2.Dota2Client+event_matchmakingStatsData)
* ["topFriendMatchesData" (matches)](#module_Dota2.Dota2Client+event_topFriendMatchesData)
* ["sourceTVGamesData" (sourceTVGamesResponse)](#module_Dota2.Dota2Client+event_sourceTVGamesData)
* ["teamData" (teams, league_id)](#module_Dota2.Dota2Client+event_teamData)
* _static_
* [.ToAccountID(steamID)](#module_Dota2.Dota2Client.ToAccountID) ⇒ <code>number</code>
* [.ToSteamID(accid)](#module_Dota2.Dota2Client.ToSteamID) ⇒ [<code>Long</code>](#external_Long)
* [.schema](#module_Dota2.schema)
* [.CMsgGCToClientPlayerStatsResponse](#module_Dota2.schema.CMsgGCToClientPlayerStatsResponse) : <code>Object</code>
* [.FantasyStats](#module_Dota2.FantasyStats) : <code>enum</code>
* [.EResult](#module_Dota2.EResult) : <code>enum</code>
* [.ServerRegion](#module_Dota2.ServerRegion) : <code>enum</code>
* [.SeriesType](#module_Dota2.SeriesType) : <code>enum</code>
* [.BotDifficulty](#module_Dota2.BotDifficulty) : <code>enum</code>
* _inner_
* [~requestCallback](#module_Dota2..requestCallback) : <code>function</code>
* [~Long](#external_Long)
<a name="module_Dota2.Dota2Client"></a>
### Dota2.Dota2Client ⇐ <code>EventEmitter</code>
**Kind**: static class of [<code>Dota2</code>](#module_Dota2)
**Extends**: <code>EventEmitter</code>
**Emits**: [<code>ready</code>](#module_Dota2.Dota2Client+event_ready), [<code>unhandled</code>](#module_Dota2.Dota2Client+event_unhandled), [<code>hellotimeout</code>](#module_Dota2.Dota2Client+event_hellotimeout), [<code>popup</code>](#module_Dota2.Dota2Client+event_popup), [<code>sourceTVGamesData</code>](#module_Dota2.Dota2Client+event_sourceTVGamesData), [<code>inventoryUpdate</code>](#module_Dota2.Dota2Client+event_inventoryUpdate), [<code>practiceLobbyUpdate</code>](#module_Dota2.Dota2Client+event_practiceLobbyUpdate), [<code>practiceLobbyCleared</code>](#module_Dota2.Dota2Client+event_practiceLobbyCleared), [<code>lobbyInviteUpdate</code>](#module_Dota2.Dota2Client+event_lobbyInviteUpdate), [<code>lobbyInviteCleared</code>](#module_Dota2.Dota2Client+event_lobbyInviteCleared), [<code>practiceLobbyJoinResponse</code>](#module_Dota2.Dota2Client+event_practiceLobbyJoinResponse), [<code>practiceLobbyListData</code>](#module_Dota2.Dota2Client+event_practiceLobbyListData), [<code>practiceLobbyResponse</code>](#module_Dota2.Dota2Client+event_practiceLobbyResponse), [<code>lobbyDestroyed</code>](#module_Dota2.Dota2Client+event_lobbyDestroyed), [<code>friendPracticeLobbyListData</code>](#module_Dota2.Dota2Client+event_friendPracticeLobbyListData), [<code>inviteCreated</code>](#module_Dota2.Dota2Client+event_inviteCreated), [<code>partyUpdate</code>](#module_Dota2.Dota2Client+event_partyUpdate), [<code>partyCleared</code>](#module_Dota2.Dota2Client+event_partyCleared), [<code>partyInviteUpdate</code>](#module_Dota2.Dota2Client+event_partyInviteUpdate), [<code>partyInviteCleared</code>](#module_Dota2.Dota2Client+event_partyInviteCleared), [<code>joinableCustomGameModes</code>](#module_Dota2.Dota2Client+event_joinableCustomGameModes), [<code>chatChannelsData</code>](#module_Dota2.Dota2Client+event_chatChannelsData), [<code>chatJoin</code>](#module_Dota2.Dota2Client+event_chatJoin), [<code>chatJoined</code>](#module_Dota2.Dota2Client+event_chatJoined), [<code>chatLeave</code>](#module_Dota2.Dota2Client+event_chatLeave), [<code>chatMessage</code>](#module_Dota2.Dota2Client+event_chatMessage), [<code>profileCardData</code>](#module_Dota2.Dota2Client+event_profileCardData), [<code>playerMatchHistoryData</code>](#module_Dota2.Dota2Client+event_playerMatchHistoryData), [<code>playerInfoData</code>](#module_Dota2.Dota2Client+event_playerInfoData), [<code>playerStatsData</code>](#module_Dota2.Dota2Client+event_playerStatsData), [<code>trophyListData</code>](#module_Dota2.Dota2Client+event_trophyListData), [<code>hallOfFameData</code>](#module_Dota2.Dota2Client+event_hallOfFameData), [<code>playerCardRoster</code>](#module_Dota2.Dota2Client+event_playerCardRoster), [<code>playerCardDrafted</code>](#module_Dota2.Dota2Client+event_playerCardDrafted), [<code>liveLeagueGamesUpdate</code>](#module_Dota2.Dota2Client+event_liveLeagueGamesUpdate), [<code>leagueData</code>](#module_Dota2.Dota2Client+event_leagueData), [<code>topLeagueMatchesData</code>](#module_Dota2.Dota2Client+event_topLeagueMatchesData), [<code>teamData</code>](#module_Dota2.Dota2Client+event_teamData), [<code>matchesData</code>](#module_Dota2.Dota2Client+event_matchesData), [<code>matchDetailsData</code>](#module_Dota2.Dota2Client+event_matchDetailsData), [<code>matchMinimalDetailsData</code>](#module_Dota2.Dota2Client+event_matchMinimalDetailsData), [<code>matchmakingStatsData</code>](#module_Dota2.Dota2Client+event_matchmakingStatsData), [<code>topFriendMatchesData</code>](#module_Dota2.Dota2Client+event_topFriendMatchesData), [<code>tipResponse</code>](#module_Dota2.Dota2Client+event_tipResponse), [<code>tipped</code>](#module_Dota2.Dota2Client+event_tipped)
* [.Dota2Client](#module_Dota2.Dota2Client) ⇐ <code>EventEmitter</code>
* [new Dota2.Dota2Client(steamClient, debug, debugMore)](#new_module_Dota2.Dota2Client_new)
* _instance_
* [.Logger](#module_Dota2.Dota2Client+Logger) : <code>winston.Logger</code>
* [.Inventory](#module_Dota2.Dota2Client+Inventory) : <code>Array.<CSOEconItem></code>
* [.chatChannels](#module_Dota2.Dota2Client+chatChannels) : <code>Array.<CMsgDOTAJoinChatChannelResponse></code>
* [.Lobby](#module_Dota2.Dota2Client+Lobby) : <code>CSODOTALobby</code>
* [.Options](#module_Dota2.Dota2Client+Lobby.Options) : <code>Object</code>
* [.LobbyInvite](#module_Dota2.Dota2Client+LobbyInvite) : <code>CSODOTALobbyInvite</code>
* [.Party](#module_Dota2.Dota2Client+Party) : <code>CSODOTAParty</code>
* [.PartyInvite](#module_Dota2.Dota2Client+PartyInvite) : <code>CSODOTAPartyInvite</code>
* [.launch()](#module_Dota2.Dota2Client+launch)
* [.exit()](#module_Dota2.Dota2Client+exit)
* [.joinChat(channel_name, [channel_type])](#module_Dota2.Dota2Client+joinChat)
* [.leaveChat(channel_name, [channel_type])](#module_Dota2.Dota2Client+leaveChat)
* [.sendMessage(message, channel_name, [channel_type])](#module_Dota2.Dota2Client+sendMessage)
* [.shareLobby(channel_name, [channel_type])](#module_Dota2.Dota2Client+shareLobby)
* [.flipCoin(channel_name, [channel_type])](#module_Dota2.Dota2Client+flipCoin)
* [.rollDice(min, max, channel_name, [channel_type])](#module_Dota2.Dota2Client+rollDice)
* [.requestChatChannels()](#module_Dota2.Dota2Client+requestChatChannels)
* [.requestPlayerMatchHistory(account_id, [options], [callback])](#module_Dota2.Dota2Client+requestPlayerMatchHistory)
* [.requestProfileCard(account_id, [callback])](#module_Dota2.Dota2Client+requestProfileCard)
* [.requestProfile(account_id, [callback])](#module_Dota2.Dota2Client+requestProfile)
* [.requestHallOfFame(week, [callback])](#module_Dota2.Dota2Client+requestHallOfFame)
* [.requestPlayerInfo(account_ids)](#module_Dota2.Dota2Client+requestPlayerInfo)
* [.requestTrophyList(account_id, [callback])](#module_Dota2.Dota2Client+requestTrophyList)
* [.requestPlayerStats(account_id, [callback])](#module_Dota2.Dota2Client+requestPlayerStats)
* [.tipPlayer(account_id, steam_id, steam_id)](#module_Dota2.Dota2Client+tipPlayer)
* [.requestJoinableCustomGameModes([server_region])](#module_Dota2.Dota2Client+requestJoinableCustomGameModes)
* [.requestPlayerCardsByPlayer()](#module_Dota2.Dota2Client+requestPlayerCardsByPlayer) ⇒ <code>Array.<FantasyPlayer></code>
* [.FantasyPlayer](#module_Dota2.Dota2Client+requestPlayerCardsByPlayer.FantasyPlayer) : <code>Object</code>
* [.requestPlayerCardRoster(league_id, timestamp, [callback])](#module_Dota2.Dota2Client+requestPlayerCardRoster)
* [.draftPlayerCard(league_id, timestamp, slot, player_card_id, [callback])](#module_Dota2.Dota2Client+draftPlayerCard)
* [.setItemPositions(item_positions)](#module_Dota2.Dota2Client+setItemPositions)
* [.deleteItem(item_id)](#module_Dota2.Dota2Client+deleteItem)
* [.requestLeagueInfo()](#module_Dota2.Dota2Client+requestLeagueInfo)
* [.requestTopLeagueMatches()](#module_Dota2.Dota2Client+requestTopLeagueMatches)
* [.createPracticeLobby(options, [callback])](#module_Dota2.Dota2Client+createPracticeLobby)
* ~~[._createPracticeLobby()](#module_Dota2.Dota2Client+_createPracticeLobby)~~
* ~~[.createTournamentLobby()](#module_Dota2.Dota2Client+createTournamentLobby)~~
* [.configPracticeLobby(lobby_id, options, [callback])](#module_Dota2.Dota2Client+configPracticeLobby)
* [.requestPracticeLobbyList([callback])](#module_Dota2.Dota2Client+requestPracticeLobbyList)
* [.requestFriendPracticeLobbyList([callback])](#module_Dota2.Dota2Client+requestFriendPracticeLobbyList)
* [.balancedShuffleLobby([callback])](#module_Dota2.Dota2Client+balancedShuffleLobby)
* [.flipLobbyTeams([callback])](#module_Dota2.Dota2Client+flipLobbyTeams)
* [.inviteToLobby(steam_id)](#module_Dota2.Dota2Client+inviteToLobby)
* [.practiceLobbyKick(account_id, [callback])](#module_Dota2.Dota2Client+practiceLobbyKick)
* [.practiceLobbyKickFromTeam(account_id, [callback])](#module_Dota2.Dota2Client+practiceLobbyKickFromTeam)
* [.joinPracticeLobby(id, password, [callback])](#module_Dota2.Dota2Client+joinPracticeLobby)
* [.leavePracticeLobby([callback])](#module_Dota2.Dota2Client+leavePracticeLobby)
* [.destroyLobby([callback])](#module_Dota2.Dota2Client+destroyLobby)
* [.abandonCurrentGame([callback])](#module_Dota2.Dota2Client+abandonCurrentGame)
* [.launchPracticeLobby([callback])](#module_Dota2.Dota2Client+launchPracticeLobby)
* [.joinPracticeLobbyTeam(slot, team, [callback])](#module_Dota2.Dota2Client+joinPracticeLobbyTeam)
* [.joinPracticeLobbyBroadcastChannel([channel], [callback])](#module_Dota2.Dota2Client+joinPracticeLobbyBroadcastChannel)
* [.addBotToPracticeLobby(slot, team, bot_difficulty, [callback])](#module_Dota2.Dota2Client+addBotToPracticeLobby)
* [.respondLobbyInvite(id, accept)](#module_Dota2.Dota2Client+respondLobbyInvite)
* [.requestMatches([criteria], [callback])](#module_Dota2.Dota2Client+requestMatches)
* [.requestMatchDetails(match_id, [callback])](#module_Dota2.Dota2Client+requestMatchDetails)
* [.requestMatchMinimalDetails(match_id, [callback])](#module_Dota2.Dota2Client+requestMatchMinimalDetails)
* [.requestMatchmakingStats()](#module_Dota2.Dota2Client+requestMatchmakingStats)
* [.requestTopFriendMatches()](#module_Dota2.Dota2Client+requestTopFriendMatches)
* [.respondPartyInvite(id, [accept], [ping_data])](#module_Dota2.Dota2Client+respondPartyInvite)
* [.leaveParty()](#module_Dota2.Dota2Client+leaveParty)
* [.setPartyLeader(steam_id)](#module_Dota2.Dota2Client+setPartyLeader)
* [.setPartyCoach(coach)](#module_Dota2.Dota2Client+setPartyCoach)
* [.inviteToParty(steam_id)](#module_Dota2.Dota2Client+inviteToParty)
* [.kickFromParty(steam_id)](#module_Dota2.Dota2Client+kickFromParty)
* [.requestSourceTVGames(filter_options)](#module_Dota2.Dota2Client+requestSourceTVGames)
* [.requestMyTeams([callback])](#module_Dota2.Dota2Client+requestMyTeams)
* ["ready"](#module_Dota2.Dota2Client+event_ready)
* ["unhandled" (kMsg, kMsg_name)](#module_Dota2.Dota2Client+event_unhandled)
* ["hellotimeout"](#module_Dota2.Dota2Client+event_hellotimeout)
* ["inventoryUpdate" (inventory)](#module_Dota2.Dota2Client+event_inventoryUpdate)
* ["gotItem" (item)](#module_Dota2.Dota2Client+event_gotItem)
* ["gaveItem" (item)](#module_Dota2.Dota2Client+event_gaveItem)
* ["practiceLobbyUpdate" (lobby)](#module_Dota2.Dota2Client+event_practiceLobbyUpdate)
* ["practiceLobbyCleared"](#module_Dota2.Dota2Client+event_practiceLobbyCleared)
* ["lobbyInviteUpdate" (lobbyInvite)](#module_Dota2.Dota2Client+event_lobbyInviteUpdate)
* ["lobbyInviteCleared"](#module_Dota2.Dota2Client+event_lobbyInviteCleared)
* ["partyUpdate" (party)](#module_Dota2.Dota2Client+event_partyUpdate)
* ["partyCleared"](#module_Dota2.Dota2Client+event_partyCleared)
* ["partyInviteUpdate" (partyInvite)](#module_Dota2.Dota2Client+event_partyInviteUpdate)
* ["partyInviteCleared"](#module_Dota2.Dota2Client+event_partyInviteCleared)
* ["chatJoined" (channelData)](#module_Dota2.Dota2Client+event_chatJoined)
* ["chatJoin" (channel, joiner_name, joiner_steam_id, otherJoined_object)](#module_Dota2.Dota2Client+event_chatJoin)
* ["chatLeave" (channel, leaver_steam_id, otherLeft_object)](#module_Dota2.Dota2Client+event_chatLeave)
* ["chatLeft" (channel)](#module_Dota2.Dota2Client+event_chatLeft)
* ["chatMessage" (channel, sender_name, message, chatData)](#module_Dota2.Dota2Client+event_chatMessage)
* ["chatChannelsData" (channels)](#module_Dota2.Dota2Client+event_chatChannelsData)
* ["playerMatchHistoryData" (requestId, matchHistoryResponse)](#module_Dota2.Dota2Client+event_playerMatchHistoryData)
* ["profileCardData" (account_id, profileCardResponse)](#module_Dota2.Dota2Client+event_profileCardData)
* ["profileData" (profileResponse)](#module_Dota2.Dota2Client+event_profileData)
* ["hallOfFameData" (week, featured_players, featured_farmer, hallOfFameResponse)](#module_Dota2.Dota2Client+event_hallOfFameData)
* ["playerInfoData" (playerInfoData)](#module_Dota2.Dota2Client+event_playerInfoData)
* ["trophyListData" (trophyListResponse)](#module_Dota2.Dota2Client+event_trophyListData)
* ["playerStatsData" (account_id, playerStatsResponse)](#module_Dota2.Dota2Client+event_playerStatsData)
* ["tipResponse" (tipResponse)](#module_Dota2.Dota2Client+event_tipResponse)
* ["tipped" (tipper_account_id, tipper_name, recipient_account_id, recipient_name, event_id)](#module_Dota2.Dota2Client+event_tipped)
* ["joinableCustomGameModes" (joinableCustomGameModes)](#module_Dota2.Dota2Client+event_joinableCustomGameModes)
* ["playerCardRoster" (playerCardRoster)](#module_Dota2.Dota2Client+event_playerCardRoster)
* ["playerCardDrafted" (playerCardRoster)](#module_Dota2.Dota2Client+event_playerCardDrafted)
* ["popup" (id, popup)](#module_Dota2.Dota2Client+event_popup)
* ["liveLeagueGamesUpdate" (live_league_games)](#module_Dota2.Dota2Client+event_liveLeagueGamesUpdate)
* ["leagueData" (leagues)](#module_Dota2.Dota2Client+event_leagueData)
* ["topLeagueMatchesData" (matches)](#module_Dota2.Dota2Client+event_topLeagueMatchesData)
* ["lobbyDestroyed" (result, response)](#module_Dota2.Dota2Client+event_lobbyDestroyed)
* ["practiceLobbyJoinResponse" (result, response)](#module_Dota2.Dota2Client+event_practiceLobbyJoinResponse)
* ["practiceLobbyListData" (practiceLobbyListResponse)](#module_Dota2.Dota2Client+event_practiceLobbyListData)
* ["practiceLobbyResponse" (result, response)](#module_Dota2.Dota2Client+event_practiceLobbyResponse)
* ["friendPracticeLobbyListData" (practiceLobbyListResponse)](#module_Dota2.Dota2Client+event_friendPracticeLobbyListData)
* ["inviteCreated" (steam_id, group_id, is_online)](#module_Dota2.Dota2Client+event_inviteCreated)
* ["matchesData" (requestId, total_results, results_remaining, matches, series, matchResponse)](#module_Dota2.Dota2Client+event_matchesData)
* ["matchDetailsData" (match_id, matchDetailsResponse)](#module_Dota2.Dota2Client+event_matchDetailsData)
* ["matchMinimalDetailsData" (last_match, matchMinimalDetailsResponse)](#module_Dota2.Dota2Client+event_matchMinimalDetailsData)
* ["matchmakingStatsData" (matchgroups_version, match_groups, matchmakingStatsResponse)](#module_Dota2.Dota2Client+event_matchmakingStatsData)
* ["topFriendMatchesData" (matches)](#module_Dota2.Dota2Client+event_topFriendMatchesData)
* ["sourceTVGamesData" (sourceTVGamesResponse)](#module_Dota2.Dota2Client+event_sourceTVGamesData)
* ["teamData" (teams, league_id)](#module_Dota2.Dota2Client+event_teamData)
* _static_
* [.ToAccountID(steamID)](#module_Dota2.Dota2Client.ToAccountID) ⇒ <code>number</code>
* [.ToSteamID(accid)](#module_Dota2.Dota2Client.ToSteamID) ⇒ [<code>Long</code>](#external_Long)
<a name="new_module_Dota2.Dota2Client_new"></a>
#### new Dota2.Dota2Client(steamClient, debug, debugMore)
The Dota 2 client that communicates with the GC
| Param | Type | Description |
| --- | --- | --- |
| steamClient | <code>Object</code> | Node-steam client instance |
| debug | <code>boolean</code> | Print debug information to console |
| debugMore | <code>boolean</code> | Print even more debug information to console |
<a name="module_Dota2.Dota2Client+Logger"></a>
#### dota2Client.Logger : <code>winston.Logger</code>
The logger used to write debug messages. This is a WinstonJS logger,
feel free to configure it as you like
**Kind**: instance property of [<code>Dota2Client</code>](#module_Dota2.Dota2Client)
<a name="module_Dota2.Dota2Client+Inventory"></a>
#### dota2Client.Inventory : <code>Array.<CSOEconItem></code>
The current state of the bot's inventory. Contains cosmetics, player cards, ...
**Kind**: instance property of [<code>Dota2Client</code>](#module_Dota2.Dota2Client)
<a name="module_Dota2.Dota2Client+chatChannels"></a>
#### dota2Client.chatChannels : <code>Array.<CMsgDOTAJoinChatChannelResponse></code>
The chat channels the bot has joined
**Kind**: instance property of [<code>Dota2Client</code>](#module_Dota2.Dota2Client)
<a name="module_Dota2.Dota2Client+Lobby"></a>
#### dota2Client.Lobby : <code>CSODOTALobby</code>
The lobby the bot is currently in. Falsy if the bot isn't in a lobby.
**Kind**: instance property of [<code>Dota2Client</code>](#module_Dota2.Dota2Client)
<a name="module_Dota2.Dota2Client+Lobby.Options"></a>
##### Lobby.Options : <code>Object</code>
**Kind**: static typedef of [<code>Lobby</code>](#module_Dota2.Dota2Client+Lobby)
**Properties**
| Name | Type | Default | Description |
| --- | --- | --- | --- |
| game_name | <code>string</code> | | Name of the lobby |
| pass_key | <code>string</code> | | Lobby password |
| [server_region] | [<code>ServerRegion</code>](#module_Dota2.ServerRegion) | <code>module:Dota2.ServerRegion.UNSPECIFIED</code> | Server region where the lobby will be created |
| [game_mode] | <code>DOTA_GameMode</code> | <code>DOTA_GameMode.DOTA_GAMEMODE_AP</code> | Game mode |
| [game_version] | <code>DOTAGameVersion</code> | <code>DOTAGameVersion.GAME_VERSION_STABLE</code> | Version of the game |
| [cm_pick] | <code>DOTA_CM_PICK</code> | <code>DOTA_CM_PICK.DOTA_CM_RANDOM</code> | Who gets first pick |
| [allow_cheats] | <code>boolean</code> | <code>false</code> | Whether or not to allow cheats |
| [fill_with_bots] | <code>boolean</code> | <code>false</code> | Whether or not to fill empty slots with bots |
| [bot_difficulty_radiant] | <code>BotDifficulty</code> | <code>module:Dota2.BotDifficulty.PASSIVE</code> | The bot difficulty for radiant bots, if fill_with_bots is true. |
| [bot_difficulty_dire] | <code>BotDifficulty</code> | <code>module:Dota2.BotDifficulty.PASSIVE</code> | The bot difficulty for dire bots, if fill_with_bots is true. |
| [bot_radiant] | <code>number</code> | | Presumably the ID of the custom AI to be applied to radiant bots. |
| [bot_dire] | <code>number</code> | | Presumably the ID of the custom AI to be applied to dire bots. |
| [allow_spectating] | <code>boolean</code> | <code>true</code> | Whether or not to allow spectating |
| [series_type] | <code>SeriesType</code> | <code>NONE</code> | Whether or not the game is part of a series (Bo3, Bo5). |
| [radiant_series_wins] | <code>number</code> | <code>0</code> | # of games won so far, e.g. for a Bo3 or Bo5. |
| [dire_series_wins] | <code>number</code> | <code>0</code> | # of games won so far, e.g. for a Bo3 or Bo5. |
| [previous_match_override] | <code>number</code> | | In a series, the match ID of the previous game. If not supplied, the GC will try to find it automatically based on the teams and the players. |
| [allchat] | <code>boolean</code> | <code>false</code> | Whether or not it's allowed to all-chat |
| [dota_tv_delay] | <code>LobbyDotaTVDelay</code> | <code>LobbyDotaTV_120</code> | How much time the game should be delayed for DotaTV. |
| [leagueid] | <code>number</code> | | The league this lobby is being created for. The bot should be a league admin for this to work. |
| [custom_game_mode] | <code>string</code> | | Name of the custom game |
| [custom_map_name] | <code>string</code> | | Which map the custom game should be played on |
| [custom_difficulty] | <code>number</code> | | Difficulty of the custom game |
| [custom_game_id] | [<code>Long</code>](#external_Long) | | 64bit ID of the custom game mode |
| [pause_setting] | <code>LobbyDotaPauseSetting</code> | <code>0</code> | Pause setting: 0 - unlimited, 1 - limited, 2 - disabled |
<a name="module_Dota2.Dota2Client+LobbyInvite"></a>
#### dota2Client.LobbyInvite : <code>CSODOTALobbyInvite</code>
The currently active lobby invitation. Falsy if the bot has not been invited.
**Kind**: instance property of [<code>Dota2Client</code>](#module_Dota2.Dota2Client)
<a name="module_Dota2.Dota2Client+Party"></a>
#### dota2Client.Party : <code>CSODOTAParty</code>
The party the bot is currently in. Falsy if the bot isn't in a party.
**Kind**: instance property of [<code>Dota2Client</code>](#module_Dota2.Dota2Client)
<a name="module_Dota2.Dota2Client+PartyInvite"></a>
#### dota2Client.PartyInvite : <code>CSODOTAPartyInvite</code>
The currently active party invitation. Falsy if the bot has not been invited.
**Kind**: instance property of [<code>Dota2Client</code>](#module_Dota2.Dota2Client)
<a name="module_Dota2.Dota2Client+launch"></a>
#### dota2Client.launch()
Reports to Steam that you're playing Dota 2, and then initiates communication with the Game Coordinator.
**Kind**: instance method of [<code>Dota2Client</code>](#module_Dota2.Dota2Client)
<a name="module_Dota2.Dota2Client+exit"></a>
#### dota2Client.exit()
Stop sending a heartbeat to the GC and report to steam you're no longer playing Dota 2
**Kind**: instance method of [<code>Dota2Client</code>](#module_Dota2.Dota2Client)
<a name="module_Dota2.Dota2Client+joinChat"></a>
#### dota2Client.joinChat(channel_name, [channel_type])
Joins a chat channel. If the chat channel with the given name doesn't exist, it
is created. Listen for the `chatMessage` event for other people's chat messages.
Requires the GC to be [ready](#module_Dota2.Dota2Client+event_ready).
**Kind**: instance method of [<code>Dota2Client</code>](#module_Dota2.Dota2Client)
| Param | Type | Default | Description |
| --- | --- | --- | --- |
| channel_name | <code>string</code> | | Name of the chat channel |
| [channel_type] | <code>DOTAChatChannelType_t</code> | <code>DOTAChatChannelType_t.DOTAChatChannelType_Custom</code> | The type of the channel being joined |
<a name="module_Dota2.Dota2Client+leaveChat"></a>
#### dota2Client.leaveChat(channel_name, [channel_type])
Leaves a chat channel. If you've joined different channels with the same name,
specify the type to prevent unexpected behaviour.
Requires the GC to be [ready](#module_Dota2.Dota2Client+event_ready).
**Kind**: instance method of [<code>Dota2Client</code>](#module_Dota2.Dota2Client)
| Param | Type | Description |
| --- | --- | --- |
| channel_name | <code>string</code> | Name of the chat channel |
| [channel_type] | <code>DOTAChatChannelType_t</code> | The type of the channel being joined |
<a name="module_Dota2.Dota2Client+sendMessage"></a>
#### dota2Client.sendMessage(message, channel_name, [channel_type])
Sends a message to the specified chat channel. Won't send if you're not in the channel you try to send to.
If you've joined different channels with the same name, specify the type to prevent unexpected behaviour.
Requires the GC to be [ready](#module_Dota2.Dota2Client+event_ready).
**Kind**: instance method of [<code>Dota2Client</code>](#module_Dota2.Dota2Client)
| Param | Type | Description |
| --- | --- | --- |
| message | <code>string</code> | The message you want to send |
| channel_name | <code>string</code> | Name of the chat channel |
| [channel_type] | <code>DOTAChatChannelType_t</code> | The type of the channel being joined |
<a name="module_Dota2.Dota2Client+shareLobby"></a>
#### dota2Client.shareLobby(channel_name, [channel_type])
Shares the lobby you're currently in with the chat so other people can join.
Requires the GC to be [ready](#module_Dota2.Dota2Client+event_ready).
**Kind**: instance method of [<code>Dota2Client</code>](#module_Dota2.Dota2Client)
| Param | Type | Description |
| --- | --- | --- |
| channel_name | <code>string</code> | Name of the chat channel |
| [channel_type] | <code>DOTAChatChannelType_t</code> | The type of the channel being joined |
<a name="module_Dota2.Dota2Client+flipCoin"></a>
#### dota2Client.flipCoin(channel_name, [channel_type])
Sends a coin flip to the specified chat channel. Won't send if you're not in the channel you try to send to.
If you've joined different channels with the same name, specify the type to prevent unexpected behaviour.
Requires the GC to be [ready](#module_Dota2.Dota2Client+event_ready).
**Kind**: instance method of [<code>Dota2Client</code>](#module_Dota2.Dota2Client)
| Param | Type | Description |
| --- | --- | --- |
| channel_name | <code>string</code> | Name of the chat channel |
| [channel_type] | <code>DOTAChatChannelType_t</code> | The type of the channel being joined |
<a name="module_Dota2.Dota2Client+rollDice"></a>
#### dota2Client.rollDice(min, max, channel_name, [channel_type])
Sends a dice roll to the specified chat channel. Won't send if you're not in the channel you try to send to.
If you've joined different channels with the same name, specify the type to prevent unexpected behaviour.
Requires the GC to be [ready](#module_Dota2.Dota2Client+event_ready).
**Kind**: instance method of [<code>Dota2Client</code>](#module_Dota2.Dota2Client)
| Param | Type | Description |
| --- | --- | --- |
| min | <code>number</code> | Lower bound of the dice roll |
| max | <code>number</code> | Upper bound of the dice roll |
| channel_name | <code>string</code> | Name of the chat channel |
| [channel_type] | <code>DOTAChatChannelType_t</code> | The type of the channel being joined |
<a name="module_Dota2.Dota2Client+requestChatChannels"></a>
#### dota2Client.requestChatChannels()
Requests a list of chat channels from the GC. Listen for the `chatChannelsData` event for the GC's response.
Requires the GC to be [ready](#module_Dota2.Dota2Client+event_ready).
**Kind**: instance method of [<code>Dota2Client</code>](#module_Dota2.Dota2Client)
<a name="module_Dota2.Dota2Client+requestPlayerMatchHistory"></a>
#### dota2Client.requestPlayerMatchHistory(account_id, [options], [callback])
Requests the given player's match history. The responses are paginated,
but you can use the `start_at_match_id` and `matches_requested` options to loop through them.
Provide a callback or listen for the [playerMatchHistoryData](#module_Dota2.Dota2Client+event_playerMatchHistoryData) event for the GC's response.
Requires the GC to be [ready](#module_Dota2.Dota2Client+event_ready).
**Kind**: instance method of [<code>Dota2Client</code>](#module_Dota2.Dota2Client)
| Param | Type | Default | Description |
| --- | --- | --- | --- |
| account_id | <code>number</code> | | Dota 2 account ID of the player whose match history the bot should fetch |
| [options] | <code>Object</code> | | Filtering options |
| [options.start_at_match_id] | <code>number</code> | | Which match ID to start searching at (pagination) |
| [options.matches_requested] | <code>number</code> | | How many matches to retrieve |
| [options.hero_id] | <code>number</code> | | Show only matches where player played the given hero |
| [options.request_id] | <code>number</code> | <code>account_id</code> | A unique identifier that identifies this request |
| [options.include_practice_matches] | <code>boolean</code> | | Whether or not to include practice matches in the results |
| [options.include_custom_games] | <code>boolean</code> | | Whether or not to include custom games in the results |
| [callback] | [<code>requestCallback</code>](#module_Dota2..requestCallback) | | Called with `err, CMsgDOTAGetPlayerMatchHistoryResponse` |
<a name="module_Dota2.Dota2Client+requestProfileCard"></a>
#### dota2Client.requestProfileCard(account_id, [callback])
Sends a message to the Game Coordinator requesting `account_id`'s profile card.
This method is heavily rate limited. When abused, the GC just stops responding.
Even the regular client runs into this limit when you check too many profiles.
Provide a callback or listen for [profileCardData](#module_Dota2.Dota2Client+event_profileCardData) event for Game Coordinator's response.
Requires the GC to be [ready](#module_Dota2.Dota2Client+event_ready).
**Kind**: instance method of [<code>Dota2Client</code>](#module_Dota2.Dota2Client)
| Param | Type | Description |
| --- | --- | --- |
| account_id | <code>number</code> | Dota 2 account ID of the player whose profile card the bot should fetch |
| [callback] | [<code>requestCallback</code>](#module_Dota2..requestCallback) | Called with `err, CMsgDOTAProfileCard` |
<a name="module_Dota2.Dota2Client+requestProfile"></a>
#### dota2Client.requestProfile(account_id, [callback])
Sends a message to the Game Coordinator requesting `account_id`'s profile page.
This method is heavily rate limited. When abused, the GC just stops responding.
Even the regular client runs into this limit when you check too many profiles.
Provide a callback or listen for [profileData](#module_Dota2.Dota2Client+event_profileData) event for Game Coordinator's response.
Requires the GC to be [ready](#module_Dota2.Dota2Client+event_ready).
**Kind**: instance method of [<code>Dota2Client</code>](#module_Dota2.Dota2Client)
| Param | Type | Description |
| --- | --- | --- |
| account_id | <code>number</code> | Dota 2 account ID of the player whose profile page the bot should fetch |
| [callback] | [<code>requestCallback</code>](#module_Dota2..requestCallback) | Called with `err, CMsgDOTAProfileResponse` |
<a name="module_Dota2.Dota2Client+requestHallOfFame"></a>
#### dota2Client.requestHallOfFame(week, [callback])
Sends a message to the Game Coordinator requesting the Hall of Fame data for `week`.
Provide a callback or listen for the [hallOfFameData](#module_Dota2.Dota2Client+event_hallOfFameData) event for the Game Coordinator's response.
Requires the GC to be [ready](#module_Dota2.Dota2Client+event_ready).
**Kind**: instance method of [<code>Dota2Client</code>](#module_Dota2.Dota2Client)
| Param | Type | Description |
| --- | --- | --- |
| week | <code>number</code> | The week of which you wish to know the Hall of Fame members; will return latest week if omitted. Weeks are counted from start of unix epoch with a lower bound of 2233 (2012-10-18) |
| [callback] | [<code>requestCallback</code>](#module_Dota2..requestCallback) | Called with `err, CMsgDOTAHallOfFameResponse` |
<a name="module_Dota2.Dota2Client+requestPlayerInfo"></a>
#### dota2Client.requestPlayerInfo(account_ids)
Sends a message to the Game Coordinator requesting one or multiple `account_ids` player information.
This includes their display name, country code, team info and sponsor, fantasy role, official information lock status, and if the user is marked as a pro player.
Listen for the [playerInfoData](#module_Dota2.Dota2Client+event_playerInfoData) event for the Game Coordinator's response.
Requires the GC to be [ready](#module_Dota2.Dota2Client+event_ready).
**Kind**: instance method of [<code>Dota2Client</code>](#module_Dota2.Dota2Client)
| Param | Type | Description |
| --- | --- | --- |
| account_ids | <code>number</code> \| <code>Array.<number></code> | Either a single or array of Account IDs (lower 32-bits of a 64-bit Steam ID) of desired user(s) player info. |
<a name="module_Dota2.Dota2Client+requestTrophyList"></a>
#### dota2Client.requestTrophyList(account_id, [callback])
Sends a message to the Game Coordinator requesting `account_id`'s trophy data.
Provide a callback or listen for [trophyListData](#module_Dota2.Dota2Client+event_trophyListData) event for Game Coordinator's response.
Requires the GC to be [ready](#module_Dota2.Dota2Client+event_ready).
**Kind**: instance method of [<code>Dota2Client</code>](#module_Dota2.Dota2Client)
| Param | Type | Description |
| --- | --- | --- |
| account_id | <code>number</code> | Dota 2 account ID of the player whose trophy data the bot should fetch |
| [callback] | [<code>requestCallback</code>](#module_Dota2..requestCallback) | Called with `err, CMsgClientToGCGetTrophyListResponse` |
<a name="module_Dota2.Dota2Client+requestPlayerStats"></a>
#### dota2Client.requestPlayerStats(account_id, [callback])
Sends a message to the Game Coordinator requesting `account_id`'s player stats.
Provide a callback or listen for [playerStatsData](#module_Dota2.Dota2Client+event_playerStatsData) event for Game Coordinator's response.
This data contains all stats shown on a player's profile page.
Requires the GC to be [ready](#module_Dota2.Dota2Client+event_ready).
**Kind**: instance method of [<code>Dota2Client</code>](#module_Dota2.Dota2Client)
| Param | Type | Description |
| --- | --- | --- |
| account_id | <code>number</code> | Dota 2 account ID of the player whose player stats the bot should fetch |
| [callback] | [<code>requestCallback</code>](#module_Dota2..requestCallback) | Called with `err, CMsgGCToClientPlayerStatsResponse` |
<a name="module_Dota2.Dota2Client+tipPlayer"></a>
#### dota2Client.tipPlayer(account_id, steam_id, steam_id)
Attempts to tip a player for his performance during a match. Listen for the `tipResponse` event for the GC's response.
Requires the GC to be [ready](#module_Dota2.Dota2Client+event_