webhooks

Develper issues when using the Beds24 APi.
Post Reply
jimfoxes
Posts: 12
Joined: Sat Jun 12, 2021 1:37 pm

Are there examples of sending webhooks?
Are there services where the webhook goes, and they send a push notification about the booking and its changes to the phone.
lesleywoermeijer
Posts: 291
Joined: Wed Dec 28, 2016 2:20 pm

There are a few options for webhooks.

Have a look here :- https://wiki.beds24.com/index.php/Prope ... ng_Webhook

You can also use an Auto Action to trigger a webhook. Check out the examples in this wiki page :- https://wiki.beds24.com/index.php/Auto_ ... .2FWebhook

You can also use Integromat, go to Apps & Integrations > Integromat, send the data to Integromat and then you can connect to a vast number of applications. See the (?) help page for more details.
jimfoxes
Posts: 12
Joined: Sat Jun 12, 2021 1:37 pm

are there examples of third-party services (to whose url to send webhooks notifications) that can be used for push notifications and that can be put on a phone from Google Play?
iuri_rosa
Posts: 33
Joined: Fri Jun 10, 2016 9:14 pm

Hello,

Currently there are two options,

Integromat: You can send bookings to Integromat and from Integromat you can use the Beds24 Module to receive the booking Information and google push service to send a push notification to a user, This option is a bit limited to sending push notifications to google chrome, and you need to find a way of getting the user RegistrationID from google to send the push notification.

I believe that with integromat very little knowledge of programing is required to set this up.

OneSignal (https://onesignal.com) : This is a better option and it is a free service, we have tested this before and we did manage to send a push notification to a registered user, User registration in Onesignal is quite easys task, you do need to develop a tool to either import the "player ID" into the booking so that you can trigger a auto action and send the push notification to the specific user, or you can make your guest "register/accept" the push notifications and import the player ID into the booking.

With one signal and once the "playerID" is set into the booking you can trigger a auto action to send booking notifications to a guest.

OneSignal would be a better option however you do need to be able to develop the tools yourself to import the "playerID" ( this is the onesignal userID) development skills are required here, please have a look at the onesignal documentation for more information, https://documentation.onesignal.com/docs

Best Regards,

Iuri Rosa
iuri_rosa
Posts: 33
Joined: Fri Jun 10, 2016 9:14 pm

Hello,

Here goes an example for onesignal.

Register with the service and setup your account api key, than in Beds24 setup a auto action and under the webhook tab set the following.

URL: https://onesignal.com/api/v1/notifications

Custom Header: Content-Type: application/json; charset=utf-8
Authorization: Basic (OneSIgnal_API_KEY)

Body Data: {"app_id":"YOUR_ONESIGNAL_APP_ID","include_player_ids":["REGISTERED_PLAYER_ID"],"data":{"foo":"bar"},"contents":{"en":"message from an auto action web hook for booking [BOOKID]"},"web_buttons":[]}

This webook would send to the player id in OneSIgnal " message from an auto action web hook for booking 123456"

Best Regards

Iuri Rosa
Post Reply