MutationsSandbox API

createReservation mutation

Creates a reservation in the sandbox environment. The mutation accepts arguments such as property ID, check-in and check-out dates, adult and child counts, and more. If not specified, reservation details are populated with logical test data. The mutation also supports sending a notification when a reservation is created.

Note: At this time, all reservations created in the sandbox environment are assigned static values to support property mapping:
- unit and room type IDs are the same as the property ID
- rate and rate plan IDs are set to 202323288

Syntax

1mutation {
3}

Example

1mutation {
2 createReservation(
3 input: {
4 propertyId: "100000027",
5 checkInDate: "2024-09-06",
6 checkOutDate: "2024-09-10",
7 businessModel: EXPEDIA_COLLECT,
8 paymentInstrumentType: EXPEDIA_VIRTUAL_CARD,
9 source: "Expedia",
10 adultCount: 5,
11 accessibilityText: [],
12 childCount: 3,
13 childAges: null,
14 multiRoomText: null,
15 smokingType: "NONSMOKING",
16 status: BOOKED,
17 remittanceType: GROSS,
18 sendNotification: true
19 }
20 ) {
21 reservation {
22 id
23 businessModel
24 checkInDate
25 checkOutDate
26 lastUpdatedDateTime
27 businessModel
28 multiRoomText
29 tidsCode
30 status
31 specialRequest
32 childCount
33 childAges
34 adultCount
35 totalGuestCount
36 bedTypes
37 smokingType
38 valueAddedPromotions {
39 id
40 description
41 }
42 accessibilityText
43 reservationIds {
44 id
45 idSource
46 }
47 rateIds {
48 id
49 idSource
50 }
51 unitIds {
52 id
53 idSource
54 }
55 primaryGuest {
56 firstName
57 lastName
58 loyaltyTier
59 emailAddress
60 supplierLoyaltyPlanInfo {
61 planCode
62 membershipNumber
63 }
64 phoneNumbers {
65 countryCode
66 areaCode
67 number
68 }
69 }
70 isReconciled
71 reconciliationType
72 }
73 }
74}

Arguments

NameDescription

input

Required.
Type: CreateReservationInput

Types


Name
Type
Boolean
Boolean

The Boolean scalar type represents true or false.

BusinessModel
Enum

Entity that collects payment for the reservation.

NameDescription
EXPEDIA_COLLECT

Expedia collects payment for the reservation.

HOTEL_COLLECT

Partner collects payment for the reservation.

BusinessModelInput
Enum

Entity that collects payment.

NameDescription
EXPEDIA_COLLECT

Expedia collects payment.

HOTEL_COLLECT

Partner collects payment.

CreateReservationInput
InputObject

Input object for creating a reservation.

FieldDescription
accessibilityText

Accessibility requests made by the guest for the reservation. Defaults to a single accessibility text with value \"In-room accessibility (in select rooms)\".

Type: Array of non nullable String
adultCount

Adult count. Defaults to 2.

Type: Int
bedTypes

Bed types of the reservation. Defaults to \"2 Queen Beds\".

Type: String
businessModel

Entity that collects payment for the reservation. Defaults to EXPEDIA_COLLECT.

Type: BusinessModelInput
checkInDate

Check-in date (format: YYYY-MM-DD) of the reservation. Defaults to a date in a near future.

Type: Date
checkOutDate

Checkout date (format: YYYY-MM-DD) of the reservation. Defaults to a random date in the month after the check-in date.

Type: Date
childAges

Ages of children associated with the reservation. If not specified, defaults to a list of random child ages.

Type: Array of non nullable Int
childCount

Child count. If not specified, defaults to the number of child ages provided (or its default).

Type: Int
clientMutationId

Partner's transaction ID that uniquely identifies the request, which can be used to associate requests and responses for troubleshooting purposes. This ID must be unique across requests and cannot be reused. However, if a request needs to be retried, such as because it failed or timed out, the ID provided in the original request should be used. The ID can be in any format as long as it uniquely identifies the request.

Type: String
multiRoomText

Text that is displayed to guests if there are multiple rooms associated with the reservation.

Type: String
paymentInstrumentType

Payment type, which is required for testing the variety of options of payment options. If this field is omitted:

  • For Expedia Collect properties, you can retrieve payment information using the Payments API.
  • For Hotel Collect properties, you can retrieve payment information using the Payments API.
Type: PaymentInstrumentTypeInput
petCount

Number of pets associated with the reservation.

Type: Int
primaryGuest

Guest who made the reservation. Personal information cannot be set and is automatically generated.

Type: PrimaryGuestInput
propertyIdNot nullable.

Property ID on which to associate the reservation.

Type: ID
reconciliationType

Reconciliation type of the reservation. Defaults to non-reconciled (null).

Type: ReconciliationTypeInput
remittanceType

Remittance type of the reservation. Defaults to null.

Type: RemittanceTypeInput
sendNotification

Whether to send a notification upon the creation of the reservation. Defaults to false.

Type: Boolean
smokingType

Whether smoking is allowed for the reservation. Defaults to \"NONSMOKING\".

Type: String
source

Source of the reservation, such as Hotels.com, Egencia, Orbitz. Here is a list of sources (values in the Expedia Collect column), though this list is not exhaustive. Defaults to EXPEDIA

Type: String
specialRequest

Text that is displayed to guests if there is a special request associated with the reservation. Defaults to \"Expedia test reservation. This is a free-text comment from the traveler.\".

Type: String
status

Current status of the reservation. Defaults to BOOKED.

Type: ReservationStatusInput
supplierOperatingModel

Supplier's operating model.

Type: SupplierOperatingModelInput
valueAddedPromotions

Value add promotion(s) used to book the reservation. Defaults to a single \"Free full breakfast for 2 per day\" value added promotion.

Type: Array of non nullable ReservationValueAddedPromotionInput
CreateReservationPayload
Object

Response payload to the `createReservation mutation.

FieldDescription
clientMutationId

Partner's transaction ID that identifies the request, which can be used to correlate with partner's transaction logs. This ID must be unique across requests and cannot be reused.

Type: String
reservationNot nullable.

Reservation details for the reservation that was created.

Type: Reservation
Date
Date

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

Float
Float

The Float scalar type represents signed double-precision fractional values as specified by IEEE 754.

Guest
Object

Details about the guest who made the reservation.

FieldDescription
emailAddressNot nullable.

Email address of the guest.

Type: String
firstNameNot nullable.

First (given) name of the guest.

Type: String
lastNameNot nullable.

Last name (surname) of the guest.

Type: String
loyaltyTierNot nullable.

The traveler's Expedia Group VIP Access loyalty tier. Values include MEMBER, VIP, PREMIUMVIP, and null.

Type: String
phoneNumbersNot nullable.

Phone numbers associated with the guest.

Type: Array of non nullable GuestContactPhoneNumber
supplierLoyaltyPlanInfo

Details about the guest's frequent traveler reward program.

Type: SupplierLoyaltyPlanInfo
GuestContactPhoneNumber
Object

Guest phone number.

FieldDescription
areaCodeNot nullable.

Area code (three digits).

Type: String
countryCodeNot nullable.

Country code (two digits).

Type: String
numberNot nullable.

Phone number (seven digits, no hyphen).

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
idNot nullable.

ID in the source system.

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

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.

Money
Object

Monetary amount along with its currency.

FieldDescription
amountNot nullable.

Actual monetary amount value. The scale of the amount will vary according to the currency or any rate conversion that may have been applied.

Type: String
currencyCodeNot nullable.

Code of the currency of the amount.

Type: String
Payment
Object

Guest payment details.

FieldDescription
cardNumberNot nullable.

Card number. Sandbox value is always \"4111111111111111\".

Type: String
issuerNameNot nullable.

Name of the issuer associated with the card. Sandbox value is \"VISA\" for HOTEL_COLLECT reservations and \"MasterCard\" for EXPEDIA_COLLECT reservations.

Type: String
paymentInstrumentTypeNot nullable.

Type of payment instrument. Sandbox value is \"GUEST_CREDIT_CARD\" for HOTEL_COLLECT reservations and \"EXPEDIA_VIRTUAL_CARD\" for EXPEDIA_COLLECT reservations.

Type: String
verificationNumber

Randomly generated, three-digit verification number associated with the card.

Type: String
PaymentInstrumentTypeInput
Enum

Type of payment instrument.

NameDescription
BANK_TRANSFER

Expedia collects payment via bank transfer. This is for use for Expedia Collect properties only.

CASH

Partner collects cash payment. This is for use for Hotel Collect properties only.

EXPEDIA_VIRTUAL_CARD

Expedia collects payment by Expedia Virtual Card. This is for use for Expedia Collect properties only. You can retrieve payment information using the Payments API.

GUEST_CREDIT_CARD

Property collects payment by guest credit card. This is for use for Hotel Collect properties only, and you can retrieve payment information using the Payments API.

NONE

No payment instrument.

PrimaryGuestInput
InputObject

Guest who made the reservation. Personal information about the guest cannot be set and is automatically generated.

FieldDescription
loyaltyTier

Loyalty tier of the guest. Defaults to \"MEMBER\".

Type: String
supplierLoyaltyPlanInfo

Details about the frequent traveler reward program. Defaults to null.

Type: SupplierLoyaltyPlanInfoInput
ReconciliationType
Enum

Type of reconciliation that has been performed on the reservation.

NameDescription
CANCEL

Reservation was cancelled.

MODIFY

Reservation was modified.

NO_SHOW

Reservation was marked as a no-show.

REFUND

Reservation was refunded.

ReconciliationTypeInput
Enum

Reconciliation type for the reservation.

NameDescription
CANCEL

Reservation was cancelled.

MODIFY

Reservation was modified.

NO_SHOW

Reservation was marked as a no-show.

REFUND

Reservation was refunded.

RemittanceType
Enum

Remittance type of the reservation.

NameDescription
GROSS

Gross remittance type.

NET

Net remittance type.

RemittanceTypeInput
Enum

Remittance type of the reservation.

NameDescription
GROSS

Gross remittance type.

NET

Net remittance type.

Reservation
Object

Reservation details.

FieldDescription
accessibilityTextNot nullable.

Accessibility requests made by the guest for the reservation.

Type: Array of non nullable String
adultCountNot nullable.

Count for all adult guests associated with the reservation.

Type: Int
amounts

Amounts associated with the reservation.

Type: ReservationAmounts
bedTypes

Bed type of the reservation.

Type: String
businessModelNot nullable.

Entity that collects payment for the reservation.

Type: BusinessModel
checkInDateNot nullable.

Check-in date (format: YYYY-MM-DD) of the reservation.

Type: Date
checkOutDateNot nullable.

Checkout date (format: YYYY-MM-DD) of the reservation.

Type: Date
childAges

Ages of children associated with the reservation.

Type: Array of non nullable Int
childCountNot nullable.

Count for all child guests associated with the reservation.

Type: Int
creationDateTimeNot nullable.

Date amd time when the reservation was created (format: yyyy-MM-dd'T'HH:mm:ss.SSSX, in UTC timezone).

Type: String
idNot nullable.

Expedia ID of the reservation.

Type: ID
isReconciledNot nullable.

Whether the reservation has been reconciled.

Type: Boolean
lastUpdatedDateTimeNot nullable.

Date and time when the reservation was last updated (format: yyyy-MM-dd'T'HH:mm:ss.SSSX, in UTC timezone).

Type: String
multiRoomText

Text that is displayed to guests if there is a multi-room booking associated with the reservation.

Type: String
paymentNot nullable.

Payment details associated with the reservation.

Type: Payment
petCount

Count of pets associated with the reservation.

Type: Int
primaryGuestNot nullable.

Guest who made the reservation.

Type: Guest
propertyIdNot nullable.

Expedia ID for the property.

Type: ID
rateIds

Unique identifiers for the rates associated with the reservation.

Type: Array of non nullable IdNode
reconciliationType

Type of reconciliation that has been performed on the reservation, if any.

Type: ReconciliationType
remittanceType

Remittance type of the reservation. Defaults to null.

Type: RemittanceType
reservationIdsNot nullable.

IDs for the reservation(s), each corresponding to a different source associated with the reservation.

Type: Array of non nullable IdNode
smokingTypeNot nullable.

Whether smoking is allowed for the reservation.

Type: String
sourceNot nullable.

Source of the reservation.

Type: String
specialRequest

Text that is displayed to guests if there is a special request associated with the reservation.

Type: String
statusNot nullable.

Current status of the reservation.

Type: ReservationStatus
supplierOperatingModel

Supplier's operating model.

Type: SupplierOperatingModelType
tidsCode

Travel Industry Designator Service (TIDS) code that allows a reservation to be recognized by industry suppliers.

Type: Int
totalGuestCountNot nullable.

Number of guests associated with the reservation.

Type: Int
unitIds

Known IDs for the unit/room in the source system(s). IDs that are returned depend on where the property was onboarded:

  • If the property was onboarded onto Vrbo, three IDs are returned: the partner's (external ID), Vrbo's (Vrbo internal ID), and Expedia's (EID).
  • If the property was onboarded onto Expedia, only the Expedia ID is included in the response.
Type: Array of non nullable IdNode
valueAddedPromotions

Value add promotion(s) used to book the reservation.

Type: Array of non nullable ReservationValueAddedPromotion
ReservationAmounts
Object

Amounts associated with the reservation.

FieldDescription
nightlyPayments

Detailed list of payments associated with the reservation.

Type: ReservationNightlyPayments
ReservationDailyAmount
Object

Reservation amount that applies to a specific stay date.

FieldDescription
amountNot nullable.

Amount value.

Type: Money
dateNot nullable.

Amount date (format: yyyy-MM-dd), such as 2025-01-30.

Type: Date
descriptionNot nullable.

Description associated to the amount.

Type: String
percent

Percentage of amount (when applicable), expressed as a fraction of 1 (such as 0.12 for 12%).

Type: Float
typeNot nullable.

Amount type (BASE, DISCOUNT, TAX, GUESS_PAYMENT, PAYOUT, and so on).

Type: String
ReservationNightlyPayments
Object

Nightly payments associated with the reservation.

FieldDescription
cancellationAmountsNot nullable.

Cancellation amounts for the reservation.

Type: Array of non nullable ReservationPerStayAmount
dailyAmountsNot nullable.

Reservation amounts for a specific stay date.

Type: Array of non nullable ReservationDailyAmount
perStayAmountsNot nullable.

Reservation amounts that apply to the whole stay.

Type: Array of non nullable ReservationPerStayAmount
ReservationPerStayAmount
Object

Reservation amount that applies to the whole stay.

FieldDescription
amountNot nullable.

Amount value.

Type: Money
descriptionNot nullable.

Description associated to the amount.

Type: String
percent

Percentage of amount (when applicable), expressed as a fraction of 1 (such as 0.12 for 12%).

Type: Float
typeNot nullable.

Amount type (BASE, DISCOUNT, TAX, GUESS_PAYMENT, PAYOUT, and so on).

Type: String
ReservationStatus
Enum

Current status of the reservation.

NameDescription
BOOKED

Reservation is booked and confirmed.

CANCELLED

Reservation is cancelled.

ReservationStatusInput
Enum

Current status of the reservation.

NameDescription
BOOKED

Reservation is booked and confirmed.

CANCELLED

Reservation is cancelled.

ReservationValueAddedPromotion
Object

Value add promotion(s) used to book the reservation.

FieldDescription
descriptionNot nullable.

Description of the value add promotion.

Type: String
idNot nullable.

ID of the promotion.

Type: String
ReservationValueAddedPromotionInput
InputObject

Value added promotion(s) used to book the reservation.

FieldDescription
descriptionNot nullable.

Description of the promotion.

Type: String
idNot nullable.

ID of the promotion.

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

SupplierLoyaltyPlanInfo
Object

Details about the frequent traveler reward program.

FieldDescription
membershipNumberNot nullable.

Traveler's membership number.

Type: Int
planCodeNot nullable.

Reward program code.

Type: String
SupplierLoyaltyPlanInfoInput
InputObject

Details about the frequent traveler reward program.

FieldDescription
membershipNumberNot nullable.

Traveler's membership number.

Type: Int
planCodeNot nullable.

Reward program code.

Type: String
SupplierOperatingModelInput
Enum

Supplier's operating model.

NameDescription
AGENCY

Partner operates on an agency model.

MERCHANT

Partner operates on a merchant model.

SupplierOperatingModelType
Enum

Type of supplier operating model used for the reservation.

NameDescription
AGENCY

Partner operates on an agency model.

MERCHANT

Partner operates on a merchant model.