# ESI Pages

**URL:** <https://forums.eveonline.com/t/esi-pages/26080>\
**Category:** Third Party Developers\
**Created:** [September 21, 2017, 6:18am UTC](https://forums.eveonline.com/t/esi-pages/26080 "2017-09-21T06:18:40Z")\
**Posts on this page:** 11\
**Page:** 1

<div class="post-metadata">

**Author:** ![Minerva\_Arbosa](https://sea1.discourse-cdn.com/eveonline/user_avatar/forums.eveonline.com/minerva_arbosa/32/263946_2.png) [@Minerva\_Arbosa](https://forums.eveonline.com/u/Minerva_Arbosa)\
**Post date:** [September 21, 2017, 6:18am UTC](https://forums.eveonline.com/t/esi-pages/26080/1 "2017-09-21T06:18:40Z")

</div>

How does one figure out from the ESI calls how many pages to ask for in end points such as /markets/{region\_id}/types or other ESI calls which you have to declare what page you are seeking? Any one able to point me in the right direction or let me know it would be appreciated.

---

<div class="post-metadata">

**Author:** ![CCP\_Zoetrope](https://sea1.discourse-cdn.com/eveonline/user_avatar/forums.eveonline.com/ccp_zoetrope/32/278627_2.png) [@CCP\_Zoetrope](https://forums.eveonline.com/u/CCP_Zoetrope)\
**Post date:** [September 21, 2017, 8:52am UTC](https://forums.eveonline.com/t/esi-pages/26080/2 "2017-09-21T08:52:01Z")

</div>

We actually published a blog about this recently! [https://developers.eveonline.com/blog/article/esi-concurrent-programming-and-pagination](https://developers.eveonline.com/blog/article/esi-concurrent-programming-and-pagination)

---

<div class="post-metadata">

**Author:** ![Golden\_Gnu](https://sea1.discourse-cdn.com/eveonline/user_avatar/forums.eveonline.com/golden_gnu/32/459734_2.png) [@Golden\_Gnu](https://forums.eveonline.com/u/Golden_Gnu)\
**Post date:** [September 21, 2017, 11:57am UTC](https://forums.eveonline.com/t/esi-pages/26080/3 "2017-09-21T11:57:52Z")

</div>

Note that the wallet endpoints, also, does not have x-pages (they use fromID).  
You need to continue until you get an empty result. Due to a bug ([https://github.com/ccpgames/esi-issues/issues/553](https://github.com/ccpgames/esi-issues/issues/553)) you also have the check that the current page does not match the last or you may end up with a never-ending-loop.

---

<div class="post-metadata">

**Author:** ![Minerva\_Arbosa](https://sea1.discourse-cdn.com/eveonline/user_avatar/forums.eveonline.com/minerva_arbosa/32/263946_2.png) [@Minerva\_Arbosa](https://forums.eveonline.com/u/Minerva_Arbosa)\
**Post date:** [September 21, 2017, 6:57pm UTC](https://forums.eveonline.com/t/esi-pages/26080/4 "2017-09-21T18:57:22Z")

</div>

CCP Zoetrope, thank you for the help.

Reading the blog makes more sense now for writing the code to access those end points with pagination.

Just for reference, which might also help other developers in the future, the Try It Out! feature on [http://esi.tech.ccp.is](http://esi.tech.ccp.is) does not actually display the header X-Pages even though it displays much of the other header information.

---

<div class="post-metadata">

**Author:** ![CCP\_Zoetrope](https://sea1.discourse-cdn.com/eveonline/user_avatar/forums.eveonline.com/ccp_zoetrope/32/278627_2.png) [@CCP\_Zoetrope](https://forums.eveonline.com/u/CCP_Zoetrope)\
**Post date:** [September 22, 2017, 7:53am UTC](https://forums.eveonline.com/t/esi-pages/26080/5 "2017-09-22T07:53:44Z")

</div>

@Minerva_Arbosa I’m not sure what you mean about the Try it Out! feature not displaying the header X-Pages. It is displayed both in the documentation and when you click “Try It Out!”:

 ![x-pages-documentation](https://global.discourse-cdn.com/eveonline/original/3X/7/6/762bf93793779746a2398ffaeba75846ad8d87c7.png)  
 ![x-pages-response-headers](https://global.discourse-cdn.com/eveonline/original/3X/2/8/2805ed6666f4fea1b70b0196dfbceea95d77be67.png)

But if you do find a case where there’s an endpoint that has X-Pages but it is not displayed in the documentation please let us know [here](https://github.com/ccpgames/esi-issues/issues) :).

---

<div class="post-metadata">

**Author:** ![Minerva\_Arbosa](https://sea1.discourse-cdn.com/eveonline/user_avatar/forums.eveonline.com/minerva_arbosa/32/263946_2.png) [@Minerva\_Arbosa](https://forums.eveonline.com/u/Minerva_Arbosa)\
**Post date:** [September 23, 2017, 1:00am UTC](https://forums.eveonline.com/t/esi-pages/26080/6 "2017-09-23T01:00:52Z")

</div>

CCP Zoetrope, I was talking about on the [http://esi.tech.ccp.is](http://esi.tech.ccp.is) page where you linked your picture from. There is a button at the bottom of each end point where you can try the end point out in your browser which displays all of the header information you should see and the data for the parameters which were put in. It’s really helpful when coding new features into libraries and such.

---

<div class="post-metadata">

**Author:** ![Blacksmoke16](https://sea1.discourse-cdn.com/eveonline/user_avatar/forums.eveonline.com/blacksmoke16/32/376589_2.png) [@Blacksmoke16](https://forums.eveonline.com/u/Blacksmoke16)\
**Post date:** [September 23, 2017, 1:27am UTC](https://forums.eveonline.com/t/esi-pages/26080/7 "2017-09-23T01:27:50Z")

</div>

He is probably using an endpoint that doesn’t that header yet. I.e. one of these:

```auto
 https://esi.tech.ccp.is/latest/#!/Contacts/get_characters_character_id_contacts
 https://esi.tech.ccp.is/latest/#!/Corporation/get_corporations_corporation_id_structures
 https://esi.tech.ccp.is/latest/#!/Market/get_markets_structures_structure_id
 https://esi.tech.ccp.is/latest/#!/Universe/get_universe_groups
 https://esi.tech.ccp.is/latest/#!/Universe/get_universe_types
 https://esi.tech.ccp.is/latest/#!/Wars/get_wars_war_id_killmails

```

---

<div class="post-metadata">

**Author:** ![Minerva\_Arbosa](https://sea1.discourse-cdn.com/eveonline/user_avatar/forums.eveonline.com/minerva_arbosa/32/263946_2.png) [@Minerva\_Arbosa](https://forums.eveonline.com/u/Minerva_Arbosa)\
**Post date:** [September 24, 2017, 6:26pm UTC](https://forums.eveonline.com/t/esi-pages/26080/8 "2017-09-24T18:26:55Z")

</div>

I was using the markets/{region\_id}/orders end point. Which is supposed to have the X-Pages header, but when getting the header information from X-Pages doesn’t show up. I have already submitted an issue on github about it. It’s not the only header having an issue when you look at the issues section.

---

<div class="post-metadata">

**Author:** ![Blacksmoke16](https://sea1.discourse-cdn.com/eveonline/user_avatar/forums.eveonline.com/blacksmoke16/32/376589_2.png) [@Blacksmoke16](https://forums.eveonline.com/u/Blacksmoke16)\
**Post date:** [September 24, 2017, 6:44pm UTC](https://forums.eveonline.com/t/esi-pages/26080/9 "2017-09-24T18:44:43Z")

</div>

Strange, because if i use that in chrome or postman i can see the headers, but in Curl it isn’t there. Have to see what the devs can figure out.

---

<div class="post-metadata">

**Author:** ![Zeke\_Darkweaver](https://imageserver.eveonline.com/Character/1_512.jpg) [@Zeke\_Darkweaver](https://forums.eveonline.com/u/Zeke_Darkweaver)\
**Post date:** [October 15, 2017, 10:38am UTC](https://forums.eveonline.com/t/esi-pages/26080/10 "2017-10-15T10:38:33Z")

</div>

It appears that X-Pages is not included if the result set is \< 10k (i.e a single page).

If you do all market orders for say Jita 4-4 with no type ID (i.e every order for every typeID) for sells. The X-Pages header shows.

If you look for a specific type ID for sells for example, there is no header, I suspect due to it being a single page.

The way around this would probably be to check the header is set, and if so, continue pagination, if not just ignore pagination code.

---

<div class="post-metadata">

**Author:** ![system](https://global.discourse-cdn.com/eveonline/original/3X/4/1/41ec4921cbaca7a6f9ea556e7cc20018461eae5e.png) [@system](https://forums.eveonline.com/u/system)\
**Post date:** [January 13, 2018, 10:38am UTC](https://forums.eveonline.com/t/esi-pages/26080/11 "2018-01-13T10:38:38Z")

</div>

Closed on January 13, 2018, 10:38am UTC

This topic was automatically closed 90 days after the last reply. New replies are no longer allowed.
