Sabre酒店预订SOAP api中的VERIFY RATE LEVEL错误

时间:2015-12-10 09:28:17

标签: soap sabre

我正在尝试使用Sabre SOAP api进行酒店预订。但无法通过此VERIFY RATE LEVEL错误。我的酒店预订有效负载如下:

<?xml version='1.0' encoding='UTF-8'?>
<SOAP-ENV:Envelope xmlns:SOAP-ENV="http://schemas.xmlsoap.org/soap/envelope/" xmlns:eb="http://www.ebxml.org/namespaces/messageHeader">
    <SOAP-ENV:Header>
        <eb:MessageHeader SOAP-ENV:mustUnderstand="0">
            <eb:From>
                <eb:PartyId eb:type="urn:x12.org:IO5:01">from</eb:PartyId>
            </eb:From>
            <eb:To>
                <eb:PartyId eb:type="urn:x12.org:IO5:01">ws</eb:PartyId>
            </eb:To>
            <eb:CPAId>H65H</eb:CPAId>
            <eb:ConversationId>app_name</eb:ConversationId>
            <eb:Service eb:type="sabreXML"></eb:Service>
            <eb:Action>OTA_HotelResLLSRQ</eb:Action>
        </eb:MessageHeader>
        <wsse:Security xmlns:wsse="http://schemas.xmlsoap.org/ws/2002/12/secext">
            <wsse:BinarySecurityToken valueType="String" EncodingType="wsse:Base64Binary">
<!--                  Use Security token from Authentication Request  -->
            <<-- sabre auth token -->>
            </wsse:BinarySecurityToken>
        </wsse:Security>
    </SOAP-ENV:Header>
    <SOAP-ENV:Body>
      <OTA_HotelResRQ xmlns="http://webservices.sabre.com/sabreXML/2011/10" xmlns:xs="http://www.w3.org/2001/XMLSchema" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" Version="2.2.0">
        <Hotel>
            <BasicPropertyInfo ChainCode="HY" HotelCode="1"/>
            <Guarantee Type="GDPST">
                <CC_Info>
                    <PaymentCard Code="cc-cvc" ExpireDate="cc-date" Number="cc-number"/>
                    <PersonName>
                        <Surname>TEST</Surname>
                    </PersonName>
                </CC_Info>
            </Guarantee>
            <GuestCounts Count="2">
                <ExtraGuest>1</ExtraGuest>
            </GuestCounts>
            <RoomType NumberOfUnits="1" RoomTypeCode="A2DRAC"/>
            <TimeSpan End="12-24T13:00" Start="12-22T12:00"/>
        </Hotel>
    </OTA_HotelResRQ>
    </SOAP-ENV:Body>
</SOAP-ENV:Envelope>

但我收到的回复是 1VERIFY RATE LEVEL 错误,如下所示

<?xml version="1.0" encoding="UTF-8"?>
<soap-env:Envelope xmlns:soap-env="http://schemas.xmlsoap.org/soap/envelope/">
    <soap-env:Header>
        <eb:MessageHeader xmlns:eb="http://www.ebxml.org/namespaces/messageHeader" eb:version="1.0" soap-env:mustUnderstand="1">
            <eb:From>
                <eb:PartyId eb:type="urn:x12.org:IO5:01">ws</eb:PartyId>
            </eb:From>
            <eb:To>
                <eb:PartyId eb:type="urn:x12.org:IO5:01">from</eb:PartyId>
            </eb:To>
            <eb:CPAId>H65H</eb:CPAId>
            <eb:ConversationId>app_name</eb:ConversationId>
            <eb:Service eb:type="sabreXML"/>
            <eb:Action>OTA_HotelResLLSRS</eb:Action>
            <eb:MessageData>
                <eb:MessageId>8860ceca-d624-4fc6-b3a6-c1f7a7da5f43@61</eb:MessageId>
                <eb:Timestamp>2015-12-09T06:26:01</eb:Timestamp>
            </eb:MessageData>
        </eb:MessageHeader>
        <wsse:Security xmlns:wsse="http://schemas.xmlsoap.org/ws/2002/12/secext">
            <wsse:BinarySecurityToken valueType="String" EncodingType="wsse:Base64Binary">Shared/IDL:IceSess\/SessMgr:1\.0.IDL/Common/!ICESMS\/ACPCRTC!ICESMSLB\/CRT.LB!-3460990906663307648!220138!0</wsse:BinarySecurityToken>
        </wsse:Security>
    </soap-env:Header>
    <soap-env:Body>
        <OTA_HotelResRS xmlns="http://webservices.sabre.com/sabreXML/2011/10" xmlns:xs="http://www.w3.org/2001/XMLSchema" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:stl="http://services.sabre.com/STL/v01" Version="2.2.0">
            <stl:ApplicationResults status="NotProcessed">
                <stl:Error type="BusinessLogic" timeStamp="2015-12-09T00:26:01-06:00">
                    <stl:SystemSpecificResults>
                        <stl:Message>1VERIFY RATE LEVEL                                             </stl:Message>
                        <stl:ShortText>ERR.SWS.HOST.ERROR_IN_RESPONSE</stl:ShortText>
                    </stl:SystemSpecificResults>
                </stl:Error>
            </stl:ApplicationResults>
        </OTA_HotelResRS>
    </soap-env:Body>
</soap-env:Envelope>

我无法弄清楚是什么问题,因为我无法在Sabre文档中找到与 1VERIFY RATE LEVEL 相关的任何内容。

有什么问题?我的请求有效负载是无效还是某些参数丢失了?

由于

1 个答案:

答案 0 :(得分:0)

我想这就是你出错的地方。

 <eb:Action>OTA_HotelResLLSRQ</eb:Action>

正确的值是

<eb:Action>OTA_HotelAvailLLSRQ</eb:Action>

也会传递以下标记中的值。

<eb:Service eb:type="sabreXML">HotelAvailLLSRQ</eb:Service>

正文请求部分

<ns:OTA_HotelAvailRQ  Version="2.2.0">
        <ns:AvailRequestSegment>

            <ns:GuestCounts Count="2"/>
            <ns:HotelSearchCriteria >
                <ns:Criterion>
                    <ns:Address>
                        <ns:CityName></ns:CityName>
                        <ns:CountryCode>US</ns:CountryCode>
                        <ns:PostalCode></ns:PostalCode>
                        <ns:StreetNmbr></ns:StreetNmbr>
                    </ns:Address>
                    <ns:HotelRef HotelCityCode="DFW" />
                </ns:Criterion>
            </ns:HotelSearchCriteria>
            <ns:TimeSpan End="02-12" Start="01-12"/>
        </ns:AvailRequestSegment>
    </ns:OTA_HotelAvailRQ>

我希望这能解决你的问题。 感谢。