2017 © Pedro PelĂĄez
 

library marvel-api-client

An API client to handle calls to the Marvel API.

image

ikoene/marvel-api-client

An API client to handle calls to the Marvel API.

  • Tuesday, May 9, 2017
  • by ikoene
  • Repository
  • 0 Watchers
  • 3 Stars
  • 10 Installations
  • PHP
  • 0 Dependents
  • 0 Suggesters
  • 1 Forks
  • 0 Open issues
  • 7 Versions
  • 0 % Grown

The README.md

Insight Build Status Scrutinizer Code Quality Installs Packagist license, (*1)

Marvel API client

The Marvel Comics API allows developers everywhere to access information about Marvel's vast library of comics—from what's coming up, to 70 years ago. This Marvel API client helps you explore the Marvel universe with great ease., (*2)

Requirements

Installation

Add the API client as a dependency to your project using Composer., (*3)

composer require ikoene/marvel-api-client

Usage

<?php

require_once dirname(__DIR__) . '/vendor/autoload.php';

use ikoene\Marvel\Client;

$client = new Client('your_public_api_key', 'your_private_api_key');

$response = $client->getCharacter(1009610);

var_dump($response);

Endpoints

You can call every endpoint with an explicitly defined method. So if you, for example, want a list of comics containing a specific character, you can call getComicsForCharacter()., (*4)

$response = $client->getComicsForCharacter(1009610);

Optional filters

It's also possible to add optional filters to the calls. Let's get all comics for 'Spider-Man' which title starts with 'Age of Ultron' and order the results by 'title'., (*5)

$comicFilter = new \ikoene\Marvel\Entity\ComicFilter();
$comicFilter->setTitleStartsWith('Age of Ultron');
$comicFilter->setOrderBy('title');

$response = $client->getComicsForCharacter(1009610, $comicFilter);

Pretty easy, right?, (*6)

Examples

You can find some more examples here., (*7)

Additional info

The Versions

09/05 2017

dev-master

9999999-dev

An API client to handle calls to the Marvel API.

  Sources   Download

MIT

The Requires

 

The Development Requires

30/10 2016

0.0.5

0.0.5.0

An API client to handle calls to the Marvel API.

  Sources   Download

MIT

The Requires

 

The Development Requires

01/10 2016

0.0.4

0.0.4.0

An API client to handle calls to the Marvel API.

  Sources   Download

MIT

The Requires

 

The Development Requires

01/10 2016

dev-feature/travis-ci

dev-feature/travis-ci

An API client to handle calls to the Marvel API.

  Sources   Download

MIT

The Requires

 

The Development Requires

28/09 2016

0.0.3

0.0.3.0

An API client to handle calls to the Marvel API.

  Sources   Download

MIT

The Requires

 

27/09 2016

0.0.2

0.0.2.0

An API client to handle calls to the Marvel API.

  Sources   Download

MIT

The Requires

 

23/09 2016

0.0.1

0.0.1.0

An API client to handle calls to the Marvel API.

  Sources   Download

MIT

The Requires