Booking Engine Guide
  • Mews Booking Engine Guide
  • Booking Engine Standalone
    • Getting started
    • Deeplinks
  • Booking Engine Widget
    • Getting started
    • Use cases
      • Prerequisites
      • Testing in the Demo environment
      • Using your own Date inputs
      • Multiple enterprises and pre-selected locations
      • Disabling widget caching
    • Advanced guide
    • Reference
    • Troubleshooting
  • Booking Engine API
    • Usage guidelines
      • Authentication
      • Requests
      • Responses
      • Environments
      • Images
      • Supported currency codes
      • Supported language codes
    • Use cases
      • Availability blocks
      • On session payments
      • Payment card authorization
      • Supporting payment cards
    • API Operations
      • Availability blocks
      • Configuration
      • Hotels
      • Payment cards
      • Reservations
      • Reservation groups
      • Services
      • Vouchers
    • Deprecations
  • Integrations
    • Google Tag Manager
    • Google Triggers Reference
    • Google Tag Manager Configuration
    • Google Analytics cross-domain tracking
  • FAQ
    • Ways to integrate
    • Migration off the mews.li domain
  • Changelog
    • Changelog 2024
    • Changelog 2023
    • Changelog 2022
    • Changelog 2021
    • Changelog 2020
Powered by GitBook
On this page
  • Get services availability
  • Request
  • Response
  • Get services pricing
  • Request
  • Response
  • Response diagram

Was this helpful?

  1. Booking Engine API
  2. API Operations

Services

Get services availability

Get availability for the specified service for each time unit in the specified date interval.

Request

[ApiBaseUrl]/api/distributor/v1/services/getAvailability

{
    "Client": "My Client 1.0.0",
    "EnterpriseId": "3edbe1b4-6739-40b7-81b3-d369d9469c48",
    "ServiceId": "40665467-5862-4932-a861-aa6b00e2b660",
    "StartUtc": "202-01-01T00:00:00Z",
    "EndUtc": "2022-01-31T00:00:00Z",
    "CategoryIds": ["4037c0ec-a59d-43f1-9d97-d6c984764e8c"],
    "LanguageCode": "en-GB"
}
Property
Type
Contract
Description

Client

string

required

EnterpriseId

string

required

Unique identifier of the enterprise.

ServiceId

string

required

StartUtc

string

required

Start date of the requested interval.

EndUtc

string

required

End date of the requested interval.

CategoryIds

array of string

optional

Unique identifiers of specific categories for which availability should be returned. If omitted, availability will be returned for all categories.

LanguageCode

string

optional

Response

{
  "TimeUnitStartsUtc": [
    "2022-10-04T22:00:00Z",
    "2022-10-05T22:00:00Z",
    "2022-10-06T22:00:00Z"
  ],
  "CategoryAvailabilities": [
    {
      "CategoryId": "ddc48d9f-f21d-422a-b24a-aa6b00e2b77e",
      "Availabilities": [
        56,
        40,
        26
      ]
    },
    {
      "CategoryId": "abcdefg-08ad-4d19-98cc-aa6b00e2999e",
      "Availabilities": [
        0,
        10,
        0
      ]
    }
  ]
}
Property
Type
Contract
Description

TimeUnitStartsUtc

array of string

required

Each time unit specified in request interval. Values are in UTC timezone in ISO 8601 format.

CategoryAvailabilities

required

List of availability counts for each category. Each availability number belongs to TimeUnitStartsUtc linked by same index.

Category Availability

Property
Type
Contract
Description

CategoryId

string

required

Identifier of the room category.

Availabilities

array of number

required

List of availability counts for each TimeUnitStartsUtc linked by same index.

Get services pricing

Get pricing for the specified service for each time unit in the specified date interval.

Request

[ApiBaseUrl]/api/distributor/v1/services/getPricing

{
    "Client": "My Client 1.0.0",
    "EnterpriseId": "3edbe1b4-6739-40b7-81b3-d369d9469c48",
    "ServiceId": "40665467-5862-4932-a861-aa6b00e2b660",
    "StartUtc": "202-01-01T00:00:00Z",
    "EndUtc": "2022-01-31T00:00:00Z",
    "CategoryIds": ["4037c0ec-a59d-43f1-9d97-d6c984764e8c"],
    "RateIds": ["4037c0ec-a59d-43f1-9d97-d6c984764e8c"],
    "LanguageCode": "en-GB",
    "CurrencyCode": "EUR"
}
Property
Type
Contract
Description

Client

string

required

EnterpriseId

string

required

Unique identifier of the enterprise.

ServiceId

string

required

StartUtc

string

required

Start date of the requested interval.

EndUtc

string

required

End date of the requested interval.

CategoryIds

array of string

optional

Unique identifiers of specific room categories for which pricing should be computed. If omitted, pricing will be computed and returned for all room categories.

RateIds

array of string

optional

Unique identifiers of specific rates for which pricing should be computed. If omitted, pricing will be computed and returned for all rates.

LanguageCode

string

optional

CurrencyCode

string

optional

Response

{
  "RateGroups":[
    {
      "Id": "3ede420b-9e9e-4008-abef-abc800c82505",
      "Ordering": 0,
      "SettlementType": "Manual",
      "SettlementAction": "ChargeCreditCard",
      "SettlementTrigger": "Start",
      "SettlementValue": 1.00,
      "SettlementOffset": "P0M0DT0H0M0S",
      "SettlementMaximumNights": null,
      "SettlementMaximumTimeUnits": null,
      "SettlementCurrencyCode": null
    }
  ],
  "Rates":[
    {
      "Id": "f02923a9-ffa3-4d83-a9d7-abc800c81111",
      "ServiceId": "33c75941-c2ec-467e-9797-abc800c8110d",
      "RateGroupId": "3ede420b-9e9e-4008-abef-abc800c82505",
      "Ordering": 0,
      "Name": {
        "es-ES": "Fully Flexible",
        "en-US": "Fully Flexible"
      },
      "Description": {},
      "IsPrivate": false,
      "CurrencyCode": "EUR"
    }
  ],
  "CategoryPrices": [
    {
      "CategoryId": "4037c0ec-a59d-43f1-9d97-d6c984764e8c",
      "OccupancyPrices": [
        {
          "Occupancies": [
            {
              "AgeCategoryId": "16e8a466-729e-4d32-a221-ade300e410a8",
              "PersonCount": 2
            },
            {
              "AgeCategoryId": "790c82c1-cbe6-4b8d-a45f-ade300e410a8",
              "PersonCount": 0
            }
          ]
        }
      ],
      "RateGroupPrices":[
        {
          "MinRateId": "abd865c2-8cc3-4ebc-acad-aca100b125b9",
          "MinPrice": {
            "TotalAmount": {
              "Currency": "EUR",
              "GrossValue": 83.41,
              "NetValue": 77.65,
              "Breakdown": {
                "Items": [
                  {
                    "TaxRateCode": null,
                    "NetValue": 18.11,
                    "TaxValue": 0.0
                  },
                  {
                    "TaxRateCode": "CZ-L",
                    "NetValue": 57.50,
                    "TaxValue": 5.76
                  },
                  {
                    "TaxRateCode": "CZ-Z",
                    "NetValue": 2.04,
                    "TaxValue": 0.00
                  }
                ]
              }
            },
            "AverageAmountPerTimeUnit": {
              "Currency": "EUR",
              "GrossValue": 41.71,
              "NetValue": 38.83,
              "Breakdown": {
                "Items": [
                  {
                    "TaxRateCode": null,
                    "NetValue": 9.06,
                    "TaxValue": 0.0
                  },
                  {
                    "TaxRateCode": "CZ-L",
                    "NetValue": 28.75,
                    "TaxValue": 2.88
                  },
                  {
                    "TaxRateCode": "CZ-Z",
                    "NetValue": 1.02,
                    "TaxValue": 0.00
                  }
                ]
              }
            }
          },
          "MaxPrice": {
            "TotalAmount": {
              "Currency": "EUR",
              "GrossValue": 20020.15,
              "NetValue": 18201.97,
              "Breakdown": {
                "Items": [
                  {
                    "TaxRateCode": null,
                    "NetValue": 18.11,
                    "TaxValue": 0.0
                  },
                  {
                    "TaxRateCode": "CZ-L",
                    "NetValue": 18181.82,
                    "TaxValue": 1818.18
                  },
                  {
                    "TaxRateCode": "CZ-Z",
                    "NetValue": 2.04,
                    "TaxValue": 0.00
                  }
                ]
              }
            },
            "AverageAmountPerTimeUnit": {
              "Currency": "EUR",
              "GrossValue": 10010.08,
              "NetValue": 9100.99,
              "Breakdown": {
                "Items": [
                  {
                    "TaxRateCode": null,
                    "NetValue": 9.06,
                    "TaxValue": 0.0
                  },
                  {
                    "TaxRateCode": "CZ-L",
                    "NetValue": 9090.91,
                    "TaxValue": 909.09
                  },
                  {
                    "TaxRateCode": "CZ-Z",
                    "NetValue": 1.02,
                    "TaxValue": 0.00
                  }
                ]
              }
            }
          }
        }
      ]
    }
  ]
}
Property
Type
Contract
Description

RateGroups

required

Information about all available rate groups.

Rates

required

Information about all available rates.

CategoryPrices

required

Prices for all specified categories.

Category price

Property
Type
Contract
Description

CategoryId

string

required

Unique identifier of category.

OccupancyPrices

required

List of occupancies for age categories against which rate group prices are supplied.

RateGroupPrices

required

Prices for the given category for each of the occupancy bands specified in OccupancyPrices.

Occupancy

Property
Type
Contract
Description

AgeCategoryId

string

required

Identifier of age category.

PersonCount

number

required

Number of persons of this Age category type.

Rate group price

Property
Type
Contract
Description

MinRateId

string

required

Unique identifier of rate.

MinPrice

required

Minimal price for the specified interval for rate.

MaxPrice

required

Maximal price for the specified interval for rate.

Min price

Property
Type
Contract
Description

TotalAmount

required

Total price for specified interval.

AverageAmountPerTimeUnit

required

Price for one timeUnit. (Day/Night)

Max price

Property
Type
Contract
Description

TotalAmount

required

Total price for specified interval.

AverageAmountPerTimeUnit

required

Price for one timeUnit. (Day/Night)

Rate

Property
Type
Contract
Description

Id

string

required

Unique identifier of the rate.

Name

required

Name of the rate localized into all supported languages.

Description

required

Description of the rate localized into all supported languages.

IsPrivate

boolean

required

Set to true for promotion rate enabled by provided VoucherCode.

ServiceId

string

required

RateGroupId

string

required

Ordering

number

required

Number defining the ordering of the rate.

Amount

Property
Type
Contract
Description

Currency

string

required

ISO 4217 code of the currency.

GrossValue

number

required

Gross value of the amount. (Net + sum of TaxValues)

NetValue

number

required

Net value of the amount.

Breakdown.Items

required

List of taxes related to this amount.

Rate

Property
Type
Contract
Description

Currency

string

required

Amount currency.

GrossValue

number

required

Gross value of the amount. (Net + sum of Breakdown > Items)

NetValue

number

required

Net value of the amount.

Breakdown.Items

required

List of taxes related to this amount.

Complete tax

Property
Type
Contract
Description

TaxRateCode

string

Unique identifier of the tax rate.

NetValue

number

required

Net value taxValue is calculated from.

TaxValue

number

required

Tax value calculated from NetValue based on Tax configuration.

Response diagram

PreviousReservation groupsNextVouchers

Last updated 2 months ago

Was this helpful?

Identification of the client as described in .

Unique identifier of the for which availability should be returned.

Code of the language.

array of

Identification of the client as described in .

Unique identifier of the for which availability should be returned.

Code of the language.

Currency code which should be used for prices in the response.

array of

array of

array of

array of objects with arrays of

array of

objects

objects

objects

objects

objects

objects

Unique identifier of the to which the rate is bound.

Identifier of the rate.

array of

array of

Authentication
Supported language codes
Authentication
Supported language codes
Supported currency codes
Category Availability
Category price
Occupancy
Rate group price
Min price
Max price
Amount
Amount
Amount
Amount
Complete tax
Complete tax
Rate group
Rate
Localized text
Localized text
Rate group
Get services pricing response
Service
Service
Service