swagger: "2.0"

info:
  title: Rapid
  description: EPS Rapid V2.3
  version: "2.3"

host: api.ean.com
basePath: /2.3
schemes:
  - https

produces:
  - application/json

tags:
  - name: Recommendations
    description: "Get recommended properties"

paths:
  /properties/availability:
    get:
      summary: "Cross-Sell Recommendations"
      description: |
        Calculates recommended properties based on the provided flight itinerary. Returns a sorted list of available properties; the first property in the response is the “strongest recommendation”. For each property, rate and availability information is returned.
      tags:
        - Recommendations
      parameters:
        - $ref: "#/parameters/accept"
        - $ref: "#/parameters/acceptEncoding"
        - $ref: "#/parameters/authorization"
        - $ref: "#/parameters/customerIpOptional"
        - $ref: "#/parameters/customerSessionId"
        - $ref: "#/parameters/user_agent"
        - $ref: "#/parameters/checkin"
        - $ref: "#/parameters/checkout"
        - $ref: "#/parameters/destination_iata_airport_code"
        - $ref: "#/parameters/origin_iata_airport_code"
        - $ref: "#/parameters/cabin_class"
        - $ref: "#/parameters/flight_designator"
        - $ref: "#/parameters/arrival"
        - $ref: "#/parameters/transportation_gross_cost"
        - $ref: "#/parameters/currency"
        - $ref: "#/parameters/language"
        - $ref: "#/parameters/country_code"
        - $ref: "#/parameters/occupancy"
        - $ref: "#/parameters/sales_channel"
        - $ref: "#/parameters/sales_environment"
        - $ref: "#/parameters/sort_type"
        - $ref: "#/parameters/filter"
        - $ref: "#/parameters/ratePlanCount"
        - $ref: "#/parameters/rate_option"
        - $ref: "#/parameters/billing_terms"
        - $ref: "#/parameters/payment_terms"
        - $ref: "#/parameters/partner_point_of_sale"
        - $ref: "#/parameters/platform_name"
      responses:
        200:
          $ref: "#/responses/Recommendations"
        400:
          $ref: "#/responses/BadRequestInvalidInput400Error"
        401:
          $ref: "#/responses/Error401"
        403:
          $ref: "#/responses/Error403"
        404:
          $ref: "#/responses/PropertyAvailability404Error"
        426:
          $ref: "#/responses/Error426"
        429:
          $ref: "#/responses/Error429"
        500:
          $ref: "#/responses/Error500"
        503:
          $ref: "#/responses/Error503"

  /properties/{property_id}/recommendations:
    get:
      description: |
        Calculates recommended alternative properties based on the reference property id. Returns a sorted list of recommended properties; the first property in the response is the "strongest recommendation". For each property, rates on available room types for properties is returned similar to the "Get property room rates and availability" call in the existing Rapid Shop API.
      summary: "Get alternative properties"
      tags:
        - Recommendations
      parameters:
        - $ref: "#/parameters/accept"
        - $ref: "#/parameters/acceptEncoding"
        - $ref: "#/parameters/authorization"
        - $ref: "#/parameters/customerIpOptional"
        - $ref: "#/parameters/customerSessionId"
        - $ref: "#/parameters/user_agent"
        - $ref: "#/parameters/reference_property_id"
        - $ref: "#/parameters/recommendation_type"
        - $ref: "#/parameters/checkin"
        - $ref: "#/parameters/checkout"
        - $ref: "#/parameters/currency"
        - $ref: "#/parameters/language"
        - $ref: "#/parameters/country_code"
        - $ref: "#/parameters/occupancy"
        - $ref: "#/parameters/sales_channel"
        - $ref: "#/parameters/sales_environment"
        - $ref: "#/parameters/filter"
        - $ref: "#/parameters/rate_option"
        - $ref: "#/parameters/billing_terms"
        - $ref: "#/parameters/payment_terms"
        - $ref: "#/parameters/partner_point_of_sale"
        - $ref: "#/parameters/platform_name"
      responses:
        200:
          $ref: "#/responses/Recommendations"
        400:
          $ref: "#/responses/Recommendations400Error"
        401:
          $ref: "#/responses/Error401"
        403:
          $ref: "#/responses/Error403"
        404:
          $ref: "#/responses/Recommendations404Error"
        426:
          $ref: "#/responses/Error426"
        429:
          $ref: "#/responses/Error429"
        500:
          $ref: "#/responses/Error500"
        503:
          $ref: "#/responses/Error503"

parameters:
  accept:
    in: header
    name: Accept
    description: Must be `application/json`
    required: true
    type: string
  acceptEncoding:
    in: header
    name: Accept-Encoding
    description: Must be `gzip`
    required: true
    type: string
  authorization:
    in: header
    name: Authorization
    description: "The custom generated authentication header. Refer to our [signature authentication](https://developer.expediapartnersolutions.com/reference/signature-authentication) page for full details."
    required: true
    type: string
  customerIpOptional:
    in: header
    name: Customer-Ip
    description: |
      IP address of the customer, as captured by your integration. Send IPV4 addresses only.<br>
      Ensure your integration passes the customer's IP, not your own. This value helps determine their location and assign the correct payment gateway.<br>
      Also used for fraud recovery and other important analytics.
    required: false
    type: string
  customerSessionId:
    in: header
    name: Customer-Session-Id
    description: |
      Insert your own unique value for each user session, beginning with the first API call.
      Continue to pass the same value for each subsequent API call during the user's session, using a new value for every new customer session.<br>
      Including this value greatly eases EPS's internal debugging process for issues with partner requests, as it explicitly links together request paths for individual user's session.
    required: false
    type: string
  destination_iata_airport_code:
    in: query
    name: destination_iata_airport_code
    description: |
      3-character IATA airport code of the destination airport. The code must be upper case.

      Example: `SEA`.
    required: true
    type: string
  origin_iata_airport_code:
    in: query
    name: origin_iata_airport_code
    description: |
      3-character IATA airport code of the origin airport. The code must be upper case.

      Example: `LHR`.
    required: false
    type: string
  flight_designator:
    in: query
    name: flight_designator
    description: |
      Flight designator, or flight number, of booked flight.

      Example: `BA49`.
    required: false
    type: string
  arrival:
    in: query
    name: arrival
    description: |
      Arrival date and time, in extended ISO 8601 format.

      Example: `2018-02-17T01:15:00.000Z`.
    required: false
    type: string
  transportation_gross_cost:
    in: query
    name: transportation_gross_cost
    description: |
      The currency and gross cost of the flight booking, for all travelers and before any deductibles. This should be formatted by first specifying the currency in ISO 4217 format, followed by a hyphen, followed by the decimal amount.

      Example: `USD-1063.62`.
    required: false
    type: string
  cabin_class:
    in: query
    name: cabin_class
    description: |
      The cabin class of the ticket. Use the highest cabin class if the journey inclues multiple cabin classes.<br>
      Accepted values:<br>
      * `economy` - Economy cabin class.
      * `premium_economy` - Premium economy cabin class.
      * `business` - Business cabin class.
      * `first` - First cabin class.
    required: false
    type: string
    enum:
      - economy
      - premium_economy
      - business
      - first
  language:
    in: query
    name: language
    description: |
      Desired language for the response as a subset of BCP47 format that only uses hyphenated pairs of two-digit language and country codes. Use only ISO639-1 alpha 2 language codes and ISO3166-1 alpha 2 country codes. See [https://www.w3.org/International/articles/language-tags/](https://www.w3.org/International/articles/language-tags/)

      Example: `language=en-US`

      Language Options: [https://developer.expediapartnersolutions.com/reference/language-options/](https://developer.expediapartnersolutions.com/reference/language-options/)
    required: true
    type: string
  billing_terms:
    in: query
    name: billing_terms
    description: |
      This parameter is to specify the terms of how a resulting booking should be billed. If this field is needed, the value for this will be provided to you separately.
    required: false
    type: string
  payment_terms:
    in: query
    name: payment_terms
    description: |
      This parameter is to specify what terms should be used when being paid for a resulting booking. If this field is needed, the value for this will be provided to you separately.
    required: false
    type: string
  partner_point_of_sale:
    in: query
    name: partner_point_of_sale
    description: |
      This parameter is to specify what point of sale is being used to shop and book. If this field is needed, the value for this will be provided to you separately.
    type: string
  platform_name:
    in: query
    name: platform_name
    description: |
      This parameter is to specify what platform is being used to shop and book. If this field is needed, the value for this will be provided to you separately.
    type: string
  user_agent:
    in: header
    name: User-Agent
    description: |
      The `User-Agent` header string from the customer's request, as captured by your integration. If you are building an application then the `User-Agent` value should be `{app name}/{app version}`.

      Example: `Mozilla/5.0 (Macintosh; Intel Mac OS X 10_11_6) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/63.0.3239.132 Safari/537.36`

      Example: `TravelNow/3.30.112`
    required: true
    type: string
  reference_property_id:
    in: path
    name: property_id
    type: string
    required: true
    description: |
      Reference property to get alternative properties for.
  recommendation_type:
    in: query
    name: recommendation_type
    required: true
    type: string
    enum:
      - relevance
    description: |
      Requested recommendation type. Recommendations provided are based on `relevance` to the given reference property.
  checkin:
    in: query
    name: checkin
    description: |
      Check-in date, in ISO 8601 format (YYYY-MM-DD)
      Example: `2018-02-16`.
    required: true
    type: string
  checkout:
    in: query
    name: checkout
    description: |
      Check-out date, in ISO 8601 format (YYYY-MM-DD). Availability can be searched up to 500 days in advance of this date. Total length of stay cannot exceed 28 nights.

      Example: `2018-02-18`.
    required: true
    type: string
  currency:
    in: query
    name: currency
    description: |
      Requested currency for the rates, in ISO 4217 format<br>
      Example: `USD`.<br>
      Currency Options: [https://developer.expediapartnersolutions.com/reference/currency-options/](https://developer.expediapartnersolutions.com/reference/currency-options/)
    required: true
    type: string
  country_code:
    in: query
    name: country_code
    description: |
      The country code of the traveler's point of sale, in ISO 3166-1 alpha-2 format. This should represent the country where the shopping transaction is taking place.

      Example: country_code=US

      For more information see: [https://www.iso.org/obp/ui/#search/code/](https://www.iso.org/obp/ui/#search/code/)
    required: true
    type: string
  occupancy:
    in: query
    name: occupancy
    description: |
      Defines the requested occupancy for a single room. Each room must have at least 1 adult occupant.<br>
      Format: `numberOfAdults[-firstChildAge[,nextChildAge]]`<br>
      To request multiple rooms (of the same type), include one instance of occupancy for each room requested. Up to 8 rooms may be requested or booked at once.<br>
      Examples:
      * 2 adults, one 9-year-old and one 4-year-old would be represented by `occupancy=2-9,4`.<br>
      * A multi-room request to lodge an additional 2 adults would be represented by `occupancy=2-9,4&occupancy=2`
    required: true
    type: array
    collectionFormat: multi
    items:
      type: string
  sales_channel:
    in: query
    name: sales_channel
    description: |
      You must provide the sales channel for the display of rates. EPS dynamically provides the best content for optimal conversion on each sales channel. If you have a sales channel that is not currently supported in this list, please contact our support team.<br>
      * `website` - Standard website accessed from the customer's computer
      * `agent_tool` - Your own agent tool used by your call center or retail store agent
      * `mobile_app` - An application installed on a phone or tablet device
      * `mobile_web` - A web browser application on a phone or tablet device
      * `meta` - Rates will be passed to and displayed on a 3rd party comparison website
      * `cache` - Rates will be used to populate a local cache
    required: true
    type: string
  sales_environment:
    in: query
    name: sales_environment
    description: |
      You must provide the sales environment in which rates will be sold. EPS dynamically provides the best content for optimal conversion. If you have a sales environment that is not currently supported in this list, please contact our support team.<br>
      * `hotel_package` - Use when selling the hotel with a transport product, e.g. flight & hotel.
      * `hotel_only` - Use when selling the hotel as an individual product.
      * `loyalty` - Use when you are selling the hotel as part of a loyalty program and the price is converted to points.
    required: true
    type: string
  sort_type:
    in: query
    name: sort_type
    description: |
      Order properties should be returned in. If the requested sort type cannot be applied, the response will include a Warning header indicating the results are unsorted.<br>
      * `preferred` - What we are paid impacts our sort order.
    required: true
    default: preferred
    type: string
  filter:
    in: query
    name: filter
    description: |
      Single filter type. Send multiple instances of this parameter to request multiple filters.<br>
      * `refundable` - Filters results to only show fully refundable rates.
      * `expedia_collect` - Filters results to only show rates where payment is collected by Expedia at the time of booking. These properties can be eligible for payments via Expedia Affiliate Collect(EAC).
      * `property_collect` - Filters results to only show rates where payment is collected by the property after booking. This can include rates that require a deposit by the property, dependent upon the deposit policies.

      Example: `filter=refundable&filter=expedia_collect`
    required: false
    type: array
    collectionFormat: multi
    items:
      type: string
      enum:
        - refundable
        - expedia_collect
        - property_collect
  ratePlanCount:
    in: query
    name: rate_plan_count
    type: number
    description: |
      The number of rates to return per property. The rate’s price determines which rates are returned e.g. a rateplancount=4 will return the lowest 4 rates, but the rates are not ordered from lowest to highest or vice versa in the response.  The lowest rate has been proven to provide the best conversion rate and so a value of 1 is recommended.

      The value must be greater than 0.
    required: true
  rate_option:
    in: query
    name: rate_option
    description: |
      Request specific rate options for each property. Send multiple instances of this parameter to request multiple rate options.
      Accepted values:<br>
      * `closed_user_group` - Return closed user group rates for each property. This feature must be enabled and requires a user to be logged in to request these rates.
      * `net_rates` - Return net rates for each property. This feature must be enabled to request these rates.
      * `cross_sell` - Identify if the traffic is coming from a cross sell booking. Where the traveler has booked another service (flight, car, activities...) before hotel.

      Example: `rate_option=closed_user_group&rate_option=net_rates`
    required: false
    type: array
    collectionFormat: multi
    items:
      type: string
      enum:
        - closed_user_group
        - net_rates
        - cross_sell

definitions:
  Error:
    type: object
    description: The overall class of error that occured.
    properties:
      type:
        description: The error type.
        type: string
      message:
        description: A human readable message giving details about this error.
        type: string
      fields:
        type: array
        description: Details about the specific fields that had an error.
        items:
          type: object
          description: An individual field that had an error.
          properties:
            name:
              type: string
              description: The field that had an error.
            type:
              type: string
              description: The type of the field that had an error.
            value:
              type: string
              description: The value of the field that had an error.
      errors:
        type: array
        description: An array of all the actual errors that occured.
        items:
          type: object
          description: An individual error.
          properties:
            type:
              type: string
              description: The error type.
            message:
              type: string
              description: A human readable message giving details about this error.
            fields:
              type: array
              description: Details about the specific fields that had an error.
              items:
                type: object
                description: An individual field that had an error.
                properties:
                  name:
                    type: string
                    description: The field that had an error.
                  type:
                    type: string
                    description: The type of the field that had an error.
                  value:
                    type: string
                    description: The value of the field that had an error.

  PropertyAvailabilityWithoutScore:
    type: object
    description: The rooms and rates for a property.
    properties:
      property_id:
        description: Expedia property ID.
        type: string
      rooms:
        description: Array of objects containing room information.
        type: array
        items:
          type: object
          description: The room information.
          properties:
            id:
              description: Unique Identifier for a room type.
              type: string
            room_name:
              description: Name of the room type.
              type: string
            rates:
              description: Array of objects containing rate information.
              type: array
              items:
                type: object
                properties:
                  id:
                    description: Unique Identifier for a rate.
                    type: string
                  available_rooms:
                    description: >-
                      The number of bookable rooms remaining with this rate in EPS inventory. Use this value to create rules for urgency messaging to alert users to low availability on busy travel dates or at popular properties.

                      If the value returns as 2147483647 (max int value), the actual value could not be determined. Ensure your urgency messaging ignores such instances when returned.
                    type: number
                  refundable:
                    description: Indicates if the rate is fully refundable at the time of booking. Cancel penalties may still apply. Please refer to the cancel penalties section for reference.
                    type: boolean
                  fenced_deal:
                    description: >-
                      Indicates that a "Member Only Deal" discount has been applied to the rate.

                      Partners must be enabled to receive "Member Only Deals" to benefit from this parameter. If interested, partners should speak to their account representatives.

                      This parameter can be used to merchandise if a "Member Only Deal" has been applied which will help partners to drive loyalty. In addition, it can be used by OTA's to create an opaque but public shopping experience. These deals are expected to be messaged with the specific traveler program naming.
                    type: boolean
                  fenced_deal_available:
                    description: >-
                      Indicates if a "Member Only Deal" is available for this rate.
                    type: boolean
                  deposit_required:
                    description: If a deposit is required for the rate, this value will be `true`. A "deposit_policies" link will be included in this response to retrieve more information about the deposit, including amounts and timing.
                    type: boolean
                  merchant_of_record:
                    description: |
                      * `expedia` - Payment is taken by Expedia. The payment options avaliable can be discovered using the "payment-options" link in the response. This includes AFFILIATE_COLLECT payments.
                      * `property` - Payment is taken by the property.
                    type: string
                    enum:
                      - expedia
                      - property
                  amenities:
                    description: Room amenities.
                    type: object
                    additionalProperties:
                      $ref: "#/definitions/Amenity"
                  links:
                    type: object
                    description: A map of links, including links to request payment options and deposit policies.
                    properties:
                      payment_options:
                        $ref: "#/definitions/Link"
                      deposit_policies:
                        $ref: "#/definitions/Link"
                    additionalProperties:
                      $ref: "#/definitions/Link"
                  bed_groups:
                    type: object
                    description: A map of the room's bed groups.
                    additionalProperties:
                      $ref: "#/definitions/BedGroupAvailability"
                  cancel_penalties:
                    description: Array of `cancel_penalty` objects containing cancel penalty information. Will not be populated on non refundable.
                    type: array
                    items:
                      type: object
                      properties:
                        currency:
                          description: Currency of the amount object.
                          type: string
                        start:
                          description: Effective date and time of cancellation penalty in extended ISO 8601 format, with ±hh:mm timezone offset
                          type: string
                        end:
                          description: End date and time of cancellation penalty in extended ISO 8601 format, with ±hh:mm timezone offset
                          type: string
                        amount:
                          description: The monetary amount of the penalty.
                          type: string
                        nights:
                          description: Number of nights charged for as penalty.
                          type: string
                        percent:
                          description: Percentage of total booking charged for as penalty. A thirty percent penalty would be returned as 30%
                          type: string
                      required:
                        - currency
                  occupancy_pricing:
                    type: object
                    description: A map of room information by occupancy.
                    additionalProperties:
                      $ref: '#/definitions/RoomRate'
                  promotions:
                    description: Available promotions that apply to this rate.
                    type: object
                    properties:
                      value_adds:
                        description: A collection of value adds that apply to this rate.
                        type: object
                        additionalProperties:
                          $ref: "#/definitions/ValueAdd"
                      deal:
                        description: The deal that applies to this rate.
                        type: object
                        properties:
                          id:
                            description: Unique identifier for the deal.
                            type: string
                          description:
                            description: The description for the deal.
                            type: string
                required:
                  - id
                  - available_rooms
                  - refundable
                  - fenced_deal
                  - fenced_deal_available
                  - deposit_required
                  - merchant_of_record
                  - links
                  - occupancy_pricing
          required:
            - id
            - rates
      links:
        type: object
        description: A map of links, including links to request additional rates and recommendations.
        properties:
          additional_rates:
            $ref: "#/definitions/Link"
          recommendations:
            $ref: "#/definitions/Link"
        additionalProperties:
          $ref: "#/definitions/Link"
    required:
      - property_id
      - rooms

  RoomRate:
    type: object
    description: A map of room information by occupancy.
    properties:
      nightly:
        description: Array of arrays of amount objects. Each sub-array of amount objects represents a single night's charges
        type: array
        items:
          type: array
          items:
            type: object
            properties:
              type:
                description: |
                  The price breakout type.
                    * `base_rate` - The room rate without any taxes and fees applied.
                    * `tax_and_service_fee` - Tax recovery charges, service fees, and taxes. Ensure that you capture these values and display as:
                                              For Europe: "Tax Recovery Charges"
                                              All other regions: "Tax Recovery Charges and Service Fees"
                    * `extra_person_fee` - A per night fee that is charged by a hotel for additional adults over the nightly rate. This fee is included as part of the total.
                    * `compensation`
                    * `property_fee` - The property fee surcharge type must be displayed beginning on the initial hotel room selection page, immediately after your hotel search results page. This placement is required by the U.S. Federal Trade Commission (FTC).
                                       Display this surcharge as "Property Fee" on your room selection page, as described above, and in all subsequent price breakdowns for the following Points of Sale:
                                       * `US`
                                       * `Canada`
                                       * `Brazil`
                                       * `LATAM`
                    * `sales_tax` - Taxes that must be displayed by certain jurisdictional laws. Ensure that you capture these values and display as "Taxes".
                    * `adjustment` - This is the amount that the individual night have been adjusted/discounted.
                    * `recovery_charges_and_fees` - Tax recovery charges, service fees, and taxes. Ensure that you capture these values and display as:
                                                    For Europe: "Tax Recovery Charges"
                                                    All other regions: "Tax Recovery Charges and Service Fees"
                type: string
                enum:
                  - base_rate
                  - tax_and_service_fee
                  - extra_person_fee
                  - compensation
                  - property_fee
                  - sales_tax
                  - adjustment
                  - recovery_charges_and_fees
              value:
                description: The value of the amount object. Decimal point inline with correct precision.
                type: string
              currency:
                description: Currency of the amount object.
                type: string
            required:
              - type
              - value
              - currency
      stay:
        description: Array of amount objects. Details any charges that apply to the entire stay (not divided per-night). Any per-room adjustments are applied to the `base_rate` amount within this object.
        type: array
        items:
          type: object
          properties:
            type:
              description: The price breakout type.
              type: string
              enum:
                - base_rate
                - tax_and_service_fee
                - extra_person_fee
                - compensation
                - property_fee
                - sales_tax
                - adjustment
                - recovery_charges_and_fees
            value:
              description: The value of the amount object. Decimal point inline with correct precision.
              type: string
            currency:
              description: Currency of the amount object.
              type: string
          required:
            - type
            - value
            - currency
      totals:
        type: object
        properties:
          inclusive:
            description: |
              Provides the total price including taxes and fees.  This does not include hotel collected fees such as resort, mandatory taxes, and mandatory fees.
            type: object
            properties:
              billable_currency:
                type: object
                description: The amount in the billable currency.
                properties:
                  value:
                    description: The value of the amount object. Decimal point inline with correct precision.
                    type: string
                  currency:
                    description: Currency of the amount object.
                    type: string
                required:
                  - value
                  - currency
              request_currency:
                type: object
                description: The amount in the requested currency.
                properties:
                  value:
                    description: The value of the amount object. Decimal point inline with correct precision.
                    type: string
                  currency:
                    description: Currency of the amount object.
                    type: string
                required:
                  - value
                  - currency
          exclusive:
            type: object
            description: Provides the total price excluding taxes and fees.
            properties:
              billable_currency:
                type: object
                description: The amount in the billable currency.
                properties:
                  value:
                    description: The value of the amount object. Decimal point inline with correct precision.
                    type: string
                  currency:
                    description: Currency of the amount object.
                    type: string
                required:
                  - value
                  - currency
              request_currency:
                type: object
                description: The amount in the requested currency.
                properties:
                  value:
                    description: The value of the amount object. Decimal point inline with correct precision.
                    type: string
                  currency:
                    description: Currency of the amount object.
                    type: string
                required:
                  - value
                  - currency
          strikethrough:
            type: object
            description: Provides the tax exclusive total price with any hotel funded discounts added back. Can be used to merchandise the savings due to a discount.
            properties:
              billable_currency:
                description: The amount in the billable currency.
                type: object
                properties:
                  value:
                    description: The value of the amount object. Decimal point inline with correct precision.
                    type: string
                  currency:
                    description: Currency of the amount object.
                    type: string
                required:
                  - value
                  - currency
              request_currency:
                description: The amount in the requested currency.
                type: object
                properties:
                  value:
                    description: The value of the amount object. Decimal point inline with correct precision.
                    type: string
                  currency:
                    description: Currency of the amount object.
                    type: string
                required:
                  - value
                  - currency
          marketing_fee:
            type: object
            description: Provides the potential owed earnings per transaction.
            properties:
              billable_currency:
                description: The amount in the billable currency.
                type: object
                properties:
                  value:
                    description: The value of the amount object. Decimal point inline with correct precision.
                    type: string
                  currency:
                    description: Currency of the amount object.
                    type: string
                required:
                  - value
                  - currency
              request_currency:
                description: The amount in the requested currency.
                type: object
                properties:
                  value:
                    description: The value of the amount object. Decimal point inline with correct precision.
                    type: string
                  currency:
                    description: Currency of the amount object.
                    type: string
                required:
                  - value
                  - currency
          gross_profit:
            type: object
            description: Provides the estimated gross profit per transaction.
            properties:
              billable_currency:
                description: The amount in the billable currency.
                type: object
                properties:
                  value:
                    description: The value of the amount object. Decimal point inline with correct precision.
                    type: string
                  currency:
                    description: Currency of the amount object.
                    type: string
                required:
                  - value
                  - currency
              request_currency:
                description: The amount in the requested currency.
                type: object
                properties:
                  value:
                    description: The value of the amount object. Decimal point inline with correct precision.
                    type: string
                  currency:
                    description: Currency of the amount object.
                    type: string
                required:
                  - value
                  - currency
          minimum_selling_price:
            type: object
            description: Provides the minimum selling price.
            properties:
              billable_currency:
                description: The amount in the billable currency.
                type: object
                properties:
                  value:
                    description: The value of the amount object. Decimal point inline with correct precision.
                    type: string
                  currency:
                    description: Currency of the amount object.
                    type: string
                required:
                  - value
                  - currency
              request_currency:
                description: The amount in the requested currency.
                type: object
                properties:
                  value:
                    description: The value of the amount object. Decimal point inline with correct precision.
                    type: string
                  currency:
                    description: Currency of the amount object.
                    type: string
                required:
                  - value
                  - currency
        required:
          - inclusive
          - exclusive
      fees:
        type: object
        properties:
          mandatory_fee:
            description: A mandated fee collected by the property at check-in or check-out.
            type: object
            properties:
              billable_currency:
                type: object
                description: The amount in the billable currency.
                properties:
                  value:
                    description: The value of the amount object. Decimal point inline with correct precision.
                    type: string
                  currency:
                    description: Currency of the amount object.
                    type: string
                required:
                  - value
                  - currency
              request_currency:
                type: object
                description: The amount in the requested currency.
                properties:
                  value:
                    description: The value of the amount object. Decimal point inline with correct precision.
                    type: string
                  currency:
                    description: Currency of the amount object.
                    type: string
                required:
                  - value
                  - currency
              scope:
                description: "The scope of the fee."
                type: string
                enum:
                  - unknown
                  - per_person
                  - per_room
                  - per_accommodation
                  - per_house
                  - per_apartment
                  - per_adult
              frequency:
                description: "The frequency of the fee."
                type: string
                enum:
                  - unknown
                  - per_night
                  - per_day
                  - per_stay
                  - per_week
                  - round_trip
                  - one_way
          resort_fee:
            type: object
            description: A fee charged for amenities and extras and collected by the property at check-in or check-out.
            properties:
              billable_currency:
                type: object
                description: The amount in the billable currency.
                properties:
                  value:
                    description: The value of the amount object. Decimal point inline with correct precision.
                    type: string
                  currency:
                    description: Currency of the amount object.
                    type: string
                required:
                  - value
                  - currency
              request_currency:
                type: object
                description: The amount in the requested currency.
                properties:
                  value:
                    description: The value of the amount object. Decimal point inline with correct precision.
                    type: string
                  currency:
                    description: Currency of the amount object.
                    type: string
                required:
                  - value
                  - currency
              scope:
                description: "The scope of the fee."
                type: string
                enum:
                  - unknown
                  - per_person
                  - per_room
                  - per_accommodation
                  - per_house
                  - per_apartment
                  - per_adult
              frequency:
                description: "The frequency of the fee."
                type: string
                enum:
                  - unknown
                  - per_night
                  - per_day
                  - per_stay
                  - per_week
                  - round_trip
                  - one_way
          mandatory_tax:
            type: object
            description: A mandated tax collected by the property at check-in or check-out.
            properties:
              billable_currency:
                description: The amount in the billable currency.
                type: object
                properties:
                  value:
                    description: The value of the amount object. Decimal point inline with correct precision.
                    type: string
                  currency:
                    description: Currency of the amount object.
                    type: string
                required:
                  - value
                  - currency
              request_currency:
                description: The amount in the requested currency.
                type: object
                properties:
                  value:
                    description: The value of the amount object. Decimal point inline with correct precision.
                    type: string
                  currency:
                    description: Currency of the amount object.
                    type: string
                required:
                  - value
                  - currency
              scope:
                description: "The scope of the fee."
                type: string
                enum:
                  - unknown
                  - per_person
                  - per_room
                  - per_accommodation
                  - per_house
                  - per_apartment
                  - per_adult
              frequency:
                description: "The frequency of the fee."
                type: string
                enum:
                  - unknown
                  - per_night
                  - per_day
                  - per_stay
                  - per_week
                  - round_trip
                  - one_way
    required:
      - nightly
      - stay
      - totals

  Amenity:
    type: object
    description: An individual amenity.
    properties:
      id:
        type: number
        description: Numeric identifier for the amenity.
      name:
        type: string
        description: Amenity name.
      value:
        type: string
        description: Amenity value.

  BedGroupAvailability:
    type: object
    properties:
      links:
        type: object
        description: A map of links, including links to confirm pricing and availability for the selected rate.
        properties:
          price_check:
            $ref: "#/definitions/Link"
        additionalProperties:
          $ref: "#/definitions/Link"
      id:
        type: string
        description: Unique identifier for a bed group.
      description:
        type: string
        description: This is a display ready description of a bed configuration for this room.
      configuration:
        type: array
        description: 'The bed configuration for a given room. This array can be empty for the related bed group.'
        items:
          type: object
          properties:
            type:
              description: The type of bed.
              type: string
            size:
              description: The size of the bed.
              type: string
            quantity:
              description: The number of bed(s).
              type: number

  Link:
    type: object
    description: An individual link.
    properties:
      method:
        type: string
        description: The request method used to access the link.
      href:
        type: string
        description: The URL for the link. This can be absolute or relative.
      expires:
        type: string
        description: If the link expires, this will be the UTC date the link will expire, in ISO 8601 format.

  ValueAdd:
    type: object
    description: An individual value add.
    properties:
      id:
        type: string
        description: Unique identifier for the value add promotion.
      description:
        type: string
        description: A localized description of the value add promotion.
    required:
      - id
      - description

responses:
  Error401:
    description: Unauthorized
    headers:
      WWW-Authenticate:
        type: string
        description: Provides an example of the Authorization header.
    schema:
      $ref: "#/definitions/Error"
    examples:
      Example:
        type: request_unauthenticated
        message: Data required to authenticate your request is missing or inaccurate. Ensure that your request follows the guidelines in our documentation.
        fields:
          - name: apikey
            type: header
            value: jaj3982k239dka328e
          - name: signature
            type: header
            value: 129d75332614a5bdbe0c7eb540e95a65f9d85a5b53dabb38d19b37fad6312a2bd25c12ee5a82831d55112087e1b
          - name: timestamp
            type: header
            value: 198284729
          - name: servertimestamp
            type: server
            value: 198284729

  Error403:
    description: Forbidden
    schema:
      $ref: "#/definitions/Error"
    examples:
      Example:
        type: request_unauthorized
        message: Your request could not be authorized.

  Error426:
    description: Upgrade Required
    schema:
      $ref: "#/definitions/Error"
    examples:
      Example:
        type: upgrade_required
        message: This service requires the use of TLS.

  Error429:
    description: Too Many Requests
    headers:
      Rate-Limit-Day:
        type: number
        description: Reserved for future use. Optional header for request capacity per day.
      Rate-Limit-Day-Remaining:
        type: number
        description: Optional header for the remaining capacity, as a percentage, for the daily time window.
      Rate-Limit-Day-Reset:
        type: number
        description: Optional header for the timestamp, as the number of milliseconds since the Unix Epoch, when the daily capacity resets.
      Rate-Limit-Minute:
        type: number
        description: Reserved for future use. Optional header for request capacity per minute.
      Rate-Limit-Minute-Remaining:
        type: number
        description: Optional header for the remaining capacity, as a percentage, for the per minute time window.
      Rate-Limit-Minute-Reset:
        type: number
        description: Optional header for the timestamp, as the number of milliseconds since the Unix Epoch, when the per minute capacity resets.
      Rate-Limit-Reduction-Status:
        type: string
        description: Optional header that indicates the state (inactive, active) of minute capacity reduction triggered once all daily capacity has been used.
    schema:
      $ref: "#/definitions/Error"
    examples:
      Example:
        type: too_many_requests
        message: You have reached your capacity for this type of request.

  Error500:
    description: Unknown Internal Error
    schema:
      $ref: "#/definitions/Error"
    examples:
      Example:
        type: unknown_internal_error
        message: An internal server error has occurred.

  Error503:
    description: Service Unavailable
    schema:
      $ref: "#/definitions/Error"
    examples:
      Example:
        type: service_unavailable
        message: This service is currently unavailable.

  BadRequestInvalidInput400Error:
    description: Bad Request
    headers:
      Rate-Limit-Day:
        type: number
        description: Reserved for future use. Optional header for request capacity per day.
      Rate-Limit-Day-Remaining:
        type: number
        description: Optional header for the remaining capacity, as a percentage, for the daily time window.
      Rate-Limit-Day-Reset:
        type: number
        description: Optional header for the timestamp, as the number of milliseconds since the Unix Epoch, when the daily capacity resets.
      Rate-Limit-Minute:
        type: number
        description: Reserved for future use. Optional header for request capacity per minute.
      Rate-Limit-Minute-Remaining:
        type: number
        description: Optional header for the remaining capacity, as a percentage, for the per minute time window.
      Rate-Limit-Minute-Reset:
        type: number
        description: Optional header for the timestamp, as the number of milliseconds since the Unix Epoch, when the per minute capacity resets.
      Rate-Limit-Reduction-Status:
        type: string
        description: Optional header that indicates the state (inactive, active) of minute capacity reduction triggered once all daily capacity has been used.
    schema:
      $ref: "#/definitions/Error"
    examples:
      Example:
        type: invalid_input
        message: An invalid request was sent in, please check the nested errors for details.
        errors:
          - type: checkin.invalid_date_format
            message: 'Invalid checkin format. It must be formatted in ISO 8601 (YYYY-mm-dd) http://www.iso.org/iso/catalogue_detail?csnumber=40874.'
            fields:
              - name: checkin
                type: querystring
                value: 2019-01-1

  Recommendations400Error:
    description: Invalid Input
    schema:
      $ref: "#/definitions/Error"
    examples:
      Recommendation type not provided:
        type: invalid_input
        message: An invalid request was sent in, please check the nested errors for details.
        errors:
          - type: recommendation_type.required
            message: 'Recommendation Type is required. Accepted recommendation_type are: [relevance].'
            fields:
              - name: recommendation_type
                type: querystring
      Recommendation type not supported:
        type: invalid_input
        message: An invalid request was sent in, please check the nested errors for details.
        errors:
          - type: recommendation_type.invalid
            message: 'Recommendation Type is invalid. Accepted recommendation_type are: [relevance].'
            fields:
              - name: recommendation_type
                type: querystring,
                value: "XX"
      Multiple Errors:
        type: invalid_input
        message: An invalid request was sent in, please check the nested errors for details.
        errors:
          - type: language.invalid_language_format
            message: 'Language is invalid. It must be formatted in ISO639-1 alpha 2 language codes and ISO3166-1 alpha 2 country codes format. See https://www.w3.org/International/articles/language-tags/.'
            fields:
              - name: language
                type: querystring
                value: xx_XX
          - type: recommendation_type.invalid
            message: 'Recommendation Type is invalid. Accepted recommendation_type values are: [relevance].'
            fields:
              - name: recommendation_type
                type: querystring
                value: "XX"
    headers:
      Rate-Limit-Day:
        type: number
        description: Reserved for future use. Optional header for request capacity per day.
      Rate-Limit-Day-Remaining:
        type: number
        description: Optional header for the remaining capacity, as a percentage, for the daily time window.
      Rate-Limit-Day-Reset:
        type: number
        description: Optional header for the timestamp, as the number of milliseconds since the Unix Epoch, when the daily capacity resets.
      Rate-Limit-Minute:
        type: number
        description: Reserved for future use. Optional header for request capacity per minute.
      Rate-Limit-Minute-Remaining:
        type: number
        description: Optional header for the remaining capacity, as a percentage, for the per minute time window.
      Rate-Limit-Minute-Reset:
        type: number
        description: Optional header for the timestamp, as the number of milliseconds since the Unix Epoch, when the per minute capacity resets.
      Rate-Limit-Reduction-Status:
        type: string
        description: Optional header that indicates the state (inactive, active) of minute capacity reduction triggered once all daily capacity has been used.

  PropertyAvailability404Error:
    description: No availability found.
    headers:
      Rate-Limit-Day:
        type: number
        description: Reserved for future use. Optional header for request capacity per day.
      Rate-Limit-Day-Remaining:
        type: number
        description: Optional header for the remaining capacity, as a percentage, for the daily time window.
      Rate-Limit-Day-Reset:
        type: number
        description: Optional header for the timestamp, as the number of milliseconds since the Unix Epoch, when the daily capacity resets.
      Rate-Limit-Minute:
        type: number
        description: Reserved for future use. Optional header for request capacity per minute.
      Rate-Limit-Minute-Remaining:
        type: number
        description: Optional header for the remaining capacity, as a percentage, for the per minute time window.
      Rate-Limit-Minute-Reset:
        type: number
        description: Optional header for the timestamp, as the number of milliseconds since the Unix Epoch, when the per minute capacity resets.
      Rate-Limit-Reduction-Status:
        type: string
        description: Optional header that indicates the state (inactive, active) of minute capacity reduction triggered once all daily capacity has been used.
    schema:
      $ref: "#/definitions/Error"
    examples:
      Error:
        type: availability.not_found
        message: No availability was found for the properties requested.

  Recommendations404Error:
    description: Not found
    schema:
      $ref: "#/definitions/Error"
    examples:
      Recommendations not found:
        type: recommendations.not_found
        message: No recommendations found.
    headers:
      Rate-Limit-Day:
        type: number
        description: Reserved for future use. Optional header for request capacity per day.
      Rate-Limit-Day-Remaining:
        type: number
        description: Optional header for the remaining capacity, as a percentage, for the daily time window.
      Rate-Limit-Day-Reset:
        type: number
        description: Optional header for the timestamp, as the number of milliseconds since the Unix Epoch, when the daily capacity resets.
      Rate-Limit-Minute:
        type: number
        description: Reserved for future use. Optional header for request capacity per minute.
      Rate-Limit-Minute-Remaining:
        type: number
        description: Optional header for the remaining capacity, as a percentage, for the per minute time window.
      Rate-Limit-Minute-Reset:
        type: number
        description: Optional header for the timestamp, as the number of milliseconds since the Unix Epoch, when the per minute capacity resets.
      Rate-Limit-Reduction-Status:
        type: string
        description: Optional header that indicates the state (inactive, active) of minute capacity reduction triggered once all daily capacity has been used.

  Recommendations:
    description: OK
    headers:
      Rate-Limit-Day:
        type: number
        description: Reserved for future use. Optional header for request capacity per day.
      Rate-Limit-Day-Remaining:
        type: number
        description: Optional header for the remaining capacity, as a percentage, for the daily time window.
      Rate-Limit-Day-Reset:
        type: number
        description: Optional header for the timestamp, as the number of milliseconds since the Unix Epoch, when the daily capacity resets.
      Rate-Limit-Minute:
        type: number
        description: Reserved for future use. Optional header for request capacity per minute.
      Rate-Limit-Minute-Remaining:
        type: number
        description: Optional header for the remaining capacity, as a percentage, for the per minute time window.
      Rate-Limit-Minute-Reset:
        type: number
        description: Optional header for the timestamp, as the number of milliseconds since the Unix Epoch, when the per minute capacity resets.
      Rate-Limit-Reduction-Status:
        type: string
        description: Optional header that indicates the state (inactive, active) of minute capacity reduction triggered once all daily capacity has been used.
    schema:
      type: array
      items:
        $ref: "#/definitions/PropertyAvailabilityWithoutScore"
    examples:
      Example:
        - property_id: "19248"
          rooms:
            - id: 123abc
              room_name: Fancy Queen Room
              rates:
                - id: 333abc
                  available_rooms: 12
                  refundable: true
                  fenced_deal: true
                  fenced_deal_available: true
                  deposit_required: true
                  merchant_of_record: expedia
                  amenities:
                    1234:
                      id: "1234"
                      name: Free Wireless Internet
                  links:
                    payment_options:
                      method: GET
                      href: /2.3/properties/19248/payment-options?token=MY5S3j36cOcL
                    deposit_policies:
                      method: GET
                      href: /2.3/properties/19248/deposit-policies?token=MY5S3j36cOcL
                  bed_groups:
                    12345:
                      links:
                        price_check:
                          method: GET
                          href: /2.3/properties/19248/rooms/abc123/rates/abc123/price-check?token=MY5S3j36cOcL
                      id: '12345'
                      description: 1 Queen Bed
                      configuration:
                        - type: Bed
                          size: Queen
                          quantity: 1
                  cancel_penalties:
                    - currency: USD
                      start: "2018-02-12T11:59:00.000-08:00"
                      end: "2018-02-12T11:59:00.000-08:00"
                      amount: "10.00"
                      nights: "1"
                      percent: "30%"
                  occupancy_pricing:
                    2:
                      nightly:
                        - - type: base_rate
                            value: "309.00"
                            currency: CAD
                          - type: tax_and_service_fee
                            value: "37.00"
                            currency: CAD
                      totals:
                        inclusive:
                          billable_currency:
                            value: "346.00"
                            currency: CAD
                          request_currency:
                            value: "261.00"
                            currency: USD
                        exclusive:
                          billable_currency:
                            value: "309.00"
                            currency: CAD
                          request_currency:
                            value: "230.00"
                            currency: USD
                      fees:
                        mandatory_fee:
                          billable_currency:
                            value: "5.00"
                            currency: CAD
                          request_currency:
                            value: "3.00"
                            currency: USD
                          scope: per_person
                          frequency: per_day
                  promotions:
                    value_adds:
                      123abc:
                        id: "123abc"
                        description: "10 USD credit on activities and sports for your stay."
                    deal:
                      id: "999abc"
                      description: "Book early and save 15%"
          links:
            additional_rates:
              method: GET
              href: /2.3/properties/12345/availability?token=MY5S3j36cOcL
            recommendations:
              method: GET
              href: /2.3/properties/6471/recommendations?token=abcdef
