Download the PHP package kronusme/dota2-api without Composer

On this page you can find all versions of the php package kronusme/dota2-api. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.

FAQ

After the download, you have to make one include require_once('vendor/autoload.php');. After that you have to import the classes with use statements.

Example:
If you use only one package a project is not needed. But if you use more then one package, without a project it is not possible to import the classes with use statements.

In general, it is recommended to use always a project to download your libraries. In an application normally there is more than one library needed.
Some PHP packages are not free to download and because of that hosted in private repositories. In this case some credentials are needed to access such packages. Please use the auth.json textarea to insert credentials, if a package is coming from a private repository. You can look here for more information.

  • Some hosting areas are not accessible by a terminal or SSH. Then it is not possible to use Composer.
  • To use Composer is sometimes complicated. Especially for beginners.
  • Composer needs much resources. Sometimes they are not available on a simple webspace.
  • If you are using private repositories you don't need to share your credentials. You can set up everything on our site and then you provide a simple download link to your team member.
  • Simplify your Composer build process. Use our own command line tool to download the vendor folder as binary. This makes your build process faster and you don't need to expose your credentials for private repositories.
Please rate this library. Is it a good library?

Informations about the package dota2-api

DotA2-Api

Build Status Coverage Status License Latest Stable Version Dependencies Code Climate

About

  1. What is it? This is PHP code for processing DotA 2 API-requests.

  2. What can it do? It can get match-list for some criteria, get match-info for single match, get steam-profile info for users. AND save all this data in MySQL database. For more information see - "How to use it".

  3. What I need to work with it? First of all you need web-server with PHP 5.3+ ( PDO and cURL should be enabled) and MySQL 5. Then look at install section.

Install

  1. Install via Composer: `

  2. Connect to your mysql-server with any tool (phpmyadmin, heidisql etc) and execute code from the file db_latest.sql.

  3. Initialize Dota2-Api like this: ``

Requests

Type URL
Supported
GetMatchHistory https://api.steampowered.com/IDOTA2Match_570/GetMatchHistory/v001/
GetMatchDetails https://api.steampowered.com/IDOTA2Match_570/GetMatchDetails/v001/
GetPlayerSummaries https://api.steampowered.com/ISteamUser/GetPlayerSummaries/v0002/
GetLeagueListing https://api.steampowered.com/IDOTA2Match_570/GetLeagueListing/v0001/
GetLiveLeagueGames https://api.steampowered.com/IDOTA2Match_570/GetLiveLeagueGames/v0001/
GetTeamInfoByTeamID https://api.steampowered.com/IDOTA2Match_570/GetTeamInfoByTeamID/v001/
GetHeroes https://api.steampowered.com/IEconDOTA2_570/GetHeroes/v0001/
GetTournamentPrizePool https://api.steampowered.com/IEconDOTA2_570/GetTournamentPrizePool/v1/
GetGameItems https://api.steampowered.com/IEconDOTA2_570/GetGameItems/v0001/
Unsupported
EconomySchema https://api.steampowered.com/IEconItems_570/GetSchema/v0001/
GetMatchHistoryBySequenceNum https://api.steampowered.com/IDOTA2Match_570/GetMatchHistoryBySequenceNum/v0001/

How to use it

IMPORTANT!

Before parsing and saving leagues matches to your DB, make sure that you've saved leagues to the DB (using leaguesMapperWeb! If you try to save some "public" matches, you should REMOVE foreign key for field leagueid in the table matches!

Load some match-info

$match - it's an object with all match data including slots info, ability-upgrades (if provided) and pick, bans (if cm-mode).

Save match-info in the database

matchMapperDb will check if match with $match->get('match_id') exists in the db and select method for save (insert or update).

Work with match-object

I want get last 25 matches with some player

``

Get player info

`` Player's id you can get via Player::convertId('xxxxx') method (xxxxx - its DotA ID).

Get team info

``

Get current heroes list

`` $heroes - array with numeric indexes (heroes ids)

Get current items list

``

Save received from web items list to db

``

Get current items list from db

``

Get leagues list

`` $leagues - array with numeric indexes (leagues ids)

Get leagues prize pool

``

``

Get live leagues matches

`` $games - array of live_match objects

Get matches from local db

``

Delete match(es) from local db

``

Get info about abilities, heroes, items, games mods, lobby types etc

``

Get map with barracks and towers

``

Get info about players from db

or for just getting one player, you can also use

Save info about players into db

``

Work with UGC Objects

``

Thanks

  1. Valve for DotA 2 and Web API.

  2. MuppetMaster42, for http://dev.dota2.com/showthread.php?t=58317.

  3. Players, who don't hide their own statistic.

  4. dev.dota2 community.

All versions of dota2-api with dependencies

PHP Build Version
Package Version
Requires php Version >5.2
Composer command for our command line client (download client) This client runs in each environment. You don't need a specific PHP version etc. The first 20 API calls are free. Standard composer command

The package kronusme/dota2-api contains the following files

Loading the files please wait ....