API v2 bug: series 70366 says 30 pages of data, but page 30 is a 404

A place for developers to advertise their TheTVDB.com enabled app and get help from other developers with the API.
Post Reply
rkulagow
Posts: 72
Joined: Mon Oct 15, 2012 11:04 am

Sun Oct 08, 2017 3:07 pm

When I execute:

Code: Select all

https://api.thetvdb.com/series/70366/episodes
I get:

Code: Select all

{
  "links": {
    "first": 1,
    "last": 30,
    "next": 2,
    "prev": null
  }
But if I then request page 30:

Code: Select all

https://api.thetvdb.com/series/70366/episodes?page=30
I get a 404, with:

Code: Select all

{
  "Error": "No results for your query: map[tve.seriesId:70366]"
}
That's making the grabber library I'm using (thetvdb2 / adrenth) to error out.

Code: Select all

PHP Fatal error:  Uncaught Adrenth\Thetvdb\Exception\ResourceNotFoundException: Resource not found at path: /series/70366/episodes [parameters: page=30] in /home/ubuntu/json-php/vendor/adrenth/thetvdb2/lib/Adrenth/Thetvdb/Exception/ResourceNotFoundException.php:25
Stack trace:
#0 /home/ubuntu/json-php/vendor/adrenth/thetvdb2/lib/Adrenth/Thetvdb/Client.php(213): Adrenth\Thetvdb\Exception\ResourceNotFoundException::withPath('/series/70366/e...', Array)
#1 /home/ubuntu/json-php/vendor/adrenth/thetvdb2/lib/Adrenth/Thetvdb/Client.php(178): Adrenth\Thetvdb\Client->performApiCall('get', '/series/70366/e...', Array)
#2 /home/ubuntu/json-php/vendor/adrenth/thetvdb2/lib/Adrenth/Thetvdb/Extension/SeriesExtension.php(90): Adrenth\Thetvdb\Client->performApiCallWithJsonResponse('get', '/series/70366/e...', Array)
#3 /home/ubuntu/json-php/thetvdb.php(764): Adrenth\Thetvdb\Extension\SeriesExtension->getEpisodes('70366', 30)
#4 /home/ubuntu/json-php/thetvdb.php(152): processEpisode('70366', 'EP00001189')
#5 {main}
  thrown in /home/ubuntu/json-php/vendor/adrenth/thetvdb2/lib/Adrenth/Thetvdb/Exception/ResourceNotFoundException.php on line 25

rkulagow
Posts: 72
Joined: Mon Oct 15, 2012 11:04 am

Sun Oct 08, 2017 10:23 pm

Same issue exists with

Code: Select all

https://api.thetvdb.com/series/123401/episodes
{
"links": {
"first": 1,
"last": 13,
"next": 2,
"prev": null
},

There's no page 13.
Post Reply