<OTA_HotelRateAmountNotifRQ>
를 통해 전송된 요금은 요금의 원래 투숙객 수 외에 성인 및 어린이 수를 고려하도록 수정할 수 있습니다. ExtraGuestCharges
메시지를 사용하면 추가 투숙객의 요금을 계산하는 방법과 요금이 적용될 객실, 요금제, 숙박 기간을 지정할 수 있습니다.
용량 요구사항
ExtraGuestCharges
메시지에서 계산된 가격은 모든 용량 요구사항이 충족되는 경우에만 유효합니다. 자세한 내용은 거래 (속성 데이터)를 참고하세요.
요청
구문
ExtraGuestCharges
메시지는 다음 문법을 사용합니다.
<?xml version="1.0" encoding="UTF-8"?>
<ExtraGuestCharges partner="partner_account_name"
id="message_ID"
timestamp="timestamp">
<HotelExtraGuestCharges hotel_id="HotelID" action="[overlay]">
<ExtraGuestCharge>
<RatePlans>
<RatePlan id="PackageID_1"/>
<RatePlan id="PackageID_2"/>
</RatePlans>
<RoomTypes>
<RoomType id="RoomID_1"/>
<RoomType id="RoomID_2"/>
</RoomTypes>
<StayDates>
<DateRange start="YYYY-MM-DD" end="YYYY-MM-DD"
days_of_week="MTWHFSU_or_subset"/>
</StayDates>
<AgeBrackets>
<AdultCharge amount="float"/>
<ChildAgeBrackets>
<!-- The following are different ways child charges can be specified.
Use the option that matches your system. -->
<ChildAgeBracket max_age="integer" amount="float"
exclude_from_capacity="[true|false]"/>
<ChildAgeBracket max_age="integer" percentage="float"
exclude_from_capacity="[true|false]"
counts_as_base_occupant="[never|preferred|always]"/>
<ChildAgeBracket max_age="integer" discount_amount="float"
exclude_from_capacity="[true|false]"
counts_as_base_occupant="[never|preferred|always]"/>
</ChildAgeBrackets>
</AgeBrackets>
</ExtraGuestCharge>
</HotelExtraGuestCharges>
</ExtraGuestCharges>
요소 및 속성
ExtraGuestCharges
메시지에는 다음과 같은 요소와 속성이 있습니다.
요소 / @속성 | 발생 횟수 | 유형 | 설명 |
---|---|---|---|
ExtraGuestCharges | 1 | Complex element | 이 메시지의 루트 요소입니다. |
ExtraGuestCharges / @partner | 1 | string | 이 메시지의 파트너 계정입니다. 이 문자열 값은 Hotel Center의
계정 설정 페이지에 표시된 Partner key 값입니다.
참고: 여러 계정의 피드를 제공하는 백엔드가 있는 경우 이 값은 동일한 계정의 |
ExtraGuestCharges / @id | 1 | string | 이 요청 메시지의 고유 식별자입니다. 이 값은 응답 메시지에 반환됩니다. 허용되는 문자는 a-z , A-Z , 0-9 , _ (밑줄), - (대시)입니다. |
ExtraGuestCharges / @timestamp | 1 | DateTime | 이 메시지의 생성 날짜 및 시간입니다. |
ExtraGuestCharges / HotelExtraGuestCharges | 0..n | HotelExtraGuestCharges | 단일 숙박 시설의 요금을 위한 컨테이너입니다. |
ExtraGuestCharges / HotelExtraGuestCharges / @hotel_id | 1 | string | 숙박 시설의 고유 식별자입니다. 이 값은 호텔 목록 피드의 <listing> 요소에서
<id> 를 사용하여 지정된 호텔 ID와 일치해야 합니다. 호텔 ID는 Hotel Center에도 표시됩니다. |
ExtraGuestCharges / HotelExtraGuestCharges / @action | 0..1 | enum | 업데이트가 적용되는 방식을 지정합니다. overlay 만 지원되며 기본값은 오버레이입니다. 업데이트가 적용되기 전에 이 속성에 대한 이전 청구가 삭제됩니다. |
ExtraGuestCharges / HotelExtraGuestCharges / ExtraGuestCharge | 0..99 | ExtraGuestCharge | 숙박 시설에 대한 단일 청구 세트입니다. 여기에는 요금이 적용되는 방식과 연령 또는 투숙객 카테고리별로 요금이 계산되는 방식에 관한 제한사항이 포함될 수 있습니다.
|
ExtraGuestCharges / HotelExtraGuestCharges / ExtraGuestCharge / AgeBrackets | 1 | AgeBrackets | 연령 또는 투숙객 카테고리별 요금을 계산하기 위한 연령대 컨테이너입니다. |
ExtraGuestCharges / HotelExtraGuestCharges / ExtraGuestCharge / AgeBrackets / AdultCharge | 0..1 | AdultCharge | 추가 성인 요금을 위한 컨테이너입니다. |
ExtraGuestCharges / HotelExtraGuestCharges / ExtraGuestCharge / AgeBrackets / AdultCharge / @amount | 0..1 | float | 추가 성인 1명당 청구되는 고정 금액을 지정하는 양수 소수점 값입니다. 이 청구에는 숙박 요금에 지정된 통화와 동일한 통화가 사용됩니다. |
ExtraGuestCharges / HotelExtraGuestCharges / ExtraGuestCharge / AgeBrackets / ChildAgeBrackets | 0..1 | ChildAgeBrackets | 추가 자녀 요금을 위한 컨테이너입니다. 이러한 연령대는 0~17세(양 끝값 포함)까지만 적용될 수 있습니다. |
ExtraGuestCharges / HotelExtraGuestCharges / ExtraGuestCharge / AgeBrackets / ChildAgeBrackets / ChildAgeBracket | 1..99 | ChildAgeBracket | 특정 연령대의 아동에게 적용되는 요금입니다. 이러한 값은 가장 낮은 max_age 에서 가장 높은 max_age 순으로 정렬해야 합니다. 청구 금액은 amount , percentage 또는 discount_amount 를 사용하여 지정할 수 있습니다. 각 <ChildAgeBracket> 에 이러한 속성 중 정확히 하나를 지정해야 합니다.
|
ExtraGuestCharges / HotelExtraGuestCharges / ExtraGuestCharge / AgeBrackets / ChildAgeBrackets / ChildAgeBracket / @max_age | 1 | integer | <ChildAgeBracket> 에 지정된 요금이 적용될 수 있는 최대 연령입니다. 이 <ChildAgeBracket> 앞에 지정된 다른 <ChildAgeBracket> 가 없는 경우 최소 기간은 0입니다. 그렇지 않으면 이전 구간의 최대 연령보다 1살 더 큽니다. |
ExtraGuestCharges / HotelExtraGuestCharges / ExtraGuestCharge / AgeBrackets / ChildAgeBrackets / ChildAgeBracket / @exclude_from_capacity | 1 | boolean | 이 연령대의 어린이를 객실의 총 숙박 인원 및 어린이 숙박 인원에 포함해야 하는지 나타내는 불리언입니다. 이러한 용량은 거래(속성 데이터)로 설정할 수 있습니다. 예를 들어 특정 연령 미만의 영아는 어린이 수에 포함되지 않을 수 있습니다. |
ExtraGuestCharges / HotelExtraGuestCharges / ExtraGuestCharge / AgeBrackets / ChildAgeBrackets / ChildAgeBracket / @amount | 0..1 | float | 이 구간의 추가 자녀에게 청구할 고정 금액을 지정하는 음이 아닌 소수점 값입니다. 이 청구에는 숙박 요금에 지정된 통화와 동일한 통화가 사용됩니다. |
ExtraGuestCharges / HotelExtraGuestCharges / ExtraGuestCharge / AgeBrackets / ChildAgeBrackets / ChildAgeBracket / @percentage | 0..1 | float | 이 범위에서 추가 아동에게 청구해야 하는 성인 가격의 비율을 지정하는 1~99 사이의 소수점 값입니다. 이 청구에는 숙박 요금에 지정된 통화가 사용됩니다. 성인 가격 계산 방식에 관한 자세한 내용은 |
ExtraGuestCharges / HotelExtraGuestCharges / ExtraGuestCharge / AgeBrackets / ChildAgeBrackets / ChildAgeBracket / @discount_amount | 0..1 | float | 이 구간의 추가 어린이의 성인 가격에 적용되는 고정 할인 금액을 지정하는 양수 소수점 값입니다. 이 청구에는 숙박 요금에 지정된 통화가 사용됩니다. 일반적으로 이 범위에 속하는 자녀의 요금은 '단가'에서 고정 금액을 공제하여 계산됩니다. 단가는 |
ExtraGuestCharges / HotelExtraGuestCharges / ExtraGuestCharge / AgeBrackets / ChildAgeBrackets / ChildAgeBracket / @counts_as_base_occupant | 0..1 | string |
여기서 목표는 실제 청구 금액을 계산할 수 있는 '단가'를 얻는 것입니다.
이 속성의 값은
|
ExtraGuestCharges / HotelExtraGuestCharges / ExtraGuestCharge / RoomTypes | 0..1 | RoomTypes | 요금이 적용되는 객실 유형 목록의 컨테이너입니다.
요금은 지정된 각 <RoomType> 에 적용됩니다. <RoomTypes> 가 지정되지 않으면 지정된 숙박 시설 내의 모든 객실에 요금이 적용됩니다. |
ExtraGuestCharges / HotelExtraGuestCharges / ExtraGuestCharge / RoomTypes / RoomType | 1..n | RoomType | 객실 유형을 지정합니다. 객실 유형은 거래(숙박 시설 데이터) 메시지의 <RoomData> 요소에 정의되며 <RoomID> 값을 사용하여 참조됩니다. (<RoomID> 값은 OTA_HotelRateAmountNotifRQ 메시지의 InvTypeCode 속성에서도 참조됩니다.) |
ExtraGuestCharges / HotelExtraGuestCharges / ExtraGuestCharge / RoomTypes / RoomType / @id | 1 | string | 인벤토리의 고유 식별자 (객실 유형)입니다. 이 값은 거래 (숙박 시설 데이터) 메시지의 <RoomID> 에 매핑됩니다.
허용되는 최대 문자 수는 50자(영문 기준)입니다. |
ExtraGuestCharges / HotelExtraGuestCharges / ExtraGuestCharge / RatePlans | 0..1 | RatePlans | 청구가 적용되는 요금제 목록의 컨테이너입니다.
<RatePlans> 를 지정하지 않으면 요금이 모든 요금제에 적용됩니다. |
ExtraGuestCharges / HotelExtraGuestCharges / ExtraGuestCharge / RatePlans / RatePlan | 1..n | RatePlan | 요금제를 지정합니다. 요금제는 트랜잭션(숙박 시설 데이터), OTA_HotelRateAmountNotifRQ, OTA_HotelAvailNotifRQ 메시지에 정의된 대로 패키지, 요금, 이용 가능 여부의 조합으로 정의되며 PackageID로 식별됩니다. |
ExtraGuestCharges / HotelExtraGuestCharges / ExtraGuestCharge / RatePlans / RatePlan / @id | 1 | string | 요금제의 고유 식별자입니다. 이 값은 트랜잭션 (숙박 시설 데이터) 메시지의 <PackageData> 에 있는 PackageID 값과 <OTA_HotelRateAmountNotifRQ> 및 <OTA_HotelAvailNotifRQ> 메시지 모두에서 <StatusApplicationControl> 의 RatePlanCode 속성에 매핑됩니다.
허용되는 최대 문자 수는 50자(영문 기준)입니다. |
ExtraGuestCharges / HotelExtraGuestCharges / ExtraGuestCharge / StayDates | 0..1 | StayDates | 청구가 적용되는 방식을 결정하는 하나 이상의 기간을 위한 컨테이너입니다. |
ExtraGuestCharges / HotelExtraGuestCharges / ExtraGuestCharge / StayDates / DateRange | 1..99 | DateRange | 프로모션이 적용될 날짜를 지정하는 기간입니다. |
ExtraGuestCharges / HotelExtraGuestCharges / ExtraGuestCharge / StayDates / DateRange / @start | 0..1 | Date | 기간의 시작일(숙박 시설의 시간대를 기준으로 함)입니다(기간에 포함). 이 날짜는 end 날짜 이전이거나 그와 같아야 합니다. start 가 지정되지 않으면 시작일 측면에서 날짜 범위가 사실상 무제한입니다. |
ExtraGuestCharges / HotelExtraGuestCharges / ExtraGuestCharge / StayDates / DateRange / @end | 0..1 | Date | 기간의 종료일(숙박 시설의 시간대 기준)입니다(기간에 포함). 이 날짜는 start 날짜와 같거나 그 이후여야 합니다. end 가 지정되지 않으면 종료일 측면에서 기간이 사실상 무제한입니다. |
ExtraGuestCharges / HotelExtraGuestCharges / ExtraGuestCharge / StayDates / DateRange / @days_of_week | 0..1 | string | 기간에 허용되는 요일입니다. 지정하지 않으면 기간 내 모든 날짜가 허용됩니다. 문자열의 각 문자는 하루를 지정합니다. 예를 들어 'MTWHF'는 기간에 평일이 허용됨을 지정합니다. 유효한 문자는 다음과 같습니다.
모든 문자 조합이 유효합니다. |
예
성인 요금
추가 성인 요금은 고정 금액으로만 표시할 수 있습니다. 다음 예는 성인 요금을 지정하는 ExtraGuestCharges
메시지를 보여줍니다.
<?xml version="1.0" encoding="UTF-8"?>
<ExtraGuestCharges timestamp="2001-02-03T04:05:06+00:00" id="1">
<HotelExtraGuestCharges hotel_id="ABC" action="overlay">
<ExtraGuestCharge>
<StayDates />
<AgeBrackets>
<AdultCharge amount="50" />
</AgeBrackets>
</ExtraGuestCharge>
</HotelExtraGuestCharges>
</ExtraGuestCharges>
해당 요금은 다음과 같습니다.
<?xml version="1.0" encoding="UTF-8"?>
<OTA_HotelRateAmountNotifRQ xmlns="http://www.opentravel.org/OTA/2003/05"
EchoToken="12345678"
TimeStamp="2020-05-19T20:50:37-05:00"
Version="3.0">
<RateAmountMessages HotelCode="ABC">
<RateAmountMessage>
<StatusApplicationControl Start="2020-05-18"
End="2020-05-23"
InvTypeCode="RoomID_1"
RatePlanCode="PackageID_1"/>
<Rates>
<Rate>
<BaseByGuestAmts>
<BaseByGuestAmt AmountAfterTax="100.00"
CurrencyCode="USD"
NumberOfGuests="1"/>
<BaseByGuestAmt AmountAfterTax="110.00"
CurrencyCode="USD"
NumberOfGuests="2"/>
<BaseByGuestAmt AmountAfterTax="120.00"
CurrencyCode="USD"
NumberOfGuests="3"/>
</BaseByGuestAmts>
</Rate>
</Rates>
</RateAmountMessage>
</RateAmountMessages>
</OTA_HotelRateAmountNotifRQ>
사용자가 Google에서 성인 4명을 검색하면 총 요금은 170 = 120 + 50입니다.
120은 NumberOfGuests="3"
가 있는 <BaseByGuestAmt>
비율에서 가져오고 50은 AdultCharge amount="50"
에서 가져옵니다.
하위 청구 항목
어린이 요금은 최대 17세까지의 연령대별로 표시되며 고정 금액, 비율 또는 할인으로 표시될 수 있습니다.
다음 예는 하위 청구 항목을 지정하는 ExtraGuestCharges
메시지를 보여줍니다.
<?xml version="1.0" encoding="UTF-8"?>
<ExtraGuestCharges timestamp="2001-02-03T04:05:06+00:00" id="1">
<HotelExtraGuestCharges hotel_id="ABC" action="overlay">
<ExtraGuestCharge>
<AgeBrackets>
<ChildAgeBrackets>
<ChildAgeBracket max_age="3" percentage="10"
counts_as_base_occupant="never" />
<ChildAgeBracket max_age="10" percentage="30"
counts_as_base_occupant="preferred"/>
<ChildAgeBracket max_age="17" discount_amount="10"
counts_as_base_occupant="always" />
</ChildAgeBrackets>
</AgeBrackets>
</ExtraGuestCharge>
</HotelExtraGuestCharges>
</ExtraGuestCharges>
해당 요금은 다음과 같습니다.
<?xml version="1.0" encoding="UTF-8"?>
<OTA_HotelRateAmountNotifRQ xmlns="http://www.opentravel.org/OTA/2003/05"
EchoToken="12345678"
TimeStamp="2020-05-19T20:50:37-05:00"
Version="3.0">
<RateAmountMessages HotelCode="ABC">
<RateAmountMessage>
<StatusApplicationControl Start="2020-05-18"
End="2020-05-23"
InvTypeCode="RoomID_1"
RatePlanCode="PackageID_1"/>
<Rates>
<Rate>
<BaseByGuestAmts>
<BaseByGuestAmt AmountAfterTax="100.00"
CurrencyCode="USD"
NumberOfGuests="1"/>
<BaseByGuestAmt AmountAfterTax="110.00"
CurrencyCode="USD"
NumberOfGuests="2"/>
</BaseByGuestAmts>
</Rate>
</Rates>
</RateAmountMessage>
</RateAmountMessages>
</OTA_HotelRateAmountNotifRQ>
```
1. Suppose you want the total price for 2 adults and 1 child of 2 years
of age.
Children aged 0-3 are never included in the rate's occupancy,
so here you should take the double occupancy rate and divide by 2 to
get the unit price. Then, multiply by the percentage rate and sum
with the rate to get the total price.
`unit price ` = 110 / 2 = 55
`total price` = 110 + 55 * 0.1 = 115.5
1. Suppose you want the total price for 1 adult and 2 children, both of 5
years of age.
Children aged 4-10 are preferably included in the rate's
occupancy. you should start by looking for a 3 adult rate since both
children are preferably included in the rate's occupancy. Since
that doesn't exist you should fall back to the 2 adult rate and then,
take this rate and divide by two to get the unit price. Finally,
multiply by the percentage rate and sum with the scaled rate to
get the total price.
`unit price` = 110 / 2 = 55
`total price` = 55 + 55 * 0.3 + 55 * 0.3 = 88
1. Suppose you want the total price for 1 adult and 1 child of 17
years of age.
Children aged 11-17 are always included in the rate's occupancy, so,
in this case, take the double occupancy rate and divide by 2 to get
the unit price. Then, deduct it by the discount amount and sum with
the scaled rate to get the total price.
`unit price` = 110 / 2 = 55
`total price` = 55 + (55 - 10) = 100
청구 제한사항
모든 유형의 제한은 선택사항이며 원하는 대로 조합하여 사용할 수 있습니다.
다음 예는 제한사항을 지정하는 ExtraGuestCharges
메시지를 보여줍니다.
<?xml version="1.0" encoding="UTF-8"?>
<ExtraGuestCharges timestamp="2001-02-03T04:05:06+00:00" id="1">
<HotelExtraGuestCharges hotel_id="ABC" action="overlay">
<ExtraGuestCharge>
<RoomTypes>
<RoomType id="queen" />
<RoomType id="king" />
</RoomTypes>
<RatePlans>
<RatePlan id="free-wifi" />
<RatePlan id="hot-breakfast" />
</RatePlans>
<StayDates>
<DateRange start="2020-09-01" end="2020-09-14"/>
</StayDates>
<AgeBrackets>
<AdultCharge amount="50" />
</AgeBrackets>
</ExtraGuestCharge>
</HotelExtraGuestCharges>
</ExtraGuestCharges>
위의 메시지는 2020년 9월 1일부터 2020년 9월 14일까지 요금제 'free-wifi' 또는 'hot-breakfast'가 적용되고 객실 유형이 'queen' 또는 'king'인 모든 제품에 성인 요금이 청구되어야 함을 나타냅니다.
중복 청구
이 섹션에서는 동일한 날짜 및 제품 조합에 대해 서로 다른 요금을 지정하는 잘못된 메시지의 예를 보여줍니다.
<?xml version="1.0" encoding="UTF-8"?>
<ExtraGuestCharges timestamp="2001-02-03T04:05:06+00:00" id="1">
<HotelExtraGuestCharges hotel_id="ABC" action="overlay">
<ExtraGuestCharge>
<RoomTypes>
<RoomType id="queen" />
</RoomTypes>
<RatePlans>
<RatePlan id="free-wifi" />
</RatePlans>
<StayDates>
<DateRange start="2020-09-01" end="2020-09-14"/>
</StayDates>
<AgeBrackets>
<AdultCharge amount="50" />
</AgeBrackets>
</ExtraGuestCharge>
<ExtraGuestCharge>
<RoomTypes>
<RoomType id="queen" />
<RoomType id="king" />
</RoomTypes>
<RatePlans>
<RatePlan id="free-wifi" />
<RatePlan id="hot-breakfast" />
</RatePlans>
<StayDates>
<DateRange start="2020-09-01" end="2020-09-05"/>
</StayDates>
<AgeBrackets>
<AdultCharge amount="20" />
</AgeBrackets>
</ExtraGuestCharge>
</HotelExtraGuestCharges>
</ExtraGuestCharges>
위의 메시지는 첫 번째 <ExtraGuestCharge>
에서 9월 1~14일의 '퀸' 및 'free-wifi'에 대해 추가 성인 요금 5000원을 청구해야 한다고 지정하기 때문에 유효하지 않습니다. 두 번째 <ExtraGuestCharge>
는 9월 1~5일에 'free-wifi' 또는 'hot-breakfast'가 포함된 'queen' 또는 'king'의 경우 성인 20명을 추가로 청구해야 한다고 지정합니다.
9월 1~5일에 'queen'과 'free-wifi'에 중복 청구가 있으며 추가 성인 요금을 20,000원과 50,000원 중 어느 쪽으로 청구할지 충돌이 있습니다.
응답
구문
ExtraGuestChargesResponse
메시지는 다음 문법을 사용합니다.
<?xml version="1.0" encoding="UTF-8"?>
<ExtraGuestChargesResponse timestamp="timestamp"
id="message_ID"
partner="partner_key">
<!-- Either Success or Issues will be populated. -->
<Success/>
<Issues>
<Issue code="issue_code" status="issue_type">issue_description</Issue>
</Issues>
</ExtraGuestChargesResponse>
요소 및 속성
ExtraGuestChargesResponse
메시지에는 다음과 같은 요소와 속성이 있습니다.
요소 / @속성 | 발생 횟수 | 유형 | 설명 |
---|---|---|---|
ExtraGuestChargesResponse | 1 | Complex element | 수신된 ExtraGuestCharges 요청 메시지의 성공 또는 문제를 나타내는 루트 요소입니다. |
ExtraGuestChargesResponse / @timestamp | 1 | DateTime | 이 메시지의 생성 날짜 및 시간입니다. |
ExtraGuestChargesResponse / @id | 1 | string | 연결된 ExtraGuestCharges 메시지의 고유 식별자입니다. |
ExtraGuestChargesResponse / @partner | 1 | string | 이 메시지의 파트너 계정입니다. |
ExtraGuestChargesResponse / Success | 0..1 | Success | ExtraGuestCharges 메시지가 경고, 오류, 실패 없이 성공적으로 처리되었음을 나타냅니다.
각 메시지에 |
ExtraGuestChargesResponse / Issues | 0..1 | Issues | ExtraGuestCharges 메시지를 처리하는 동안 발생한 하나 이상의 문제의 컨테이너입니다.
각 메시지에 |
ExtraGuestChargesResponse / Issues / Issue | 1..n | Issue | ExtraGuestCharges 메시지를 처리하는 동안 발생한 경고, 오류 또는 실패에 관한 설명입니다. 이러한 문제에 관한 자세한 내용은 피드 상태 오류 메시지를 참고하세요. |
ExtraGuestChargesResponse / Issues / Issue / @code | 1 | integer | 문제의 식별자입니다. |
ExtraGuestChargesResponse / Issues / Issue / @status | 1 | enum | 발생한 문제의 유형입니다. 유효한 값은 |
예
성공
다음은 처리가 완료된 ExtraGuestCharges
메시지에 대한 응답입니다.
<?xml version="1.0" encoding="UTF-8"?>
<ExtraGuestChargesResponse timestamp="2020-05-18T16:20:00-04:00"
id="12345678"
partner="partner_key">
<Success/>
</ExtraGuestChargesResponse>
문제
다음은 오류로 인해 처리되지 않은 ExtraGuestCharges
메시지에 대한 응답입니다.
<?xml version="1.0" encoding="UTF-8"?>
<ExtraGuestChargesResponse timestamp="2020-05-18T16:20:00-04:00"
id="12345678"
partner="partner_key">
<Issues>
<Issue code="1001" status="error">Example</Issue>
</Issues>
</ExtraGuestChargesResponse>