Giter VIP home page Giter VIP logo

myanimelist-api's Introduction

MyAnimeList Unofficial API
==========================

An unofficial API for the awesome http://myanimelist.net/.

Why?
----
There're no official plans by MyAnimeList to release an official API yet. I
intend to use this API to build other apps.

What do I need to run this?
---------------------------
* ruby 1.9.3 or later.
* libxml2 and libxslt (for nokogiri)
* Bundler gem.
* memcached

myanimelist-api's People

Contributors

6 avatar chrislegault avatar chuyeow avatar damien avatar dependabot[bot] avatar riotopsys avatar srvrguy avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

myanimelist-api's Issues

top anime end point reporting member_score as score

The score field is used for the score given by the user and is constrained to integer values values 0 thru 10 inclusive.

However the top endpoint gives it as a float value

Also the value returned does match the correct value for member_score

I've included a representative sample of the incorrect data below.

[
    {
        "id": 5114,
        "title": "Fullmetal Alchemist: Brotherhood",
        "other_titles": {},
        "synopsis": null,
        "type": "TV",
        "rank": null,
        "popularity_rank": null,
        "image_url": "http://cdn.myanimelist.net/images/anime/5/47421t.jpg",
        "episodes": 64,
        "status": null,
        "start_date": null,
        "end_date": null,
        "genres": [],
        "tags": [],
        "classification": null,
        "members_score": null,
        "members_count": 209762,
        "favorited_count": null,
        "manga_adaptations": [],
        "prequels": [],
        "sequels": [],
        "side_stories": [],
        "parent_story": null,
        "character_anime": [],
        "spin_offs": [],
        "summaries": [],
        "alternative_versions": [],
        "listed_anime_id": null,
        "watched_episodes": null,
        "score": 9.21,
        "watched_status": null
    },

CORS Support

I'm attempting to use the API on a mobile web site, and I am running into what I think are CORS issues. When I you issue a regular XHR GET request it works fine. However, when I specify a custom header, in my case the Basic authentication, my requests fail. I think the reason is because when you add a custom header the browser first sends a pre-flight OPTIONS request to the endpoint to see if it is OK. If the endpoint returns a 200, then it continues on and sends the GET request.

Currently, OPTIONS requests to any URL returns a 404 which prevents my requests from completing. I can use JSONP as a workaround, but it is an undesired way to call into the API.

If there is a solution to this from the consumer end let me know.

Anime Functions Broken

{"details":"Exception message: wrong number of arguments (1 for 0)","error":"unknown-error"}

Returned entity encoding is inconsistent

The entity encodings differ between single-anime results and a list of animes.

Compare these two results:
Correct: http://mal-api.com/anime/search?q=Black%20Rock%20Shooter

Unnecessary entities: http://mal-api.com/anime/search?q=Black%20Rock%20Shooter%20(OVA)
http://mal-api.com/anime/search?q=Yuru%20Yuri%E2%99%AA%E2%99%AA

I guess this is the case because a single result gets treated differently than a result list, I don't really know Ruby though, so I'm not of much help code-wise.

Search API Broken

No results will show unless you type in the full title. This effects both anime and manga.

mal-api.com site down

Hello,

I apologize if this isn't the right place to ask, but I haven't found a better place yet. The public api site at mal-api.com appears to be down and has stayed down for a good while now. Is it simply dead for good? Or has it moved or something?

Thanks :)

mal-api.com, all methods return error or empty array

Hi, I don't know where I can ask someone about this API, so I'm asking here.

I used this public API (mal-api.com) and it worked fine, but now it doesn't work. So first question, is it still public API? Can I use mal-api.com or do I have to set this code up on my own server?

So, now each method of API (mal-api.com) returnls error or empty array:

For example:

http://mal-api.com/animelist/xinil (Status Code 500)
{"error":"unknown-error","details":"Exception message: undefined method `text' for nil:NilClass"}

http://mal-api.com/anime/1887 (Status Code 500)
{"error":"unknown-error","details":"Exception message: Error scraping anime with ID=1887. Original exception: undefined method `[]' for nil:NilClass."}

Can you tell what is going wrong?

Thanks

Exception on profile endpoint

I created a profile for testing the scraping. If you hit a newly created profile (http://mal-api.com/profile/partial_profile) the current site raises an exception. The problem lies in the profile page has some inconsistent layout. If a user does not have an anime/manga history, then a table isn't rendered for that part of the page.

Suggest changing from:

details, updates, anime_stats, manga_stats = main_content.search("> table table")

To something more specific:

details = main_content.at('div.normal_header:contains("Details")').next_element
updates = main_content.at('div.normal_header:contains("Last List Updates")').next_element
anime_stats = main_content.at('h2:contains("Anime Stats")').next_element
manga_stats = main_content.at('h2:contains("Manga Stats")').next_element

This might catch all the scenarios a little better.

Genres not fetched correctly

As an example, take Umineko no Naku Koro ni: http://myanimelist.net/anime/4896/Umineko_no_Naku_Koro_ni

You can see in the information: "Genres: Mystery, Horror, Supernatural, Psychological". However, when using /anime/search the resulting genres array is empty.

Python example:

import urllib.request
import json
searchresult = urllib.request.urlopen("http://mal-api.com/anime/search?q=umineko").read()
parsedresult = json.loads(searchresult.decode())
for anime in parsedresult:
   print(anime['title'], anime['genres'])

Output:
Umineko no Naku Koro ni []
Umineko no Naku Koro ni Specials []

Unable to login to MAL Updater

Using this API I get the error:
"MAL Updater OS X was unable to log you in since you don't have the correct username and/or password."
Although my username and password are correct.
Any help would be much appreciated.

Update: I spoke to the MAL Updater OS X maintainer and he pointed me here too, it does appear to be an issue with the api.
Any luck looking at the logs?

Still unable to authenticate with api

Getting a seemingly random mixture of errors when trying to save a token with MAL Updater OS X.
Is it possible to look at any logs to find out where the problem is?
Username and password are definitely correct.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.