Matrix calculation

Matrix calculation is an API call that calcualtes price comparison between different tour operators for one (or more) offers.

It generates a table of minimum prices for all room/service/tour operator combinations that match given search query.

This API call was mostly developed for use in ORS SMART B2B app, so it's use is probably not relevant for use on IBE.

API Endpoints

It's API endpoint is /search/<content type>/matrix

For example:

  • For hotel: /search/hotel/matrix
  • For pauschal: /search/pauschal/matrix

Trips content type is not supported.

Response structure

typedef Results = array{struct{
    # Contains definition for given offer
    Offer struct{
        # For hotel and pauschal types, this is a hotel name.
        # For trips this a trip name.
        OfferName string

        # Unique GIATA ID for this offer. Some offers might be
        # missing those.
        GiataID   bigint

        Picture   struct{
            # URL to object thumbnail picture (about 100x66 px)
            Thumbnail string

            # URL to object full-scale picture
            Full      string
        }

        # Object category (1-5)
        Category                 int

        # Rating of the offer (0-100)
        OfferRating              int

        # Percentage of guests recommending this object (0-100)
        RecommendationPercentage int

        Location struct{
            # Location name and its corresponding ID of this object
            LocationName    string
            LocationID      int

            # Region group and region (with coressponding IDs) this
            # object belongs to
            RegionGroupID   int
            RegionGroupName string
            RegionID        int
            RegionName      string

            # Object exact latitude and longitude. This information
            # is missing for some objects
            Latitude        float
            Longitude       float
        }

        Facts map{
            # Facts are short factoids about object properties.
            # Key in this map is a fact short code, and it's value
            # is a human-readable description of a factoid.
            string => string
        }

        # Contains additional GIATA tags. Key is tag name, which
        # usually corresponds to a specific fact in facts map.
        AdditionalTags map{
            string => struct{
                Value string # Human readable translation of an tag
            }
        }
    }

    # Contains matrix data for given offer
    Data array{struct{
        # Defines service combination this cell refers to
        Service struct{
            # Contains tour operator code
            TourOperator     string

            # Contains human readable tour operator name
            TourOperatorName string

            # Contains service code
            ServiceCode      string

            # Contains human readable service name
            ServiceName      string

            # Contains room code
            RoomType         string

            # Contains human readable room name
            RoomName         string
        }

        # Contains actual matrix data
        Data    array{struct{
            # Contains duration (in days) that this price referes to
            Duration int

            # Contains minimum price for this offer,
            # duration and service combination
            Price    int
        }}
    }}
}}

Filters and sors

This query does not support filtering.

Matrix results are always sorted in Duration fields.

Example response

{
    "RequestID": "d17c4dcc-5f80510701c1b032281444",
    "Results": [
        {
            "Offer": {
                "Product": {
                    "OfferName": "Aminess Laguna Hotel",
                    "GiataID": 6711,
                    "Picture": {
                        "Thumbnail": "https:\/\/ors.si\/giata-pics\/6711\/\/thumb.jpg",
                        "Full": "https:\/\/ors.si\/giata-pics\/6711\/\/full.jpg"
                    },
                    "Category": 3,
                    "OfferRating": 80,
                    "RecommendationPercentage": "88",
                    "Location": {
                        "LocationName": "Novigrad",
                        "LocationID": 1267,
                        "ArrivalAirport": null,
                        "ArrivalAirportName": null,
                        "RegionGroupID": "100023",
                        "RegionGroupName": "Croatia",
                        "RegionID": "1108",
                        "RegionName": "Istria",
                        "Latitude": "45.3154000000000000",
                        "Longitude": "13.5745000000000000"
                    },
                    "AdditionalTags": [],
                    "Facts": {
                        "bea": "directly on the beach",
                        "ben": "near the beach (approx. 100-500m)",
                        "chf": "family-friendly",
                        "ani": "animation program",
                        "spt": "a wide range of sports activities",
                        "pol": "pool",
                        "ipl": "indoor swimming pool",
                        "sws": "water sports",
                        "wel": "rich wellness offer",
                        "wbf": "beauty farms",
                        "sbs": "ball sports",
                        "sfr": "fitness",
                        "stn": "tennis",
                        "sth": "other sports activities",
                        "wifi": "wifi",
                        "cup": "for couples",
                        "sen": "seniors",
                        "yun": "for young people",
                        "chl": "children's discounts",
                        "air": "air condition",
                        "park": "parking"
                    }
                }
            },
            "Data": [
                {
                    "Service": {
                        "TourOperator": "PALM",
                        "TourOperatorName": "Palma",
                        "ServiceCode": "HP",
                        "ServiceName": "half board",
                        "RoomType": "DZ",
                        "RoomName": "double room"
                    },
                    "Data": [
                        {
                            "Duration": 3,
                            "Price": 259
                        }
                    ]
                },
                {
                    "Service": {
                        "TourOperator": "CENT",
                        "TourOperatorName": "Center Turizem",
                        "ServiceCode": "HP",
                        "ServiceName": "half board",
                        "RoomType": "DZ",
                        "RoomName": "double room"
                    },
                    "Data": [
                        {
                            "Duration": 1,
                            "Price": 32
                        },
                        {
                            "Duration": 2,
                            "Price": 64
                        },
                        {
                            "Duration": 3,
                            "Price": 97
                        },
                        {
                            "Duration": 4,
                            "Price": 129
                        },
                        {
                            "Duration": 5,
                            "Price": 162
                        },
                        {
                            "Duration": 6,
                            "Price": 194
                        },
                        {
                            "Duration": 7,
                            "Price": 226
                        },
                        {
                            "Duration": 8,
                            "Price": 259
                        },
                        {
                            "Duration": 9,
                            "Price": 291
                        },
                        {
                            "Duration": 10,
                            "Price": 324
                        },
                        {
                            "Duration": 11,
                            "Price": 356
                        },
                        {
                            "Duration": 12,
                            "Price": 388
                        },
                        {
                            "Duration": 13,
                            "Price": 421
                        },
                        {
                            "Duration": 14,
                            "Price": 453
                        }
                    ]
                },
                {
                    "Service": {
                        "TourOperator": "SJKH",
                        "TourOperatorName": "Sajko Turizem",
                        "ServiceCode": "HP",
                        "ServiceName": "half board",
                        "RoomType": "DZ",
                        "RoomName": "double room"
                    },
                    "Data": [
                        {
                            "Duration": 2,
                            "Price": 55
                        },
                        {
                            "Duration": 3,
                            "Price": 82
                        },
                        {
                            "Duration": 4,
                            "Price": 110
                        },
                        {
                            "Duration": 5,
                            "Price": 137
                        },
                        {
                            "Duration": 6,
                            "Price": 165
                        },
                        {
                            "Duration": 7,
                            "Price": 192
                        },
                        {
                            "Duration": 8,
                            "Price": 220
                        },
                        {
                            "Duration": 9,
                            "Price": 247
                        },
                        {
                            "Duration": 10,
                            "Price": 275
                        },
                        {
                            "Duration": 11,
                            "Price": 302
                        },
                        {
                            "Duration": 12,
                            "Price": 330
                        },
                        {
                            "Duration": 13,
                            "Price": 358
                        },
                        {
                            "Duration": 14,
                            "Price": 385
                        }
                    ]
                },
                {
                    "Service": {
                        "TourOperator": "RIVA",
                        "TourOperatorName": "RIVA",
                        "ServiceCode": "UF",
                        "ServiceName": "bed & breakfast",
                        "RoomType": "DZ",
                        "RoomName": "double room"
                    },
                    "Data": [
                        {
                            "Duration": 3,
                            "Price": 78
                        },
                        {
                            "Duration": 4,
                            "Price": 104
                        },
                        {
                            "Duration": 5,
                            "Price": 130
                        },
                        {
                            "Duration": 6,
                            "Price": 157
                        },
                        {
                            "Duration": 7,
                            "Price": 183
                        },
                        {
                            "Duration": 8,
                            "Price": 209
                        },
                        {
                            "Duration": 9,
                            "Price": 235
                        },
                        {
                            "Duration": 10,
                            "Price": 261
                        },
                        {
                            "Duration": 11,
                            "Price": 287
                        },
                        {
                            "Duration": 12,
                            "Price": 313
                        },
                        {
                            "Duration": 13,
                            "Price": 339
                        },
                        {
                            "Duration": 14,
                            "Price": 365
                        }
                    ]
                },
                {
                    "Service": {
                        "TourOperator": "PALH",
                        "TourOperatorName": "Palma Croatia",
                        "ServiceCode": "HP",
                        "ServiceName": "half board",
                        "RoomType": "DZ",
                        "RoomName": "double room"
                    },
                    "Data": [
                        {
                            "Duration": 1,
                            "Price": 260
                        },
                        {
                            "Duration": 2,
                            "Price": 460
                        },
                        {
                            "Duration": 3,
                            "Price": 630
                        },
                        {
                            "Duration": 4,
                            "Price": 840
                        },
                        {
                            "Duration": 5,
                            "Price": 1050
                        },
                        {
                            "Duration": 6,
                            "Price": 1260
                        },
                        {
                            "Duration": 7,
                            "Price": 1470
                        },
                        {
                            "Duration": 8,
                            "Price": 1680
                        },
                        {
                            "Duration": 9,
                            "Price": 1890
                        },
                        {
                            "Duration": 10,
                            "Price": 2100
                        },
                        {
                            "Duration": 11,
                            "Price": 2310
                        },
                        {
                            "Duration": 12,
                            "Price": 2520
                        },
                        {
                            "Duration": 13,
                            "Price": 2730
                        },
                        {
                            "Duration": 14,
                            "Price": 2940
                        }
                    ]
                },
                {
                    "Service": {
                        "TourOperator": "RLX",
                        "TourOperatorName": "Relax",
                        "ServiceCode": "HP",
                        "ServiceName": "half board",
                        "RoomType": "DZ",
                        "RoomName": "double room"
                    },
                    "Data": [
                        {
                            "Duration": 7,
                            "Price": 216
                        }
                    ]
                },
                {
                    "Service": {
                        "TourOperator": "RIVA",
                        "TourOperatorName": "RIVA",
                        "ServiceCode": "HP",
                        "ServiceName": "half board",
                        "RoomType": "DZ",
                        "RoomName": "double room"
                    },
                    "Data": [
                        {
                            "Duration": 3,
                            "Price": 94
                        },
                        {
                            "Duration": 4,
                            "Price": 126
                        },
                        {
                            "Duration": 5,
                            "Price": 157
                        },
                        {
                            "Duration": 6,
                            "Price": 189
                        },
                        {
                            "Duration": 7,
                            "Price": 220
                        },
                        {
                            "Duration": 8,
                            "Price": 252
                        },
                        {
                            "Duration": 9,
                            "Price": 283
                        },
                        {
                            "Duration": 10,
                            "Price": 315
                        },
                        {
                            "Duration": 11,
                            "Price": 346
                        },
                        {
                            "Duration": 12,
                            "Price": 378
                        },
                        {
                            "Duration": 13,
                            "Price": 409
                        },
                        {
                            "Duration": 14,
                            "Price": 441
                        }
                    ]
                }
            ]
        },
        {
            "Offer": {
                "Product": {
                    "OfferName": "Hotel in Paviljoni Ad Turres",
                    "GiataID": 34649,
                    "Picture": {
                        "Thumbnail": "https:\/\/ors.si\/giata-pics\/34649\/\/thumb.jpg",
                        "Full": "https:\/\/ors.si\/giata-pics\/34649\/\/full.jpg"
                    },
                    "Category": 3,
                    "OfferRating": 45,
                    "RecommendationPercentage": "67",
                    "Location": {
                        "LocationName": "Crikvenica-Dramalj",
                        "LocationID": 2693,
                        "ArrivalAirport": null,
                        "ArrivalAirportName": null,
                        "RegionGroupID": "100023",
                        "RegionGroupName": "Croatia",
                        "RegionID": "100434",
                        "RegionName": "Kvarner",
                        "Latitude": "45.1884000000000000",
                        "Longitude": "14.6754000000000000"
                    },
                    "AdditionalTags": [],
                    "Facts": {
                        "ben": "near the beach (approx. 100-500m)",
                        "chf": "family-friendly",
                        "ani": "animation program",
                        "spt": "a wide range of sports activities",
                        "pol": "pool",
                        "stn": "tennis",
                        "sth": "other sports activities",
                        "wifi": "wifi",
                        "yun": "for young people",
                        "chl": "children's discounts",
                        "pet": "pets allowed",
                        "park": "parking"
                    }
                }
            },
            "Data": [
                {
                    "Service": {
                        "TourOperator": "PALM",
                        "TourOperatorName": "Palma",
                        "ServiceCode": "HP",
                        "ServiceName": "half board",
                        "RoomType": "DZ",
                        "RoomName": "double room"
                    },
                    "Data": [
                        {
                            "Duration": 3,
                            "Price": 259
                        }
                    ]
                },
                {
                    "Service": {
                        "TourOperator": "CENT",
                        "TourOperatorName": "Center Turizem",
                        "ServiceCode": "HP",
                        "ServiceName": "half board",
                        "RoomType": "DZ",
                        "RoomName": "double room"
                    },
                    "Data": [
                        {
                            "Duration": 1,
                            "Price": 32
                        },
                        {
                            "Duration": 2,
                            "Price": 64
                        },
                        {
                            "Duration": 3,
                            "Price": 97
                        },
                        {
                            "Duration": 4,
                            "Price": 129
                        },
                        {
                            "Duration": 5,
                            "Price": 162
                        },
                        {
                            "Duration": 6,
                            "Price": 194
                        },
                        {
                            "Duration": 7,
                            "Price": 226
                        },
                        {
                            "Duration": 8,
                            "Price": 259
                        },
                        {
                            "Duration": 9,
                            "Price": 291
                        },
                        {
                            "Duration": 10,
                            "Price": 324
                        },
                        {
                            "Duration": 11,
                            "Price": 356
                        },
                        {
                            "Duration": 12,
                            "Price": 388
                        },
                        {
                            "Duration": 13,
                            "Price": 421
                        },
                        {
                            "Duration": 14,
                            "Price": 453
                        }
                    ]
                },
                {
                    "Service": {
                        "TourOperator": "SJKH",
                        "TourOperatorName": "Sajko Turizem",
                        "ServiceCode": "HP",
                        "ServiceName": "half board",
                        "RoomType": "DZ",
                        "RoomName": "double room"
                    },
                    "Data": [
                        {
                            "Duration": 2,
                            "Price": 55
                        },
                        {
                            "Duration": 3,
                            "Price": 82
                        },
                        {
                            "Duration": 4,
                            "Price": 110
                        },
                        {
                            "Duration": 5,
                            "Price": 137
                        },
                        {
                            "Duration": 6,
                            "Price": 165
                        },
                        {
                            "Duration": 7,
                            "Price": 192
                        },
                        {
                            "Duration": 8,
                            "Price": 220
                        },
                        {
                            "Duration": 9,
                            "Price": 247
                        },
                        {
                            "Duration": 10,
                            "Price": 275
                        },
                        {
                            "Duration": 11,
                            "Price": 302
                        },
                        {
                            "Duration": 12,
                            "Price": 330
                        },
                        {
                            "Duration": 13,
                            "Price": 358
                        },
                        {
                            "Duration": 14,
                            "Price": 385
                        }
                    ]
                },
                {
                    "Service": {
                        "TourOperator": "RIVA",
                        "TourOperatorName": "RIVA",
                        "ServiceCode": "UF",
                        "ServiceName": "bed & breakfast",
                        "RoomType": "DZ",
                        "RoomName": "double room"
                    },
                    "Data": [
                        {
                            "Duration": 3,
                            "Price": 78
                        },
                        {
                            "Duration": 4,
                            "Price": 104
                        },
                        {
                            "Duration": 5,
                            "Price": 130
                        },
                        {
                            "Duration": 6,
                            "Price": 157
                        },
                        {
                            "Duration": 7,
                            "Price": 183
                        },
                        {
                            "Duration": 8,
                            "Price": 209
                        },
                        {
                            "Duration": 9,
                            "Price": 235
                        },
                        {
                            "Duration": 10,
                            "Price": 261
                        },
                        {
                            "Duration": 11,
                            "Price": 287
                        },
                        {
                            "Duration": 12,
                            "Price": 313
                        },
                        {
                            "Duration": 13,
                            "Price": 339
                        },
                        {
                            "Duration": 14,
                            "Price": 365
                        }
                    ]
                },
                {
                    "Service": {
                        "TourOperator": "PALH",
                        "TourOperatorName": "Palma Croatia",
                        "ServiceCode": "HP",
                        "ServiceName": "half board",
                        "RoomType": "DZ",
                        "RoomName": "double room"
                    },
                    "Data": [
                        {
                            "Duration": 1,
                            "Price": 260
                        },
                        {
                            "Duration": 2,
                            "Price": 460
                        },
                        {
                            "Duration": 3,
                            "Price": 630
                        },
                        {
                            "Duration": 4,
                            "Price": 840
                        },
                        {
                            "Duration": 5,
                            "Price": 1050
                        },
                        {
                            "Duration": 6,
                            "Price": 1260
                        },
                        {
                            "Duration": 7,
                            "Price": 1470
                        },
                        {
                            "Duration": 8,
                            "Price": 1680
                        },
                        {
                            "Duration": 9,
                            "Price": 1890
                        },
                        {
                            "Duration": 10,
                            "Price": 2100
                        },
                        {
                            "Duration": 11,
                            "Price": 2310
                        },
                        {
                            "Duration": 12,
                            "Price": 2520
                        },
                        {
                            "Duration": 13,
                            "Price": 2730
                        },
                        {
                            "Duration": 14,
                            "Price": 2940
                        }
                    ]
                },
                {
                    "Service": {
                        "TourOperator": "RLX",
                        "TourOperatorName": "Relax",
                        "ServiceCode": "HP",
                        "ServiceName": "half board",
                        "RoomType": "DZ",
                        "RoomName": "double room"
                    },
                    "Data": [
                        {
                            "Duration": 7,
                            "Price": 216
                        }
                    ]
                },
                {
                    "Service": {
                        "TourOperator": "RIVA",
                        "TourOperatorName": "RIVA",
                        "ServiceCode": "HP",
                        "ServiceName": "half board",
                        "RoomType": "DZ",
                        "RoomName": "double room"
                    },
                    "Data": [
                        {
                            "Duration": 3,
                            "Price": 94
                        },
                        {
                            "Duration": 4,
                            "Price": 126
                        },
                        {
                            "Duration": 5,
                            "Price": 157
                        },
                        {
                            "Duration": 6,
                            "Price": 189
                        },
                        {
                            "Duration": 7,
                            "Price": 220
                        },
                        {
                            "Duration": 8,
                            "Price": 252
                        },
                        {
                            "Duration": 9,
                            "Price": 283
                        },
                        {
                            "Duration": 10,
                            "Price": 315
                        },
                        {
                            "Duration": 11,
                            "Price": 346
                        },
                        {
                            "Duration": 12,
                            "Price": 378
                        },
                        {
                            "Duration": 13,
                            "Price": 409
                        },
                        {
                            "Duration": 14,
                            "Price": 441
                        }
                    ]
                },
                {
                    "Service": {
                        "TourOperator": "PALH",
                        "TourOperatorName": "Palma Croatia",
                        "ServiceCode": "HP",
                        "ServiceName": "half board",
                        "RoomType": "DZ",
                        "RoomName": "double room"
                    },
                    "Data": [
                        {
                            "Duration": 1,
                            "Price": 200
                        },
                        {
                            "Duration": 2,
                            "Price": 360
                        },
                        {
                            "Duration": 3,
                            "Price": 540
                        },
                        {
                            "Duration": 4,
                            "Price": 720
                        },
                        {
                            "Duration": 5,
                            "Price": 900
                        },
                        {
                            "Duration": 6,
                            "Price": 1080
                        },
                        {
                            "Duration": 7,
                            "Price": 1260
                        },
                        {
                            "Duration": 8,
                            "Price": 1440
                        },
                        {
                            "Duration": 9,
                            "Price": 1620
                        },
                        {
                            "Duration": 10,
                            "Price": 1800
                        },
                        {
                            "Duration": 11,
                            "Price": 1980
                        },
                        {
                            "Duration": 12,
                            "Price": 2160
                        },
                        {
                            "Duration": 13,
                            "Price": 2340
                        },
                        {
                            "Duration": 14,
                            "Price": 2520
                        }
                    ]
                },
                {
                    "Service": {
                        "TourOperator": "PALM",
                        "TourOperatorName": "Palma",
                        "ServiceCode": "HP",
                        "ServiceName": "half board",
                        "RoomType": "DZ",
                        "RoomName": "double room"
                    },
                    "Data": [
                        {
                            "Duration": 1,
                            "Price": 26
                        },
                        {
                            "Duration": 2,
                            "Price": 48
                        },
                        {
                            "Duration": 3,
                            "Price": 72
                        },
                        {
                            "Duration": 4,
                            "Price": 96
                        },
                        {
                            "Duration": 5,
                            "Price": 120
                        },
                        {
                            "Duration": 6,
                            "Price": 144
                        },
                        {
                            "Duration": 7,
                            "Price": 168
                        },
                        {
                            "Duration": 8,
                            "Price": 192
                        },
                        {
                            "Duration": 9,
                            "Price": 216
                        },
                        {
                            "Duration": 10,
                            "Price": 241
                        },
                        {
                            "Duration": 11,
                            "Price": 265
                        },
                        {
                            "Duration": 12,
                            "Price": 289
                        },
                        {
                            "Duration": 13,
                            "Price": 313
                        },
                        {
                            "Duration": 14,
                            "Price": 337
                        }
                    ]
                }
            ]
        }
    ]
}