---
title: 'Hotels inventory'
url: 'https://documentation.netstorming.net/api-reference/hotels/hotels-inventory'
markdown: 'https://documentation.netstorming.net/api-reference/hotels/hotels-inventory.md'
date: '2026-11-10'
description: 'This API is meant to obtain a minimal amount of data for hotels available for your account. You should use this API for mapping and/or to obtain your inventory of "buyable" product. The list is paginated, so you probably have to call this API more than once using the parameter "start_from" to brows…'
taxonomy:
  category:
    - docs
---

# Hotels inventory

[](#)  [ API reference ](https://documentation.netstorming.net/api-reference)     [ Hotels ](https://documentation.netstorming.net/api-reference/hotels)      Hotels inventory    

This API is meant to obtain a minimal amount of data for hotels available for your account.
You should use this API for mapping and/or to obtain your inventory of "buyable" product.
The list is paginated, so you probably have to call this API more than once using the parameter "start\_from" to browse the list from where you left the previous time.

##### Request

The **type** attribute has to be set to *get\_inventory*.

The request have no compulsory parameters, but you can (and prabably want) provide two:

- **start\_from**: it is an "offset" field. Allows you to get results starting from the requested index.
- **batch\_size**: you can adjust the number of results returned with each query.
    Actually the default is 1.000 and the maximum allowed value is 10.000. With 10.000 hotels the response would weight about 1.5MB

```xml
<?xml version="1.0" encoding="UTF-8"?>  
<envelope>
    <header>
        <actor>test</actor>
        <user>test</user>
        <password>test</password>
        <version>1.6.6</version>
        <timestamp>20221005172521</timestamp>
    </header>
    <query type="get_inventory" product="hotel">
        <start_from>10</start_from>
        <batch_size>3</batch_size>
    </query>
</envelope>
```

##### Response

```xml
<?xml version="1.0" encoding="UTF-8"?>  
<envelope>
    <header>
        <version>1.6.8</version>
        <timestamp>20221005172521</timestamp>
    </header>
    <response type="get_inventory" product="hotel">
        <hotels from="10" to="13" total="238937">
            <hotel id="78" name="ANCHORAGE PORT STEPHENS" city="2POR" lt="-32.719394000000000" lg="152.105925000000000" address="Corlette Point Road, 2315," has_photos="true"/>
            <hotel id="80" name="GRAND EURHOTEL &amp; RESIDENCE" city="7MON" lt="42.516362538100000" lg="14.156239447600000" address="Via Carlo Maresca, 32, 65015," has_photos="true"/>
            <hotel id="81" name="GRAND HOTEL MONTESILVANO" city="7MON" lt="42.516362538100000" lg="14.156239447600000" address="Piazzale Kennedy, 28, 65015," has_photos="false"/>
        </hotels>
    </response>
</envelope>
```

The response message contains in its **response**, tag the **hotels** tag.

The **hotels** tag has 3 attributes:

- **from**: index of the first element (corresponds to **start\_from** param from the request)
- **to**: index of the last element (=from+batch\_size)
- **total**: total amount of hotels. You should perform the *get\_inventory* call until **to** would be equal to **total**

The **hotels** tag contains all the **hotel** tags.

Each **hotel** tag contains the following attributes:

- **id**: hotel's identifier
- **name**: hotel's name
- **city**: city code (please refer to [cities API](https://documentation.netstorming.net/api-reference/static-details-search/cities-search) in order to translate city codes)
- **lt**: hotel's latitude
- **lg**: hotel's longitude
- **address**: hotel's address
- **has\_photos**: if the hotel have at least one picture. If true, you can build the picture url with the following structure: `https://pictures.netstorming.net/common/hotels/<HOTEL_ID>/original/0.jpg`. You have to replace `<HOTEL_ID>` with the actual numeric hotel id.

 [ ](https://documentation.netstorming.net/api-reference/hotels/hotels-search-static-data) [](https://documentation.netstorming.net/api-reference/hotels/hotel-details)

---

## Navigation

- Parent: [Hotels](https://documentation.netstorming.net/api-reference/hotels.md)
- Previous: [Hotels search](https://documentation.netstorming.net/api-reference/hotels/hotels-search-static-data.md)
- Next: [Hotel details](https://documentation.netstorming.net/api-reference/hotels/hotel-details.md)
