Calling Oracle Hospitality Property APIs
All Oracle Hospitality APIs expect the following mandatory headers:
- Token: A header “Authorization” that includes the oAuth token obtained through Authenticating to Oracle Hospitality APIs.
-
x-hotelid: Supply a hotel (or property) code from the chain to which you have access in a header "x-hotelid." This is the Hotel ID you obtained from the hotel. If you do not know your x-hotelid, contact Oracle Customer Support at https://iccp.custhelp.com.
-
Application key: An unique application key is created for each application upon registering an application in the Oracle Hospitality Developer Portal. This key must be passed in the “x-app-key” header of every request to the Oracle Hospitality APIs. To obtain your application key, refer to Viewing the Application Key
.
Required Headers:
-
x-app-key:<ApplicationKey>
-
x-hotelid:<HotelId>
-
Authorization: Bearer <oAuth Token>
Optional Headers:
-
x-hubid — When you have hub-level access, you can supply the x-hubid to retrieve multiple properties.
-
x-externalSystem — If you have an external system in an OPERA environment (for example, for use with streaming or polling), then specifying that external system in the header of inbound API calls will avoid echoing those changes back to the streaming and polling APIs. For the streaming APIs, the external system code is shown on the application's Events Subscribed tab.
- X-Request-Id — This is a GUID that can help Oracle troubleshoot API issues. For more information, refer to X-Request-ID.
Example
curl --location }}{{'<GatewayURL>/lov/v1/listOfValues/Titles?parameterName=LanguageCode&includeInactiveFlag=false¶meterValue=E' {{}}
--header }}{{'Content-Type: application/json' {{}}
--header }}{{'x-app-key: <ApplicationKey>' {{}}
--header }}{{'x-hotelid: <HotelId>' {{}}
--header }}{{'Authorization: Bearer <Token>' {{}}
--data }}{{''
Table 9-2 Postman Environment Variables
Variable | Value |
---|---|
AppKey |
This value is accessed from the Developer Portal. |
ClientId |
This value is accessed from the Developer Portal. |
ClientSecret |
This value is accessed from the Developer Portal. |
HotelId |
This value is supplied by the hotel. |
EnterpriseId |
This value is provided by the customer so that you can add the environment. Subsequently, it can be accessed from the Developer Portal. |
Scope |
This value is always the following:
|