Feature Announcement: Webhook Retries

1 min read
Luke S.
Luke S.
Published December 2, 2020

When building a chat application, real-time events are crucial to providing an engaging user experience and adding custom functionality or behaviors specific to your use-case.

With Stream Chat webhooks, you can provide endpoints on your server to receive events as they happen, allowing you to consume the requests using domain-specific logic, handle custom chat commands, implement custom notification systems, and much more. For example - in a Customer Support setting - you may want to change the "open" status of a ticket in your database when an agent gets added to a channel.

Depending on the size of your application, many hundreds - even thousands - of events can be happening at any given time, from user presence changes to new messages and updates to a channel or it's members - all of which get forwarded to your webhook endpoint.

However, until now, if the recipient server fails to keep up with the events - or cannot receive the webhook request for whatever reason - the event becomes lost, and can’t be handled by your server or retried.

Because of this, we recently made some updates to how our Webhook system works to help keep your apps running smoothly, even in unpredictable or undesirable conditions.

What's new?

Retries

Webhook events will now retry for up to 15 seconds - or a maximum of five attempts, whichever comes first - in the case of a failed delivery.

Idempotency

The incoming request now includes an X-Webhook-ID header that provides a unique identifier for the webhook that will be consistent across retries, so you can deduplicate requests if necessary. More information on all of the headers included with each Stream Chat webhook event can be found here

Reuse Connections

Webhook connections are now reused when possible, including support for keep-alive to make sure requests are speedy and efficient.

All of the above updates are now available to all customers, so you can benefit from more reliable Webhooks starting today!

For more information on these updates and all things Webhooks with Stream Chat you can check out our Webhooks Documentation, and as always, let us know your feedback through the comment form on the docs page.

Integrating Video with your App?
We've built a Video and Audio solution just for you. Check out our APIs and SDKs.
Learn more ->