Creating a Reservation Claim

With an invoice, you must generate a reservation claim object to proceed with the booking. This object represents all data required to finalize the booking and incorporates much of the data gathered to this point in the reservation workflow.


The reservation claim object requires, at a minimum, these four items:



Note that for credit card payment types, the amount you are required to pay must be equal to Pricing.DueOnline. Even if no money is due online, you must specify at least one payment type to copmlete the booking.


Here is an example ReservationClaim object:


ReservationClaim Example


The full detail of the ReservationClaim object may be found at the API Specification.


One field of particular note is the GuestInfo object. If you are checking out with a guest token, this object must contain at least a phone number to complete the booking, as follows:


GuestInfo Example


The FirstName and LastName fields are used to override a guest customer's name - this is provided to the tee sheet, and is useful as generating a guest token does not require this data (although it is not required); the EmailAddress field is used by affiliates to book as another customer while authenticated under a service account: see Affiliate Payments for more information on booking as an affiliate.


Now that we have generated a ReservationClaim object, we can proceed with the actual booking.


Booking the Tee Time

Booking a tee time is a simple POST to the AddReservation endpoint, as follows:


HTTP Request

POST /rest/customers/[email protected]/reservations HTTP/1.1
Content-Type: application/json; charset=utf-8
UserName: UserName
Password: Password
CustomerToken: v2!9SdtxN91odTlY9EHl48M+AhJ4Wx5zSPSSeZQqbMwNw9md7zhA8NeMw3Yght6qnHSX4gtZCWLWdI3hHpfXW-pzzTbsprfdrfpPAEfPIdXxW1Vzl0QEe5DySWIQSzP8ecEZ4zJoX2i-I4AmrF0v6wPjNrBQb10+3-L7AhHOg1Pi+dJYeYt1s34vF4Ob+dqsSbEtv14Q7qgQ6h7mYW20KeJHSWAo+ankzjQfIxt5BysuApi-2obea3lkyndhnrkp5j-pFXz4YC3Y+vAdAwz2kO+Nw==
Host: sandbox.api.gnsvc.com
Accept-Encoding: gzip, deflate
AdvancedErrorCodes: True

Body

HTTP Response


You will notice that much of the information returned is familiar from the input and previous steps. Of note in the response is the ReservationID. This number may be leveraged to retrieve reservation details at a later time for the customer, using the GetReservation endpoint.


Click to continue to: Conclusion.


Return to the end-to-end example index.