Changes

Jump to navigation Jump to search

API V2.0

3,900 bytes added, 30 May
]
= Prices Endpoints =
To get price setup rules, include the "includePriceRules" parameter in GET /properties like this /api/v2/properties?includePriceRules=true= Bookings ==
A room can have up to 16 prices. === GET /bookings ===
In the control panel, these can be set under Prices -> Daily Price RulesGet bookings matching specified criteria.
In === POST /bookings === Create or update bookings. === DELETE /bookings === Delete bookings by id. === GET /bookings​/messages === Get messages for a booking. === POST /bookings​/messages === Send messages or mark them as read. === PATCH /bookings​/messages === Make changes in all messages in a selection. === GET /bookings​/invoices === Get invoices for bookings. == Inventory == === GET /inventory​/rooms​/offers === Get offer based on specified criteria. === GET ​/inventory​/rooms​/availability === Get the availability status of dates. === GET ​/inventory​/rooms​/calendar === Get's per day values from the calendar. === POST ​/inventory​/rooms​/calendar === Modify per day calendar values. == Properties == === GET /properties === Get properties matching specified criteria. === POST /properties === Create or modify properties. === DELETE /properties === Delete properties by id. === DELETE /properties​/rooms === Delete rooms of properties by id. == Accounts ==  === GET /accounts === Get accounts and sub-accounts. === POST /accounts === Create or modify accounts. == Webhooks == === POST Webhooks - bookings === The webhook payload sent to your URL from the API these booking webhook found here: Settings -> Properties -> Access -> Booking Webhook == Channels - settings == === GET /channels​/settings === Get channel specific settings. === POST ​/channels​/settings === Modify channel settings. == Channels - Airbnb == === GET ​/channels​/airbnb​/users === Get all Airbnb user ids connected to an account. === GET /channels​/airbnb​/listings === Get all Airbnb listings for a specified Airbnb user id. === POST /channels​/airbnb === Perform actions at Airbnb. == Channels - Booking.com == === POST ​/channels​/booking === Perform actions at Booking.com. === GET /channels​/booking​/reviews === Get reviews from Booking.com. == Channels - Stripe == You can collect the card directly with Stripe so you do not have any PCI DSS obligations. The procedure would be accessed through GET like this: 1) Make the booking via API and get the new Booking ID. 2) Make a call to API V2 POST ​/channels​/stripe with the booking ID and any charges you want to collect. The line_items should be in the Stripe format for their checkout. https://docs.stripe.com/inventorypayments/calendarcheckout { "3) POST ​/channels​/stripe will return the session data"required to instantly create a Stripe payment checkout you can show the booker and they can securely enter their card while on your site. https: [//docs.stripe.com/api/checkout/sessions 4) After the booker enters their card, it is automatically connected to the booking ID and can be charged by API or manually from the control panel.  To use the Stripe endpoints, the process is basically the same as creating a normal Strip Checkout session, except by doing it via our API function it connects the payment to the booking. Use our API to create the Stripe session and then follow Stripes instructions and use the Stripe API or widgets to create a payment checkout for your page. The Stripe checkout session will create a Stripe checkout page for receiving payments into the properties Stripe account. Pass the line_items, success_url and cancel_url in the format required by the Stripe API to create a checkout session. The line_items format is defined in the Stripe documentation { If the booking already exists, pass it's booking ID as "calendarbookId": [and any payments to this checkout session will be added to the bookings invoice. { Setting "price1capture": 100false will authorize the amount but not collect the funds. The Stripe session will be returned,the session id can be used to create the Stripe checkout in your App. "price2"When initializing Stripe in your App, use this pk_live key and the stripe_account value (acct_) from the session response as follows: 300 <code>var stripe = Stripe('pk_live_zWSW2ykzZoq4mYcKg9c8jmHS',{ "price3"stripeAccount: 200,'acct_stripe_acccont-value-from-response'});</code>  See here for more information https://stripe.com/docs/payments/checkout   === POST /channels​/stripe === Perform actions at Stripe=== GET /channels​/stripe​/paymentMethods === Get payment methods for a booking from Stripe. } ] }=== GET ​/channels​/stripe​/charges === ] }Get charges for a booking from Stripe.
= Webhooks =
16

edits

Navigation menu