Introduction

In this introduction, you will find the basic information about iGMS API and how to use it. If you have already worked with our API or with similar services from other platforms, and you know which app you want to create, we recommend that you go to any applicable documentation section.

API (application programming interface) – This is an intermediary between the app’s developer and some environment with which this app should interact. This API makes it easy to create a code because it provides a set of defined classes, functions and structures for working with your data.

iGMS API – This interface allows information to be received from the database igms.com with the help of http-requests to the special server. You do not need to know in detail how the base is constructed and from which table and field types it consists of. It is enough that API-request “knows” it. The request syntax and the type of data being returned are strictly determined by the service itself.

For example, to receive data about the Airbnb guest with the ID number “153154662”, you need to make a request of this type:

https://igms.com/api/v1/listings?listing_uids=1_airbnb_123&access_token=sometoken

Let’s have a look at the individual parts:

  • https:// - connection protocol
  • igms.com/api/ — API server address and path to root entry point for all methods
  • v1/listings — name of iGMS API “method”. Methods represent conditional commands that correspond with an operation from the database to receive, record or delete information. For example, listings is a method to receive information about a listing from a platform like Airbnb, bookings is a method to receive information about bookings, etc.

    There is a full list of methods available on this page.

  • ?listing_uids=1_airbnb_123&access_token=sometoken – request parameters. After naming the method, you need to transfer its entry data (if it has it) - as usual, GET-parameters in http-requests. With our example, we tell the server that we want data about the listing having uid equals ”1_airbnb_123”. Also, we have included the access_token parameter which is a key giving access to data.

In its response, the server returns JSON-object with the requested data (or a message about a mistake if something went wrong). JSON is the format for how data is reported in the format of “Characteristic Name”: “Value”. If you have not used this format before, we recommend that you acquaint yourself with it before you continue reading: JSON, Wikipedia

The response to this request looks like this:

{
    "data": [
        {
            "listing_uid": "1_airbnb_123",
            "listing_name": "Best flat in the world (no Wi-Fi)",
            "listing_status": "active",
            "listing_thumbnail_url": "https://a0.muscache.com/im/pictures/d6b9cd3a-99e0-4cd4-bcee-631b20a3eac1.jpg",
            "listing_url": "https://www.airbnb.ca/rooms/19379397",
            "timezone_offset_minutes": -420,
            "platform_type": "airbnb",
            "property_uid": "1482329366187",
            "property_name": "1BR flat with Wi-Fi",
            "property_address": "Go forward, then turn right",
            "property_status": "active",
            "host_uid": "123_airbnb",
            "host_name": "John Doe"
        }
    ],
    "meta": {
        "page": 1,
        "has_next_page": true
    }
}

If you already have experience of working with JSON, you can find useful information about the JSON structure of iGMS API answers here: JSON Schema.

Authorization

To perform any API request you need to provide an access token as an URL query string parameter (named as access_token), regardless of the request method used. The token gives you access to retreive data related to an iGMS client who granted you such access. More details about obtaining access tokens can be found in the Getting a Token section.

What’s next?

You have now gotten acquainted with the basics of iGMS API. The rest is up to you.

Of course, in real life, no one works with API in adjacent browser tabs. For this, different programming languages, SDK and code generators are used. The API working mechanism is very simple. The means of sending http-requests and handling responses from the server are practically provided in any environment. This means freedom of choice is constantly existent.