Booking flow via API

Discussions

Ask a Question
Back to All

Booking flow via API

I need to build a custom website on top of Lodgify's API, but I don't want to use Lodgify's checkout page. So, when a guest starts to book, a checkout process will be on the website instead of redirecting to Lodgify's checkout page. The only thing I will need is probably Lodgify's payment page so that I don't need to develop integrations with payment systems myself.

Is it possible to achieve this via API?

What I'm trying to do:

  1. Create a booking using https://api.lodgify.com/v1/reservation/booking/ with the status Open.
  2. Create a quote using https://api.lodgify.com/v1/reservation/booking/id/quote
  3. Get a payment link using https://api.lodgify.com/v2/reservations/bookings/id/quote/paymentLink

When I open a payment link, it says: Cannot make a Payment when Quote status is Not sent.

Am I doing everything correctly or should I use different endpoints and different flow? Also, if I do everything correctly, how to change the quote's status to "Sent" from "Not sent"?

Thanks.