Closed abitofevrything closed 1 year ago
I thought at first this is an API error, but it's not. Transferring it back to Jikan repo.
@abitofevrything The url is null because the list items on MAL doesn't have episode video urls yet, and the parser is looking for those instead of the episode-url
bit:
https://github.com/jikan-me/jikan/blob/master/src/Model/Anime/EpisodeListItem.php#L82
This will be populated for sure in the future.
Not sure if this is a bug. @irfan-dahir you might know more about this.
Well, the docs should at least be updated to reflect this. It's also very easy to generate the URL, just adding /episode/<number>
to the anime URL so we could fall back to that if no episode URL is found.
Updated the docs of the API: https://github.com/jikan-me/jikan-rest/pull/346/commits/7120c1eb03a1d6698362560fdfa43f57ce26c308#diff-feaa1d5b3b940a08f5552b0863a27844827f26e11244ef8d9adb3b80a843bccfL206 It will be part of the next release of the API.
The docs indicate that the
url
field in each element of the array returned bygetAnimeEpisodes
is not nullable, yet it returns null for some anime.To reproduce:
curl https://api.jikan.moe/v4/anime/51815/episodes
(Kubo-san wa Mob wo Yurusanai).Note that requesting the episode directly does return a valid URL: