Product management
ReferenceProduct management

policies query

This mutation is offered as part of the product management capability, which is available to pilot partners only. If you are interested in adopting this capability, contact your Technical Account Manager.

Retrieves all booking and cancellation policies set on the property.

Syntax

1query {
2 property(
3 id: String!,
4 idSource: IdSource
5 ) {
6 policies: {
7 bookingPolicy: BookingPolicy
8 cancellationPolicyConfigs: [CancellationPolicyConfig!]
9 }
10 }
11}

Examples

Use the interactive GraphQL explorer in the following sections to run a sample query. A test property ID is passed into the explorer; its test data is returned. The GraphQL explorer will help you get comfortable with the GraphQL:

  • For each query, a test property ID is passed into the explorer; its test data is returned.
  • Click Run Query to execute the query in the explorer on the page. You can modify the query to retrieve the desired fields, and the explorer provides a list of fields when you start typing.
  • Click API Explorer to launch the full explorer in another tab/window, which provides syntax highlighting, schema introspection, real-time error highlighting, and auto-completion, among other things.

Booking policies

Booking policies

API Explorer Alt content

Response

Cancellation policies

Cancellation policies

API Explorer Alt content

Response

Arguments

NameDescription

id

Required.

Expedia ID (EID) or supplier ID (external ID in the partner's system) of the property..

Type: String

idSource

Source system of the ID. EXPEDIA is the default value.

Type: IdSource

Types


Name
Type
AgeCategory
Enum

Age categories of guests allowed in a reservation.

NameDescription
ADULT
CHILD_A
CHILD_B
CHILD_C
CHILD_D
INFANT
BookingPolicy
Object

Details about accepted payment types and the booking type supported by the property manager.

FieldDescription
allowedAgeCategoriesNot nullable.

Age categories of guests allowed in a reservation.

Type: Array of non nullable AgeCategory
cancellationTimeNot nullable.

Time of day when a cancellation must be processed before cancellation charges apply.

Type: LocalTime
cutoffDayNot nullable.

Day when the property makes its inventory available after which same-day bookings can occur.

Type: CutoffDayType
cutoffTimeNot nullable.

Time on the cutoffDay when the property makes its inventory available after which same-day bookings can occur.

Type: LocalTime
BusinessModelRestriction
Enum

Entity that collects payment. If the property-level business model is Flex, this can specify if the individual cancellation policy is merchant only or agency only. Currently, only agency is supported.

NameDescription
AGENCY
MERCHANT
CancellationPenaltyRule
Object

Penalty type and amount.

FieldDescription
applicabilityNot nullable.

The booking value to which the cancellation penalty is applied.

Type: CancellationPenaltyRuleApplicability
flatAmount

Penalty amount for a flat amount penalty. Specify this field when type:FLAT_AMOUNT is set.

Type: Money
numberOfNights

Number of nights for which the penalty is applied. Specify this field when type:NUMBER_OF_NIGHTS is set.

Type: Int
percentage

Percentage of the total booking amount that is charged as a penalty. Represented as a fraction of 1 (for example,: 10% should be represented as 0.1). Specify this field when type:PERCENTAGE is set.

Type: Decimal
typeNot nullable.

How the cancellation penalty is applied.

Type: CancellationPenaltyRuleType
CancellationPenaltyRuleApplicability
Enum

Line item in the rental fee to which the cancellation penalty is applied.

NameDescription
BOOKING_TOTAL
CLEANING_FEE
DEPOSIT
CancellationPenaltyRuleType
Enum

How the cancellation penalty (fee) is applied.

NameDescription
FLAT_AMOUNT
NUMBER_OF_NIGHTS
PERCENTAGE
CancellationPolicy
Object

Default policy types and tiers (cancellation window and penalty rules) for which they are applied.

FieldDescription
tiers

Penalty or penalties applied based on cancellation window.

Type: Array of non nullable CancellationPolicyTier
typeNot nullable.

Type of cancellation policy (enforcement level).

Type: CancellationPolicyType
CancellationPolicyCancellationWindow
Object

Policy period (number of days, hour, or weeks before the check-in date that a cancellation can be done).

FieldDescription
cutoffNot nullable.

Number of days, hours, or weeks before the check-in date to which this policy applies. If cutoff is set to 12000 hours or 500 days, which is the the maximum reservation length, the policy applies to all days leading up to the next cutoff period.

Type: Int
temporalUnitNot nullable.

Time unit of the cutoff.

Type: CancellationWindowTemporalUnit
CancellationPolicyConfig
Object

Cancellation policy defined for the property.

FieldDescription
additionalCancellationFee

Fee charged to the traveler when the reservation is cancelled. This is supported for custom cancellation policies only.

Type: Money
businessModelRestriction

Business model to which this cancellation policy applies.

Type: BusinessModelRestriction
defaultPoliciesNot nullable.

Policy types and tiers (cancellation window and penalty rules) for which they are applied. Default policies are always applied to the selected rate plans unless there are exceptions or seasonal cancellation policies present (overridePolicies) with specific dates.

Type: Array of non nullable CancellationPolicy
idNot nullable.

Policy ID. Be sure to store this ID when creating the policy in case it needs to be modified later.

Type: ID
nameNot nullable.

Policy name.

Type: String
overridePoliciesNot nullable.

Policy overrides (also referred to as "exceptions"), which define cancellation parameters for specific dates (also referred to as "seasonal cancellation policies").

Type: Array of non nullable CancellationPolicyOverride
property

Property details.

Type: Property
CancellationPolicyDateRange
Object

Date range to which exceptions and seasonal cancellation policies (overridePolicies) are applied. Dates are closed and inclusive.

FieldDescription
fromNot nullable.

Beginning date to which the policy is applied.

Type: Date
toNot nullable.

End date to which the policy is applied.

Type: Date
CancellationPolicyOverride
Object

Policy overrides (seasonal cancellation policies), which define policy parameters for specific date ranges.

FieldDescription
cancellationPolicyNot nullable.

Policy types and tiers (cancellation window and penalty rules) for which they are applied.

Type: CancellationPolicy
dateRangesNot nullable.

Data range to which the policy applies.

Type: Array of non nullable CancellationPolicyDateRange
CancellationPolicyTier
Object

Penalty or penalties applied based on cancellation window.

FieldDescription
cancellationWindowNot nullable.

Policy period (number of days, hour, or weeks before the check-in date that a cancellation can be done).

Type: CancellationPolicyCancellationWindow
penaltyRulesNot nullable.

Penalty type and amount that is applied to the total booking amount for the specified policy period.

Type: Array of non nullable CancellationPenaltyRule
CancellationPolicyType
Enum

The enforcement levels for the cancellation policy are as follows. Note that the traveler must cancel the reservation by 11:59 PM (property’s local time) of the cut-off day in order to receive the specified refund amount.

NameDescription
CUSTOM

Terms of the policy are defined by the custom policy.

FIRM

100% refund if reservation is cancelled at least 60 days before the arrival date, 50% refund if reservation is cancelled at least 30 days before the arrival date.

MODERATE

100% refund if reservation is cancelled at least 30 days before the arrival date, 50% refund if reservation is cancelled at least 14 days before the arrival date.

NO_REFUND

No refund.

RELAXED

100% refund if reservation is cancelled at least 14 days before the arrival date, 50% refund if reservation is cancelled at least 7 days before the arrival date.

STRICT

100% refund if reservation is cancelled at least 60 days before the arrival date.

CancellationWindowTemporalUnit
Enum

Time unit used for the cancellation window.

NameDescription
DAY
HOUR
WEEK
CurrencyCode
CurrencyCode

Scalar that represents the three-letter currency code defined by the ISO 4217 standard.

CutoffDayType
Enum

Day when the property makes its inventory available after which same-day bookings can occur.

NameDescription
NEXT_DAY
SAME_DAY
Date
Date

Scalar that represents a date string compliant with the RFC 3339 profile of the ISO 8601 standard.

Decimal
Decimal

A type represending a signed decimal number (supporting up to two decimal places), which is serialized as a string.

ID
ID

The ID scalar type represents a unique identifier, often used to refetch an object or as key for a cache. The ID type appears in a JSON response as a String; however, it is not intended to be human-readable. When expected as an input type, any string (such as "4") or integer (such as 4) input value will be accepted as an ID.

IdSource
Enum

Source of a given ID.

NameDescription
EXPEDIA

Expedia is the source of the ID.

SUPPLIER

Connectivity provider or lodging partner is the source of the ID. This value is not supported for use in promotions.

VRBO

Unsupported.

Int
Int

The Int scalar type represents non-fractional signed whole numeric values. Int can represent values between -(2^31) and 2^31 - 1.

LocalTime
LocalTime

Scalar representing a time in this format: HH:mm:ss or HH:mm (such as 10:15:30 or 10:15).

Money
Object

Monetary amount value and its currency code.

FieldDescription
amountNot nullable.

Monetary amount value. The scale of the amount varies according to the currency or any rate conversion that may have been applied.

Type: Decimal
currencyCodeNot nullable.

Currency code.

Type: CurrencyCode
Policies
Object

Policies defined for the property.

FieldDescription
bookingPolicy

Booking policies defined for the property.

Type: BookingPolicy
cancellationPolicyConfigs

Cancellation policies defined for the property.

Type: Array of non nullable CancellationPolicyConfig
Property
Object

Representation of a physical property, including its units, reservations, and promotions.

FieldDescription
policiesNot nullable.

Booking and cancellation policies configured for the property.

Type: Policies
String
String

The String scalar type represents textual data, represented as UTF-8 character sequences. The String type is most often used by GraphQL to represent free-form human-readable text.