Reservation - ResAudit API
Modified on: 2024-07-24 16:00
TABLE OF CONTENTS
Introduction
This is an optional API that is designed to streamline the transmission of reservation audit data from the Hotel Suppliers to GO Distributors. It is a push-based API, GO pushes the data including real-time guest stay status (indicative of check-in, check-out, or no-show statuses), precise timestamps for when guests check in and out, and the financial details associated with each reservation to GO Distributors.
This interface adopts the DerbySoft GO API authentication mechanism to ensure the security of data during interface interactions. (For more details on authorization, please refer to docs).
GO Distributors are required to configure a specific endpoint on the Go Console for receiving data. How to configure the reservation audit endpoint:
① Sign in Go Console and navigate to Management >> Customer Setting page.
② Scroll to the page bottom, and find the label "Reservation Audit Endpoint". ③ *** Please note *** Only authorized users can renew the Production Reservation Audit Endpoint(It's similar to the authorization of renewing Access Token).To apply for authorization, please contact your Account Manager or our Support team.
Res Audit
GO push reservation audit data to GO Distributor.
Please note that only a few hotel suppliers support providing audit data to GO.
POST /reservation/audit/push HTTP/1.1 URL: {{endpoint}}/reservation/audit/push Authorization: 53ac07777cdffac2d53000002d698728ce964432d7167596bc005c5fc Accept-Encoding: gzip Content-Encoding: gzip Content-Type: application/json;charset=utf-8
Request Example
{ "header": { "distributorId": "xxx", "supplierId": "xxx", "token": "xxx" }, "hotelId": "hotelCode", "reservationId": { "distributorResId": "xxx", "derbyResId": "xxx", "supplierResId": "supplierResId1,supplierResId2" }, "auditId": "xx", "auditDateTime": "2023-06-04T08:12:23.123Z", "currency": "CNY", "roomDetails": [ { "roomId": "100001", "rateId": "123456", "stayDateRange": { "checkInDateTime": "2023-06-01 08:12:23", "checkOutDateTime": "2023-06-03 08:12:23", "timeZone": "" }, "roomStatus": "CHECK_IN", "roomRevenue": { "amountBeforeTax": 250, "amountAfterTax": 450 }, "otherFees": [ { "amountBeforeTax": 3, "amountAfterTax": 5, "description": "Drink" } ], "hotelComments": "Comments from hotel side", "supplierResId": "supplierResID1" } ], "total": { "roomRevenue": { "amountBeforeTax": 250, "amountAfterTax": 450 }, "otherFees": [ { "amountBeforeTax": 20, "amountAfterTax": 40, "description": "Drink Fee" }, { "amountBeforeTax": 50, "amountAfterTax": 70, "description": "Penalty" }, { "amountBeforeTax": 40, "amountAfterTax": 50, "description": "ServiceCharge" } ] } }
Request Specification
Attribute | Type | Required | Description | Example |
header | object | Yes | / | / |
@distributorId | string | Yes | Distributor's ID Max Length: 32 | HUAWEI |
@supplierId | string | Yes | Supplier's ID Max Length: 32 | HUAZHU |
@token | string | Yes | / | / |
hotelId | string | Yes | Supplier Hotel ID | 100001 |
reservationId | object | Yes | / | / |
@distributorResId | string | Yes | Reservation ID of Distributor | C2084DFL0 |
@derbyResId | string | Yes | Reservation ID of DerbySoft | D15F893D34DF |
@supplierResId | string | Yes | Reservation ID of Hotel Supplier | 89389494,89389495 |
auditId | string | Yes | Audit record ID | 9f1925cc888c438d |
auditDateTime | string | Yes | The time when GO received the request from Hotel Suppliers | 2023-06-04T08:12:23.123Z |
currency | string | Yes | Currency Code【ISO-4217】 | USD |
roomDetails | array[object] | Yes | There would be multiple rooms | / |
@roomId | string | Yes | Room ID | 10000101 |
@rateId | string | Yes | Rate Plan ID | 123456 |
@roomStatus | enum | Yes | Eunm: [NO_SHOW, CHECK_IN, CHECK_OUT] | / |
@hotelComments | string | No | Comments by Hotel Supplier | / |
@supplierResId | string | If the supplier has split the order for multiple rooms, here it represents the sub-order number for the supplier. | 89389494 | |
roomDetails/stayDateRange | object | No | Actual time of check-in/check-out | / |
@checkInDateTime | string | Yes | Guest check-in datetime | 2023-06-04T08:12:23.123Z |
@checkOutDateTime | string | Yes | Guest check-in datetime | 2023-06-04T08:12:23.123Z |
@timeZone | string | No | Time Zone | / |
roomDetails/roomRevenue | object | No | Room cost | / |
@amountBeforeTax | number | No | Amount Before tax | / |
@amountAfterTax | number | No | Amount After tax | / |
roomDetails/otherFees | array[object] | No | / | / |
@amountBeforeTax | number | No | Amount Before Tax | / |
@amountAfterTax | number | No | Amount After Tax | / |
@description | string | No | Description of Fees | / |
total | object | No | / | / |
total/roomRevenue | object | No | Total Order Cost | / |
@amountBeforeTax | number | No | Amount Before Tax | / |
@amountAfterTax | number | No | Amount After Tax | / |
total/otherFees | array[object] | No | Other fees | / |
@amountBeforeTax | number | No | Amount Before Tax | / |
@amountAfterTax | number | No | Amount After Tax | / |
@description | string | No | Description of Fees | / |
Response Example
Notes: GO will use the response code to determine whether the res audit push is successful. For example, an HTTP status of 200 represents a successful push, and non-200 represents a failed push. For failed requests, GO will retry (retry 5 times, with a 5-minute interval between each retry).
- Success Response (HTTP Status 200)
{ "header": { "distributorId": "xxx", "supplierId": "xxx", "token": "xxx" }, "result": "Success" }
- Error Response (HTTP Status 401)
{ "errorCode": "InvalidIdentityCredential", "errorMessage": "Invalid Identity Credential" }
- Error Response (HTTP Status 500)
{ "errorCode": "InternalError", "errorMessage": "error message with details of the error" }
Response Specification
Attribute | Type | Required | Description | Example |
---|---|---|---|---|
header | object | Yes | / | / |
@supplierId | string | Yes | Max Length: 32 Hotel Supplier's ID | HUAZHU |
@distributorId | string | Yes | Max Length: 32 Distributor's ID | HUAWEI |
@token | string | Yes | Max Length: 64 It is recommended to use a Universally Unique Identifier (UUID) as a unique identifier for requests and responses. This will ensure that each request and response is uniquely identified and can be tracked efficiently. | 18393849028490234 |
result | string | Yes | / | Success |
Did you find it helpful? Yes No
Send feedback