Jump to content


API Request GET parameter 'limit' does not work


  • Please log in to reply
No replies to this topic

Kilohauli #1 Posted 03 August 2020 - 09:31 AM

    Private

  • Player
  • 4624 battles
  • 2
  • [GENTA] GENTA
  • Member since:
    03-06-2019

Hopefully posting this to correct place.

 

When running request with limit the response does not have limit applied. Tried with Tankopedia Vehices request and below is the request and heavily truncated response. The response will come out with all results for Tier X.

 

The request itself (without https:// as this would create a true link from it)

api.worldoftanks.eu/wot/encyclopedia/vehicles/?application_id=<removed>&limit=2&tier=10&fields=name

 

The JSON response

{

"status": "ok",
-
"meta": {< >"count": 69,"page_total": 35,"total": 69,"limit": 2,"page": null
-
"data": {

-
"2417": {< >"name": "TVP T 50/51"
-
"2433": {< >"name": "Kranvagn"
-
"2721": {< >"name": "Progetto M40 mod. 65"
-
"3473": {< >"name": "60TP Lewandowskiego"
-
"3649": {< >"name": "Bat.-Châtillon 25 t"},

..

}

 

The pasted JSON result seems to get broken when copy pasting directly with own selection from response modal. But that's not important for this.

 

#Added: Copied the tankopedia list to own json file. It seems to consist all of the tanks. I only chose few fields that I need. But by local search for key tank_id has result of 667 matches. So actually there is not even limit of 100 applied currently.


Edited by Kilohauli, 05 August 2020 - 01:30 PM.





1 user(s) are reading this topic

0 members, 1 guests, 0 anonymous users