2017 © Pedro Peláez
 

package fantasydata

PHP library for the Fantasy Data API

image

konradbaron/fantasydata

PHP library for the Fantasy Data API

  • Friday, February 2, 2018
  • by konradbaron
  • Repository
  • 1 Watchers
  • 2 Stars
  • 6 Installations
  • PHP
  • 0 Dependents
  • 0 Suggesters
  • 0 Forks
  • 0 Open issues
  • 1 Versions
  • 100 % Grown

The README.md

PHP-FantasyData

PHP-FantasyData is a PHP library for the FantasyData API version 3. This library currently only contains wrappers for the Full NFL section, and the NBA Scores section of the API. Other sections are planned to be added in the future., (*1)

The API currently returns your data in two formats; JSON and XML., (*2)

Requirements

This library requires the use of Composer., (*3)

composer require konradbaron/fantasydata:dev-master

You must first register an account to receive an API key from FantasyData Portal. There is a free trial option, which limits the amount of API calls to 1K per month., (*4)

Example Usage

NFL, (*5)

    use KonradBaron\FantasyData\FantasyDataNFLPlayByPlay;
    $fd = new FantasyDataNFLPlayByPlay('YOUR_API_KEY');
    echo $fd->playByPlay('json', '2016REG', 8, 'WAS');

NBA, (*6)

    use KonradBaron\FantasyData\FantasyDataNBAScores;
    $fd = new FantasyDataNBAScores('YOUR_API_KEY');
    echo $fd->schedules('json', '2016');

The Versions

02/02 2018

dev-master

9999999-dev

PHP library for the Fantasy Data API

  Sources   Download

The Requires

 

by Konrad Baron

api fantasy data