SOAP/HTTP headers
This topic describes the SOAP and HTTP header requirements for Booking Notification requests and responses.
SOAP request header
The common message header structure is used for communication level information to uniquely identify a message and to provide authentication information.
The soap-env:Envelope element must be present and requires the xmlns:soap-env
element, which is the namespace to which this message belongs. Current namespace
for requests is http://schemas.xmlsoap.org/soap/envelope/
.
Request header
Within the soap envelope, the Header element is the root element and includes
the Interface element with the xmlns attribute, which is the namespace to which
this message belongs. Current namespace for requests is http://www.newtrade.com/expedia/R14/header
.
The Header of a request message also includes these data elements:
- The <PayloadInfo> element with a @RequestID that uniquely identifies the request, and the @RequestorID and @ResponderID that identify the source and destination of the notification.
- The <CommDescriptor> element with the @SourceID and @DestinationID of the request message and a Retry Indicator.
- The <Authentication> element with username and password is required in the request message.
- The <PayloadDescriptor> element with the name of the OTA message in the message body.
- The <PayloadReference> element with the property identifier.
Syntax
1<soap-env:Envelope xmlns:soap-env="http://schemas.xmlsoap.org/soap/envelope/">2 <soap-env:Header>3 <Interface xmlns="http://www.newtrade.com/expedia/R14/header" Name="ExpediaDirectConnect" Version="4.0">4 <PayloadInfo RequestId="644630088" RequestorId="Expedia.com" ResponderId="EQCTest" ExpirationDateTime="2016-05-10T03:59:00+00:00" Location="Body">5 <CommDescriptor SourceId="ExpediaDC" DestinationId="EQCTest" RetryIndicator="false">6 <Authentication Username="Test" Password="Pa$$w0rd" />7 </CommDescriptor>8 <PayloadDescriptor Name="OTA_HotelResNotifRQ" Version="2003A">9 <PayloadReference SupplierHotelCode="40512" DistributorHotelId="40512" />10 </PayloadDescriptor>11 </PayloadInfo>12 </Interface>13 </soap-env:Header>14 <soap-env:Body>15 ...16 </soap-env:Body>17</soap-env:Envelope>
Child elements
Element | Description |
---|---|
<Interface> element | This the root element within the SOAP header. It includes the xmlns attribute, which is the namespace to which this message belongs. Current namespace for requests is http://www.newtrade.com/expedia/R14/header. Attributes:
|
<PayloadInfo> element | This is a child element of the <Interface> element. This element contains the SOAP header information related to the payload (the business message) in the SOAP body. One per message. Attributes:
|
<CommDescriptor> element | This is a child element of the <PayloadInfo>element. Attributes:
|
<Authentication> element | This is a child element of the <CommDescriptor> element. This element holds the Information used by Expedia Group to authenticate its ongoing booking notifications to partners. Optional, if present, occurs only once per message. Attributes:
|
<PayloadDescriptor> element | This is a child element of the <PayloadInfo> element. This element holds the business level information about the payload being transferred. Occurs once per message. Attributes:
|
<PayloadReference> element | This is a child element of the <PayloadDescriptor> element. This element holds the property identifier information. Optional, but if present, only occurs once per message. Attributes:
|
Payload name value set
This attribute indicates the name of the OTA message being sent in the XML message. The value set used by the API is defined in the table below.
OTA Payload Name (<PayloadDescriptor>/@Name) |
---|
OTA_HotelResNotifRQ |
OTA_HotelResNotifRS |
OTA_HotelResModifyNotifRQ |
OTA_HotelResModifyNotifRS |
OTA_CancelRQ |
OTA_CancelRS |
HTTP request header
The Booking Notification request is sent via HTTP POST and is answered back by the OTA response or Nack via HTTP response.
HTTP POST header example:
POST /ServletDispatcher HTTP/1.1 Host: destinationpartner.com Content-Type: text/xml; charset=UTF-8 Content-Length: 1234SOAPAction: ""
HTTP response header for OTA response example:
HTTP/1.1 200 OK Content-Type: text/xml; charset=UTF-8 Content-Length: 1234
HTTP response header for NACK example:
HTTP/1.1 500 Internal Server Error Content-Type: text/xml; charset=UTF-8 Content-Length: 2291
SOAP response header
The common message header structure is used for communication level information to uniquely identify a message and to provide authentication information.
The soap-env:Envelope element must be present and requires the xmlns:soap-env
element, which is the namespace to which this message belongs. Current namespace
for requests is http://schemas.xmlsoap.org/soap/envelope/
.
Response header - Success or business failure
The header of a response message must include these data elements:
- The Payload element with the same Request ID, Requestor ID and Responder ID returned in the response message that were received in the request (RQ) message.
- The CommDescriptor element with the Source ID and Destination ID for the response message. For request messages, the SourceId="ExpediaDC" and the @DestinationId is the partner. In response messages, however, this is reversed and the @SourceId is the partner and the DestinationId="ExpediaDC".
- The PayloadDescriptor element with the name of the OTA message in the message body.
The PayloadReference element can be sent in the response message but is not required.
Example
1<soap-env:Envelopexmlns:soap-env=" http://schemas.xmlsoap.org/soap/envelope/ ">2<soap-env:Header>3<Interface xmlns="http://www.newtrade.com/expedia/R14/header" Name="ExpediaDirectConnect" Version="4.0">4<PayloadInfo Location="Body" RequestId="644630088" RequestorId="Expedia.com" ResponderId="EQCTest">5<CommDescriptor DestinationId="ExpediaDC" SourceId="EQCTest" RetryIndicator="false"/>6<PayloadDescriptor Name="OTA_HotelResNotifRS" Version="2003A">7<PayloadReference SupplierHotelCode="40512" DistributorHotelId="40512"/>8</PayloadDescriptor>9</PayloadInfo>10</Interface>11</soap-env:Header>12<soap-env:Body>13...14</soap-env:Body>15</soap-env:Envelope>
Child elements
Element | Description |
---|---|
<Interface> element | This the root element within the SOAP header. It includes the xmlns attribute, which is the namespace to which this message belongs. Current namespace for requests is http://www.newtrade.com/expedia/R14/header. Attributes:
|
<PayloadInfo> element | This is a child element of the <Interface> element. This element contains the SOAP header information related to the payload (the business message) in the SOAP body. One per message. Attributes:
|
<CommDescriptor> element | This is a child element of the <PayloadInfo>element. Attributes:
|
<Authentication> element | This is a child element of the <CommDescriptor> element. This element holds the Information used by Expedia Group to authenticate its ongoing booking notifications to you. Optional, if present, occurs only once per message. Attributes:
|
<PayloadDescriptor> element | This is a child element of the <PayloadInfo> element. This element holds the business level information about the payload being transferred. Occurs once per message. Attributes:
|
<PayloadReference> element | This is a child element of the <PayloadDescriptor> element. This element holds the property identifier information. Optional, but if present, only occurs once per message. Attributes:
|
Response header - Temporary system failure
If you are experiencing temporary issues with a request sent by Expedia Group, you can return a negative acknowledgement with an empty <Header> element. The <Fault> element will still be a child of the <Body> element.
Example
1<?xml version="1.0" encoding="UTF-8"?>2<soap-env:Envelope xmlns:soap-env="http://schemas.xmlsoap.org/soap/envelope/">3<soap-env:Header/>4<soap-env:Body>5<soap-env:Fault>6<faultcode>soap-env:Client.2002</faultcode>7<faultstring>SOAP envelope was not found.</faultstring>8<faultactor>MessageReceiver.MessageParser</faultactor>9</soap-env:Fault>10</soap-env:Body>11</soap-env:Envelope>
When a partner uses SOAP faults, Expedia Group will retry the message until the expiration time is reached.
Child elements
Name | Description |
---|---|
Body | Container element for the business message or the Fault element. One occurrence per message. |
Fault | Optional. Container element for fault details. Child elements:
|
HTTP response header
The Booking Notification request is sent via HTTP Post, and is answered back by the OTA response or Nack via HTTP response.
HTTP POST header example:
POST /ServletDispatcher HTTP/1.1 Host: destinationpartner.com Content-Type: text/xml; charset=UTF-8 Content-Length: 1234 SOAPAction: ""
HTTP response header for OTA response example:
HTTP/1.1 200 OK Content-Type: text/xml; charset=UTF-8 Content-Length: 1234
HTTP response header for NACK example:
HTTP/1.1 500 Internal Server Error Content-Type: text/xml; charset=UTF-8 Content-Length: 2291