Product management
ReferenceProduct management

units query

Retrieves details for units (room types) associated with a property, including size, amenities, unit spaces, and space amenities.

Note: Be sure to retrieve the unit and space IDs because you need them to manage the unit and spaces later (using updateUnit, updateUnitSpaces, and deleteUnitSpace).

Syntax

1query {
2 property(
3 id: String!,
4 idSource: IdSource
5 ){
6 units: [Unit]
7 }
8}

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.

Response

Arguments

NameDescription

id

Required.

Expedia ID (EID) or supplier ID (external ID in the partner's system) of the property. When retrieve units, you must specify the Expedia property ID.

Type: String

idSource

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

Type: IdSource

Types


Name
Type
AcknowledgementRecord
Object

Acknowledgement record for a bookable unit.

FieldDescription
acknowledgementType

Type of acknowledgement record.

Type: AcknowledgementType
id

ID of the acknowledgement record.

Type: String
lastUpdated

Date when the acknowledgment record was last updated.

Type: String
AcknowledgementType
Enum

Acknowledgement type values.

NameDescription
PLATFORM
LTR_POLICY
PLATFORM_ACK
PLATFORM_ACK_STATEMENT
PLATFORM_ATTESTATION
PLATFORM_ATTESTATION_LEGAL
PLATFORM_ATTESTATION_LINK
PLATFORM_ATTESTATION_NEVADA
PLATFORM_ATTESTATION_VER
PLATFORM_CERTIFY
PLATFORM_COMPLY
PLATFORM_JAPAN
PLATFORM_LEGAL
PLATFORM_READ
AmenitiesFiltersInput
InputObject

Filter for results based on amenity availability or name.

FieldDescription
available

Whether the results should include available amenities.

Type: Boolean
keys

Amenities name on which to filter results.

Type: OneOfStringFilterInput
Amenity
Object

Key-value pair that defines the amenity.

FieldDescription
keyNot nullable.

Amenity name.

Type: String
valueNot nullable.

Amenity attributes.

Type: AmenityValue
AmenityField
Object

Details about the amenity attribute.

FieldDescription
keyNot nullable.

Attribute name.

Type: String
typeNot nullable.

Attribute value's type.

Type: String
valueNot nullable.

Attribute value.

Type: AmenityFieldValue
AmenityFieldFeeType
Enum

Fee type values for amenities.

NameDescription
FREE
SPECIFIC_AMOUNT
UNSPECIFIED_AMOUNT
AmenityFieldFeeValue
Object

Fee type of an amenity.

FieldDescription
typeNot nullable.

Fee type of an amenity.

Type: AmenityFieldFeeType
AmenityFieldMeasurementValue
Object

Amenity measurement value and unit.

FieldDescription
unitOfMeasureNot nullable.

Type of measurement.

Type: String
valueNot nullable.

Value (size).

Type: String
AmenityFieldValue
Object

Amenity field value.

FieldDescription
feeValue

Fee value; used for field type fee. Allowed values include FREE and UNSPECIFIED_AMOUNT.

Type: AmenityFieldFeeValue
measurementValue

Measurement value.

Type: AmenityFieldMeasurementValue
textValue

Text value; used for field type text.

Type: Array of non nullable LocalizedString
value

Field value used for these field types: enum, string, trilean, int, and decimal. When the amenity type is trilean and the value is set to true, the amenity is included on the PDP. When set to false, the amenity definition is stored but disabled it on the PDP, similar to how amenities are disabled using AmenityValueInput : available.

Type: String
AmenityValue
Object

Amenity attributes.

FieldDescription
availableNot nullable.

Whether the amenity is available. false indicates that the amenity is defined but disabled (not shown to travelers).

Type: Boolean
fieldsNot nullable.

Amenity attributes.

Type: Array of non nullable AmenityField
ApplicableRegulations
Object

Additional registration information required by some districts.

FieldDescription
key

Identifier for additional information required by the district.

Type: ApplicableRegulationsKey
value

Value of the key required by the district.

Type: String
ApplicableRegulationsKey
Enum

Regulation key values.

NameDescription
LICENSE_DEPARTMENT_NAME

Name of the department in the issuing government body that approved the attribute (registration number).

LICENSE_GOVERNMENT_NAME

Name of the government body that issued the attribute.

LICENSE_HOLDER_NAME

Name of the person (holder) who holds the license, which may be different from the lodging partner.

LICENSE_HOLDER_STREET_ADDRESS_1

Street address of the person (holder) who holds the license, which may be different from the lodging partner.

LICENSE_HOLDER_STREET_ADDRESS_2

Secondary street address of the person (holder) who holds the license, which may be different from the lodging partner.

LICENSE_HOLDER_CITY

City of the person (holder) who holds the license, which may be different from the lodging partner.

LICENSE_HOLDER_PREFECTURE

Prefecture of the person (holder) who holds the license, which may be different from the lodging partner.

LICENSE_HOLDER_COUNTRY

County of the person (holder) who holds the license, which may be different from the lodging partner.

LICENSE_HOLDER_POSTAL

Postal code of the person (holder) who holds the license, which may be different from the lodging partner.

IS_VACATION_RENTAL
REGISTRATION_NUMBER
REGISTRATION_NUMBER_TYPE
AreaUnit
Enum

Unit of measure used to indicate the size of a property's unit.

NameDescription
SQUARE_FEET
SQUARE_METERS
AttachmentType
Enum

Exemption category types.

NameDescription
DRIVERS_LICENSE
AttachmentUrl
Object

Registration document information.

FieldDescription
key

Type of document referenced.

Type: AttachmentType
value

URL of the registration document file.

Type: String
BedGroup
Object

Bed types offered in the room. Vacation rentals are limited to a single bed group with multiple bed types. Conventional lodging may have two bed groups to represent alternatives. For example, a hotel might have a room type with 1 king bed or 2 full beds.

FieldDescription
bedsNot nullable.

Bed types offered in the room.

Type: Array of non nullable BedType
Bedroom
Object

Details about this bedroom.

FieldDescription
bedGroupsNot nullable.

Bed types offered in the room.

Type: Array of non nullable BedGroup
idNot nullable.

ID of this bedroom.

Type: ID
orderNot nullable.

Where the bedroom appears in the list of bedrooms (minimum value is 1).

Type: Int
text

Text that describes this bedroom.

Type: Array of non nullable Text
BedType
Object

Details about the bed.

FieldDescription
quantityNot nullable.

Number of beds in the bed group.

Type: Int
size

Bed size, such as FULL, KING, or TWIN.

Type: String
typeNot nullable.

Bed type, such as KINGBed or SofaBed.

Type: String
Boolean
Boolean

The Boolean scalar type represents true or false.

Compliant
Object

Compliance status for mandatory requirements only (at the unit level) according to the local jurisdiction's regulatory requirements. If invalid information is provided for an optional regulatory requirement, or if regulatory information is set in a jurisdiction that does not require regulatory information, status: COMPLIANT is returned. For optional requirements, a warning is returned in the warningStatus field of the updateUnitRegistration mutation's payload.

FieldDescription
reasonNot nullable.

Reason why the unit is in or out of compliance. The label used for the registration number in this string comes from the numberTypeLabel field on the RegistrationNumberRequirement type.

Type: String
statusNot nullable.

Whether the unit is compliant or not.

Type: RegulatoryStatus
Decimal
Decimal

Scalar representing an arbitrary-precision and scale decimal number, serialized as a string.

ExemptionCategory
Enum

Exemption types.

NameDescription
MAX_NIGHT_CAP
ExtraBedType
Object

Extra bed combination (type, size, quantity, and surcharge) that the unit provides.

FieldDescription
quantityNot nullable.

Number of extra beds.

Type: Int
sizeNot nullable.

Size of the bed.

Type: String
surcharge

Extra amount charged for the bed. Only extra beds of type 'CRIB' and 'ROLLAWAY_BED' will have a surcharge defined.

Type: Surcharge
typeNot nullable.

Type of bed.

Type: 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.

IdNode
Object

Known IDs in the source system.

FieldDescription
id

ID in the source system.

Type: ID
idSourceNot nullable.

Source of the ID.

Type: IdSource
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.

LivingRoom
Object

Details about a living room space.

FieldDescription
bedGroupsNot nullable.

Bed types offered in the living room.

Type: Array of non nullable BedGroup
idNot nullable.

Space ID of this living room.

Type: ID
orderNot nullable.

Where the living room appears in the list of living rooms (minimum value is 1).

Type: Int
text

Description of the living room.

Type: Array of non nullable Text
Locale
Locale

A type that represents a string that conforms to the BCP-47 (RFC 5646) standard. Example: en-GB.

LocalizedString
Object

Localized text and its locale code.

FieldDescription
localeNot nullable.

Locale code used to localize the text, which conforms to the BCP-47 (RFC 5646) standard, such as fr-FR.

Type: Locale
valueNot nullable.

Localized text.

Type: String
OneOfOperator
Enum

Values for operator input.

NameDescription
IN
NOT_IN
OneOfStringFilterInput
InputObject

Filter for results based on a string.

FieldDescription
operator

Whether to include or exclude the listed string.

Type: OneOfOperator
valuesNot nullable.

Strings used to filter results.

Type: Array of non nullable String
Property
Object

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

FieldDescription
units

Collection of unit configurations available for the property.

Type: Array of Unit
PropertyUnitArea
Object

Unit's size and unit of measure.

FieldDescription
unitNot nullable.

Unit of measure used to describe the unit's area.

Type: AreaUnit
valueNot nullable.

Size of the unit.

Type: Int
RateThresholds
Object
FieldDescription
net

The rate threshold settings of RateAcquisitionType NET.

Type: RateThresholdSettings
sellLar

The rate threshold settings of RateAcquisitionType SELL_LAR.

Type: RateThresholdSettings
RateThresholdSettings
Object

Minimum and maximum rates allowed as well as the source of the rate.

FieldDescription
maxAmountNot nullable.

Maximum acceptable rate, expressed as a decimal number.

Type: Decimal
minAmountNot nullable.

Minimum acceptable rate, expressed as a decimal number.

Type: Decimal
sourceNot nullable.

How the minimum and maximum amounts were calculated.

Type: RateThresholdsSource
RateThresholdsSource
Enum

How the minimum and maximum amounts were calculated.

NameDescription
MANUAL_OVERRIDE
RECENT_BOOKINGS
Registration
Object

Government registration information for the unit or room type.

FieldDescription
applicableRegulations

Additional registration information required by certain districts.

Type: Array of non nullable ApplicableRegulations
completeNot nullable.

Checks the consistency of the information in our systems at the property level to determine whether the registration information is sufficient to fulfill the requirements of the property's district. We do not recommend including this field in the query because it does not provide the true value for some properties.

If false is returned for a unit, you can use the Product API to identify active units, though false may be returned for inactive units that have incorrect regulatory information.

Type: Boolean
detailNot nullable.

Detailed registration information for the unit or room type.

Type: RegistrationDetail
district

Geographical jurisdiction identifier. For non-configured districts, this is null.

Type: String
RegistrationDetail
Object

Registration information for the unit or room type.

FieldDescription
acknowledgementRecordsNot nullable.

Acknowledgement records for the bookable unit. These are displayed to the traveler to confirm that they understand the regulatory requirements.

Type: Array of non nullable AcknowledgementRecord
applicableRegulationsNot nullable.

Additional information about the bookable unit required by certain districts.

Type: Array of non nullable ApplicableRegulations
attachmentUrls

Links for registration documentation files (if required).

Type: Array of non nullable AttachmentUrl
compliant

Compliance status for mandatory requirements only (at the unit level) according to the local jurisdiction's regulatory requirements. If invalid information is provided for an optional regulatory requirement, or if regulatory information is set in a jurisdiction that does not require regulatory information, status: COMPLIANT is returned. For optional requirements, a warning is returned in the warningStatus field of the updateUnitRegistration mutation's payload.

Type: Compliant
displayRegistrationNumber

Registration number displayed to the traveler.

Type: String
exemptionCategories

List of exemptions for the property, such as maximum night cap.

Type: Array of non nullable ExemptionCategory
numberOfPhysicalRooms

Number of rooms in the bookable unit.

Type: Int
registrationRecordsNot nullable.

Registration records for the bookable unit filed with the governing jurisdiction.

Type: Array of non nullable RegistrationRecord
regulatoryCategoryNot nullable.

Property classification category as maintained by the governing jurisdiction.

Type: RegulatoryCategory
regulatoryCategoryLabelNot nullable.

Regulatory category in the specified locale.

Type: String
regulatorySubType

Property subtype, such as primary or secondary, or null if not applicable.

Type: String
regulatoryType

Property type, such as residence, condo, boat, etc.

Type: String
unitIdNot nullable.

Expedia ID of the unit or room type.

Note: We strongly recommend that you include this field in your implementation even though it is nullable. This field provides an audit trail for reporting purposes.

Type: ID
RegistrationNumberType
Enum

Types of registration numbers (licenses).

NameDescription
LICENSE_NUMBER
LICENSE_ID
PARTIAL_TAX_ID
REGISTRATION_NUMBER
BUSINESS_LICENSE_NUMBER
OPERATOR_LICENCE_ID
OPERATOR_LICENSE_ID
BUSINESS_TAX_ID
RESORT_TAX_ID
SHORT_TERM_RENTAL_LICENSE
PERMIT_NUMBER
PLANNING_NUMBER
HOTEL_LICENSE
IS_IN_ZONING_PLAN
IS_PROFESSIONAL_HOST
TOURIST_DEVELOPMENT_TAX_ACCOUNT_NUMBER
HOME_SHARING_NUMBER
HOME_SHARING_PERMIT_NUMBER
CERTIFICATE_OF_USE_NUMBER
GENERAL_EXCISE_TAX_ID
TRANSIENT_ACCOMMODATIONS_TAX_ID
REGISTRATION_CERTIFICATE_NUMBER
PROPERTY_REGISTRY_NUMBER
SPECIAL_OPERATION_SIGN
TRANSIENT_REGISTRATION_NUMBER
PROVINCIAL_TOURIST_IDENTIFICATION_CODE
PARCEL_NUMBER_TAX_MAP_KEY
BUSINESS_TAX_RECEIPT_NUMBER
OPERATOR_LICENSE_NUMBER
OPERATOR_PERMIT
OWNER_PERMIT
TAX_IDENTIFICATION_NUMBER
MA_REGISTRATION_CERTIFICATE_NUMBER
BOSTON_REGISTRATION_NUMBER
OWNER_NAME
CADASTRAL_REFERENCE
OWNER_IS_CITIZEN
OWNER_ID
ZIPCODE
HOUSE_NUMBER
IS_CONDITION
ENTITY_TYPE
IS_TRADED
IS_GOVERNMENT_ENTITY
IS_ADDRESS_IN_EU
IS_RESIDENCE_IN_EU
LEGAL_ADDRESS
ISSUED_TAX_ID
PERMANENT_ESTABLISHMENT_COUNTRY
BUSINESS_REGISTRATION_NUMBER
LAND_REGISTRATION_NUMBER
BIRTH_DATE
IS_VAT_REGISTERED
VAT_ID
DATE
CITIZEN_ID
FOREIGN_ID
NEIGHBORHOOD_NAME
NATIONAL_ADDRESS_NUMBER
FLOOR_SYSTEM_NUMBER
JOURNAL_NUMBER
IS_ZONING_LAW_APPLIED
APPLICATION_NUMBER
ISSUANCE_DATE
RegistrationRecord
Object

Registration record for the bookable unit that has been filed with the jurisdiction.

FieldDescription
expiry

Registration record expiration date in this format: yyyy-mm-dd

Type: String
registrationNumberNot nullable.

Registration record ID.

Type: String
registrationNumberType

Type of registration/license.

Type: RegistrationNumberType
registrationNumberTypeLabel

Localized registration number type.

Type: String
RegulatoryCategory
Enum

Category values for regulatory categories. Most of jurisdiction districts only allow for two categories, HOTEL and VACATION_RENTAL, though more values GRAPHQL_VALIDATION_FAILED are provided to satisfy local government requirements.

NameDescription
HOTEL
BED_AND_BREAKFAST
HOTEL_OR_BNB
PRIMARY_HOME
PRIMARY_HOME_WITH_EXCEPTION
SECONDARY_HOME
VACATION_RENTAL
LONG_TERM_ONLY
SHORT_TERM_RENTAL
MINPAKU
SIMPLE_LODGING
EVENT
SPECIAL
NO_LICENSE
HOTEL_RYOKAN
RYOKAN
PRIMARY_OR_SECONDARY
TRANSIENT_OCCUPANCY_RESIDENTIAL_STRUCTURE
MOTEL
HOME_SHARING_NUMBER
VACATION_RENTAL_OTHER
HOSTEL
CAMPING_SITES
RURAL_LODGING
APARTMENT_HOTEL
RegulatoryStatus
Enum

Values for regulatory status.

NameDescription
COMPLIANT

Unit meets all regulatory requirements.

COMPLIANT_ACTION_NEEDED

Unit meets requirements to remain listed but will need to provide additional information (or other action) in order to not be delisted.

NOT_COMPLIANT

Unit does not meet all regulatory requirements and cannot be shown.

NOT_COMPLIANT_ACTION_NEEDED

Unit is not compliant, but enforcement hasn't started yet. Action should be taken for the listing to be compliant after enforcement date.

NOT_ALLOWED

Platform does not allow units in this jurisdiction; no actions from partner can affect status.

NONE

Unit's status cannot be determined.

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.

Surcharge
Object

Extra amount to charge for an extra bed.

FieldDescription
amount

Amount of the surcharge. Must be defined if type is not 'Free'.

Type: Decimal
typeNot nullable.

Surcharge type.

Type: String
Text
Object

Key-value pairs that specify free text elements.

FieldDescription
keyNot nullable.

Name of text element.

Type: String
valuesNot nullable.

Localized value of text element.

Type: Array of non nullable LocalizedString
Unit
Object

Unit details.

FieldDescription
ageCategoriesNot nullable.

Minimum age(s) for the specified age category.

Type: Array of non nullable UnitAgeCategory
amenities

Amenities available in the unit. You can filter by amenity name or whether it's available (active) by specifying the filters argument (type: AmenitiesFiltersInput).

Type: Array of non nullable Amenity
area

Unit's size and unit of measure.

Type: PropertyUnitArea
bedGroupsNot nullable.

Bed groups defined for the unit.

Type: Array of non nullable BedGroup
count

Cardinality of this unit configuration on the property.

Type: Int
extraBedsNot nullable.

Extra beds offered by the unit.

Type: Array of non nullable ExtraBedType
idNot nullable.

Expedia ID of the unit.

Type: ID
ids

Known IDs for the unit in the source system(s).

Type: Array of IdNode
maxOccupancyNot nullable.

Maximum occupancy of the unit in total and by age category.

Type: UnitOccupancy
nameConfigNot nullable.

Collection of elements and attributes related to the name of a unit.

Type: UnitNameConfig
propertyIdNot nullable.

Expedia ID of the property associated with this unit.

Type: ID
rateThresholdsNot nullable.

Minimum and maximum acceptable amounts that can be pushed for a unit night under any rate plan of the unit.

Type: RateThresholds
registration

Registration information for the unit or room type. You can specify the locale argument to retrieve the results in a specific language; specify the four-letter ISO code for language. Use a four-character code that indicates language and region, such as fr_FR for French in France.

Type: Registration
smokingPolicyNot nullable.

Smoking policy of this unit.

Type: UnitSmokingPolicy
spaces

Spaces available in the unit (as created by createUnitSpaces).

Type: UnitSpaces
statusNot nullable.

Unit status in Expedia's system.

Type: UnitStatus
UnitAgeCategory
Object

Minimum age for the specified age category.

FieldDescription
categoryNot nullable.

Category of age being defined.

Type: String
minAgeNot nullable.

Minimum age for a person belonging to the specified age category.

Type: Int
UnitNameAccessibility
Object

Attributes that determine if unit has accessibility.

FieldDescription
accessibilityTypeOverrideNot nullable.

Type of accessibility to be included in the name as specified; this will override includeAccessibility if present.

Type: String
includeAccessibilityNot nullable.

Whether to include 'Accessible' in the unit name. When accessibilityTypeOverride is provided, this field is set to true.

Type: Boolean
UnitNameAttributes
Object

Collection of attributes that can be used to build a unit name.

FieldDescription
accessibilityNot nullable.

Whether the unit has accessibility.

Type: UnitNameAccessibility
bedroomDetailsNot nullable.

Details of the bedroom, which is used to compose the name.

Type: String
customLabelNot nullable.

Custom label (up to 37 characters) used as a suffix to the unit name; always used in the name if provided. This text is not localized.

Type: String
featuredAmenityNot nullable.

Highlights a feature of the unit, which is used to compose the name.

Type: String
includeBedTypeNot nullable.

Whether to include bed type on the unit name. Not all bed combinations are fully displayed in the room name. Some combinations are displayed as “multiple beds” in the unit name.

Type: Boolean
includeSmokingPolicyNot nullable.

Whether to include unit smoking preferences in the unit name. When smokingPolicy is set to SMOKING_AND_NON_SMOKING and includeSmokingPolicy is set to true, the room name will specify SMOKING only.

Type: Boolean
locationNot nullable.

Highlights the location of the unit, which is used to compose the name.

Type: String
unitClassNot nullable.

Class of unit, which is used to compose the name (such as Basic, Standard, and so on).

Type: String
unitTypeNot nullable.

Type of unit, which is used to compose the name (such as Room, Apartment, Cabin, and so on).

Type: String
viewNot nullable.

Additional information about the view of the unit, which is used to compose the name.

Type: String
UnitNameConfig
Object

Collection of elements and attributes related to the name of a unit.

FieldDescription
attributesNot nullable.

Collection of attributes that can be used to build a unit name.

Type: UnitNameAttributes
valueNot nullable.

An auto-generated attribute name that is returned if attributes are provided.

Type: String
UnitOccupancy
Object

Maximum occupancy of the unit in total and by age category.

FieldDescription
adultsNot nullable.

Maximum number of adults that can reside in the unit; this will be at least 1 and less than or equal to the total.

Type: Int
childrenNot nullable.

Maximum number of children that can reside in the unit; this will be less than the total.

Type: Int
totalNot nullable.

Total count of people that can reside in the unit; this will be at least 1.

Type: Int
UnitSmokingPolicy
Enum

Smoking policy values.

NameDescription
NON_SMOKING
SMOKING
SMOKING_AND_NON_SMOKING
UnitSpaces
Object

Spaces available in the unit (as created by createUnitSpaces).

FieldDescription
bedrooms

Bedrooms available in the unit.

Type: Array of non nullable Bedroom
livingRooms

Living rooms available in the unit.

Type: Array of non nullable LivingRoom
UnitState
Enum

Unit status values.

NameDescription
ACTIVE
INACTIVE
UnitStatus
Object

Unit status in Expedia's system.

FieldDescription
stateNot nullable.

Unit status.

Type: UnitState