2017 © Pedro Peláez
 

library tvmaze-api-client

TVmaze API Client is a wrapper to work with the TVMaze API

image

devvoh/tvmaze-api-client

TVmaze API Client is a wrapper to work with the TVMaze API

  • Tuesday, August 29, 2017
  • by robindevoh
  • Repository
  • 1 Watchers
  • 0 Stars
  • 12 Installations
  • PHP
  • 0 Dependents
  • 0 Suggesters
  • 0 Forks
  • 0 Open issues
  • 5 Versions
  • 0 % Grown

The README.md

tvmzaze-api-client

A very barebones API client, currently only intended to search for shows and get their information, including episodes. No crew list, etc. at this point., (*1)

Here's the example script:, (*2)

$client = new TVmazeApi\Client();
$shows = $client->searchShow("firefl");

// Loop through the shows and show their id & name
foreach ($shows as $show) {
    echo "#{$show->id}: {$show->name}\n";
}

echo "\n";

// Get Firefly by id
$show = $client->fetchShowById(180);
echo "{$show->name} episodes:\n";
foreach ($client->fetchEpisodesByShowId($show->id) as $episode) {
    echo "{$episode->getNiceShortTag()} - {$episode->name}\n";
}

To get only the highest-scoring search result:, (*3)

$client = new TVmazeApi\Client();

$show = $client->searchOneShow("firefl");

To get an array of matching search results:, (*4)

$shows = $client->searchShow("firefl");

To get a show by its ID:, (*5)

$show = $client->fetchShowById(180);

To get a show's episodes by the show's ID:, (*6)

$show = $client->fetchShowById(180);
$episodes = $client->fetchEpisodesByShowId($show->id);

The Versions

29/08 2017

dev-master

9999999-dev

TVmaze API Client is a wrapper to work with the TVMaze API

  Sources   Download

MIT

The Requires

  • php >=5.6

 

api library tvmaze

29/08 2017

0.1.3

0.1.3.0

TVmaze API Client is a wrapper to work with the TVMaze API

  Sources   Download

MIT

The Requires

  • php >=5.6

 

api library tvmaze

29/08 2017

0.1.2

0.1.2.0

TVmaze API Client is a wrapper to work with the TVMaze API

  Sources   Download

MIT

The Requires

  • php >=5.6

 

api library tvmaze

29/08 2017

0.1.1

0.1.1.0

TVmaze API Client is a wrapper to work with the TVMaze API

  Sources   Download

MIT

The Requires

  • php >=5.6

 

api library tvmaze

25/08 2017

0.1.0

0.1.0.0

TVmaze API Client is a wrapper to work with the TVMaze API

  Sources   Download

MIT

The Requires

  • php >=5.6

 

api library tvmaze