curl -i -X GET -H "Authorization:Bearer <access-token>" https://rest_server_url/spms/v1/reservations?searchValue=Anna&profileType=P
Specify the following options on the cURL command
line:
-
-i
option to include
the HTTP header in the output. This option is optional
-
-X
option to indicate
the type of request (GET
)
-
-H
to include access
token
The following shows an example of the response
body.
Look for the guest you want to view. In this example,
the guest name is Guest LASTNAME
.
{
"offset": 0,
"count": 2,
"hasMore": false,
"link": {
"method": "get",
"rel": "self",
"operationId": "nextPage",
"href": "https:\/\/rest_server_url\/spms\/v1\/reservations?searchValue=Anna&profileType=P"
},
"limit": 10,
"items": [
{
"item": {
"reservationId": 1043703,
"guestId": 1084973,
"firstName": "Guest",
"lastName": "LASTNAME",
"gender": "Female",
"dateOfBirth": "2016-xx-xx",
"reservationBookingNumber": "4095006",
"boardCardNumber": "1111111111111111",
"embarkCruiseId": 12503,
"embarkDate": "2022-05-09",
"reservationStatus": "Leaving Today",
"cabinNum": "1014",
...
},
"links": [ ... ]
},
{
"item": {
"reservationId": 994533,
"guestId": 1024763,
"firstName": "Guest",
"lastName": "LASTNAME",
"gender": "Female",
"dateOfBirth": "1980-xx-xx",
"boardCardNumber": "1111111111111111",
"reservationBookingNumber": "4083564",
"embarkCruiseId": 10881,
"embarkDate": "2022-05-09",
"reservationStatus": "No Show",
"cabinNum": "1110",
...
},
"links": [ ... ]
}
]
}