With Webhooks, you can integrate Re:plain with an external systems or services such as your CRM, ERP, e-mail or any other solutions.
To start working with Webhooks, you have to specify the URL of your handler in the Re:plain API add-on's Settings. Requests will be sent to this address when the events listed below will be performed.
HTTP (POST)
JSON
HTTP code 200
<aside> 💡 If the handler does not return a successful response — all subsequent events from that particular client will be suspended.
</aside>
10 seconds
5 attempts, once at about a minute
<aside> 💡 At the end of attempts — all current events from this particular client will be removed.
</aside>
Try to make your handlers idempotent
<aside> 💡 Each event contains an unique ID
</aside>
If the handler performs a heavy or a long operation — add the event to your message queue and then return a successful response immediately