netsensia/pinnacle-sports-api
Composer 安装命令:
composer require netsensia/pinnacle-sports-api
包简介
API Wrapper for the Pinnacle Sports API
README 文档
README
A PHP Client wrapper for the Pinnacle Sports API (https://www.pinnacle.com/en/api/manual)
You will need an API key to use this client. This is the Base64 value of UTF-8 encoded username:password
Add to project using Composer
composer require "netsensia/pinnacle-sports-api:1.0.0"
Usage
$client = new Client($apiKey);
$sports = $client->getSports();
$leagues = $client->getLeagues(33); // 33 is the id for tennis, as obtained from getSports()
$fixtures = $client->getFixtures(33);
$odds = $client->getOdds(33);
A full list of available calls can be found by examining the ClientSpec.php file which contains the spec tests. Additional parameters can be seen in the Client.php file.
Development
Clone the repo and compose
git clone git@github.com:netsensia/pinnacle-sports-api
cd pinnacle-sports-api
php composer.phar install
Run the tests
Create a file called .apiKey in the root of the project and add your api key to it.
bin/phpspec run --format=pretty -vvv --stop-on-failure
统计信息
- 总下载量: 138
- 月度下载量: 0
- 日度下载量: 0
- 收藏数: 0
- 点击次数: 0
- 依赖项目数: 0
- 推荐数: 0
其他信息
- 授权协议: MIT
- 更新时间: 2016-11-10