jikan-rest/README.MD

135 lines
6.3 KiB
Plaintext
Raw Normal View History

2018-12-17 11:53:13 +05:00
![Jikan](http://i.imgur.com/ctoJ3Jp.png)
# Jikan - Unofficial MyAnimeList.net REST API
2020-04-25 12:33:36 +05:00
[![Average time to resolve an issue](http://isitmaintained.com/badge/resolution/jikan-me/jikan-rest.svg)](http://isitmaintained.com/project/jikan-me/jikan-rest "Average time to resolve an issue") [![Percentage of issues still open](http://isitmaintained.com/badge/open/jikan-me/jikan-rest.svg)](http://isitmaintained.com/project/jikan-me/jikan-rest "Percentage of issues still open") [![stable](https://img.shields.io/badge/PHP-^7.2.5-blue.svg?style=flat)]() [![Discord Server](https://img.shields.io/discord/460491088004907029.svg?style=flat&logo=discord)](https://discordapp.com/invite/4tvCr36)
2018-04-21 13:28:44 +05:00
2021-04-11 23:05:40 +05:00
Jikan is a REST API for [MyAnimeList.net](https://myanimelist.net). It scrapes the website to satisfy the need for some API functionality - that MyAnimeList lacks.
2018-04-21 13:28:44 +05:00
2021-04-11 23:05:40 +05:00
The raison d'être of Jikan is to assist developers easily get the data they need for their apps and projects without having to depend on unstable APIs, or sidetracking their projects to develop parsers.
2018-04-21 13:28:44 +05:00
2018-12-17 11:53:13 +05:00
The word _Jikan_ literally translates to _Time_ in Japanese (**時間**). And that's what this API saves you of. ;)
2018-04-21 13:28:44 +05:00
2021-04-11 23:05:40 +05:00
**Notice**: Jikan does not support authenticated requests. You can not update your lists. Use the official MyAnimeList API for this.
2018-12-17 11:53:13 +05:00
2019-11-15 11:31:29 -08:00
## Index
2021-04-11 23:09:54 +05:00
- [What's new?](#whats-new)
2019-11-15 11:31:29 -08:00
- [Getting Started](#getting-started)
- [Requirements](#requirements)
- [🐳 Docker](#-docker)
- [Installation Prerequisites](#01-installation-prerequisites)
- [Installation](#02-installation)
- [Configuration](#03-configuration)
- [Ignition](#04-ignition)
- [Configuring Cache Driver](#05-configuring-how-jikan-caches-optional) (optional)
- [Configuring Cache Method](#06-configuring-how-jikan-handles-expired-cache-optional) (optional)
- [Configuring Supervisord](#configuring-supervisord) (optional)
- [Troubleshooting](#troubleshooting)
- [Artisan Commands](#artisan-commands)
- [Information](#information)
- [Wrappers](#wrappers)
- [Running Tests](#running-tests)
- [Backers](#backers)
- [Disclaimer](#disclaimer)
2021-04-11 23:09:54 +05:00
## What's new?
2018-12-17 11:53:13 +05:00
## Getting Started
### Requirements
2021-04-11 23:05:40 +05:00
- PHP ^7.4
2019-03-03 14:48:08 -08:00
- [Composer](https://getcomposer.org/download/)
2021-04-11 23:05:40 +05:00
- [MongoDB]()
2018-12-17 11:53:13 +05:00
2019-05-15 14:08:18 +05:00
2021-04-12 00:09:25 +05:00
## Getting started
### Requirements
- PHP ^7.4.7
- MongoDB
- Apache (optional)
### Installation
#### Prerequisites
1. Install git and build-essentials for compiling PHP MongoDB library `sudo apt install git build-essential`
2. Install
1. PHP: `sudo apt update && sudo apt -y install software-properties-common && sudo add-apt-repository ppa:ondrej/php && sudo apt-get update && sudo apt -y install php7.4`
2. PHP dependencies `sudo apt install php7.4-{mbstring,xml,dev,pear,zip,common}`
3. Install PHP MongoDB driver `sudo pecl install mongodb`
4. Add `extension=mongodb.so` to your `php.ini`
5. Installing Apache (optional)
1. `sudo apt install apache2`
2. Set `AllowOverride All` in `apache2.conf` for `<Directory /var/www/>`
3. Edit your virtual host document root
1. By default in `/etc/apache2/sites-available/000-default.conf`: `DocumentRoot /var/www/jikan-rest/public`
4. Enable mod rewrite `sudo a2enmod deflate && sudo a2enmod rewrite`
5. Enable mod deflate (for GZIP responses): `sudo a2enmod deflate && sudo a2enmod rewrite`
4. Restart apache: `sudo service apache2 restart`
#### Jikan REST
1. Clone the repo in `/var/www` - `git clone https://github.com/jikan-me/jikan-rest.git`
2. Switch to v4 branch `git checkout v4`
3. Install [composer](https://getcomposer.org/download/)
4. Install project dependencies with composer `php path/to/composer.phar install`
2019-11-15 11:31:29 -08:00
## Information
2018-12-17 11:53:13 +05:00
If you don't want to host your instance, there's a public API available.
2021-04-11 23:09:54 +05:00
- **[REST DOCUMENTATION](http://docs.api.jikan.moe/)**
2018-12-17 11:53:13 +05:00
- **[Apps/Projects using JikanREST](https://jikan.moe/showcase)**
2021-04-11 23:13:03 +05:00
### Wrappers
| Language | Wrappers |
|------------|----------|
| JavaScript | [JikanJS](https://github.com/zuritor/jikanjs) by Zuritor |
| Java | [Jikan4java](https://github.com/Doomsdayrs/Jikan4java) by Doomsdayrs<br>[reactive-jikan](https://github.com/SandroHc/reactive-jikan) by Sandro Marques |
| Python | [JikanPy](https://github.com/abhinavk99/jikanpy) by Abhinav Kasamsetty |
| Node.js | [jikan-node](https://github.com/xy137/jikan-node) by xy137<br>[jikan-nodejs](https://github.com/ribeirogab/jikan-nodejs) by ribeirogab |
| TypeScript | [jikants](https://github.com/Julien-Broyard/jikants) by Julien Broyard<br>[jikan-client](https://github.com/javi11/jikan-client) by Javier Blanco |
| PHP | [jikan-php](https://github.com/janvernieuwe/jikan-jikanPHP) by Jan Vernieuwe |
| .NET | [Jikan.net](https://github.com/Ervie/jikan.net) by Ervie |
| Elixir | [JikanEx](https://github.com/seanbreckenridge/jikan_ex) by Sean Breckenridge |
| Go | [jikan-go](https://github.com/darenliang/jikan-go) by Daren Liang<br>[jikan2go](https://github.com/nokusukun/jikan2go) by nokusukun |
| Ruby | [Jikan.rb](https://github.com/Zerocchi/jikan.rb) by Zerocchi |
| Dart | [jikan-dart](https://github.com/charafau/jikan-dart) by Rafal Wachol |
| Kotlin | [JikanKt](https://github.com/GSculerlor/JikanKt) by Ganedra Afrasya |
[Add your wrapper here](https://github.com/jikan-me/jikan-rest/edit/master/readme.md)
2018-12-17 11:53:13 +05:00
2019-11-15 11:31:29 -08:00
## Running Tests
`php vendor/bin/phpunit tests`
Note: Tests may fail due to rate limit from MyAnimeList (HTTP 429)
2019-06-02 14:46:35 +05:00
---
2019-11-15 11:31:29 -08:00
## Backers
2019-06-02 14:46:35 +05:00
2020-02-22 22:01:45 +05:00
## Sugoi (すごい) Backers
Thank you to all our **Sugoi (すごい)** backers! 🙏 [[Become a sugoi backer](https://patreon.com/jikan)]
2019-08-26 08:20:27 -07:00
- [Jared Allard (jaredallard)](https://github.com/jaredallard)
2020-02-22 22:01:45 +05:00
- [hugonun (hug_onun)](https://twitter.com/hug_onun)
2019-08-26 08:20:27 -07:00
2019-11-15 11:31:29 -08:00
## Backers
2019-06-02 14:46:35 +05:00
Thank you to all our backers! 🙏 [[Become a backer](https://patreon.com/jikan)]
- [PurplePinapples](https://github.com/purplepinapples/)
- [Barkdoll (Jesse)](https://github.com/barkdoll/)
2019-06-20 10:33:51 +05:00
- [Piotr Szymczak (Drutol)](https://github.com/Drutol)
2019-08-24 06:26:37 -07:00
- [Jason Weatherly (jamesthebard)](https://twitter.com/jamesthebard)
2019-08-26 08:20:27 -07:00
- [Cesar Irad Mendoza (aberuwu)](https://github.com/aberuwu)
2019-11-15 11:31:29 -08:00
## Sponsors
Thank you to all our sponsors! [[Become a sponsor](https://patreon.com/jikan)]
2019-06-02 14:46:35 +05:00
- [Hibiki Matsujo](https://github.com/assintates)
---
2018-12-17 11:53:13 +05:00
## DISCLAIMER
- Jikan is not affiliated with MyAnimeList.net
- You are responsible for the usage of this API. Please be respectful towards MyAnimeList's [Terms Of Service](https://myanimelist.net/about/terms_of_use)