sprak3000/anime-news-network-data-api

There is no license information available for the latest version (3.0.0) of this package.

A PHP client library for Anime News Network data

3.0.0 2023-07-26 00:54 UTC

This package is auto-updated.

Last update: 2024-03-28 03:04:05 UTC


README

Tests Maintainability Test Coverage

This is a PHP client wrapper for the Anime News Network data API. If you are interested in contributing back to this project, feel free to read the Contributing documentation below.

NOTE: When using this client to retrieve data, you must still abide by the ANN API terms of service:

When using this API to display information on a public website, you must list Anime News Network as the source of the data and link to Anime News Network on every page that incorporates data from the API.

Requires

  • PHP ^8.0
  • Composer (to install this library)

Usage

<?php
$client = new sprak3000\AnimeNewsNetworkDataAPI\Client();
$anime = $client->getAnime(['anime' => '16148'])->toArray();
$manga = $client->getManga(['manga' => '4199'])->toArray();

Detecting API Errors

Unfortunately, the ANN API does not return a non 200 HTTP response code for an invalid / not found ID. To check for an error, look for a warning key in the result array.

Known Limitations / Issues

None at this time.

Installing via Composer

composer require sprak3000/AnimeNewsNetworkDataAPI

Continuous Integration

This project uses GitHubActions for build and continuous integration.

Documentation

All documentation can be found in the doc folder.

Contributing