> ## Documentation Index
> Fetch the complete documentation index at: https://docs.flatpeak.com/llms.txt
> Use this file to discover all available pages before exploring further.

# Subscribing to events delivery via webhooks

Webhooks enable your application to receive real-time events from your Flatpeak account as they occur. When an event occurs — for example, when a **Location** object is created, Flatpeak generates an [Event](/guides/system/events) and automatically sends it to your registered webhook endpoint.

Configure webhook endpoints from the [Dashboard](https://dashboard.flatpeak.com) > **Webhooks**, which provides a user interface for registering and testing your webhook endpoints.

Flatpeak signs webhook payloads so you can verify authenticity. See [Signature verification](/guides/system/webhooks/verify-signatures) for headers, algorithm, and code samples, and [Debug webhook signatures](/guides/system/webhooks/debug-signatures) for an OpenSSL walkthrough.

## Pending deliveries

Use [Dashboard](https://dashboard.flatpeak.com) > **Webhooks** > **Logs** to determine how many endpoints haven’t responded successfully to delivery. You can expedite resending or force failed deliveries to try again from there. Flatpeak will automatically retry deliveries on the following schedule:

| Time        | Description                                                                                                                                                                       |
| :---------- | :-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
| Immediately | As soon as an event has occurred                                                                                                                                                  |
| 30 seconds  | In 30 seconds if the first delivery attempt is unsuccessful.                                                                                                                      |
| 1 hour      | In 30 seconds if the first delivery attempt is unsuccessful.                                                                                                                      |
| 6 hours     | In 30 seconds if the first delivery attempt is unsuccessful.                                                                                                                      |
| 12 hours    | In 30 seconds if the first delivery attempt is unsuccessful.                                                                                                                      |
| 24 hours    | In 24 hours. If this delivery attempt is unsuccessful, there will be no more automatic retries. Go to **Dashboard** > **Webhooks** to initiate the redelivery of failed webhooks. |

### Delivery timeouts

Flatpeak will wait up to 10 seconds for your server to respond to the delivery attempt, after which the attempt will be deemed failed if no response from your server has been received.

## Delivery queue

* To view webhooks delivery queue, go to **Dashboard** > **Webhooks**
* To view all events go to **Dashboard** > **Events**

## Debugging webhook integrations

Multiple types of issues can occur when delivering events to your webhook endpoint:

* Flatpeak might not be able to deliver an event to your webhook endpoint.
* Your webhook endpoint might have an SSL issue.
* Your network connectivity is intermittent.
* Your webhook endpoint isn’t receiving events that you expect to receive.

## HTTP status codes

When an event displays a status code of 200, it indicates successful delivery to the webhook endpoint. You might also receive a status code other than 200. View the table below for a list of common HTTP status codes and recommended solutions.

| Webhook status                    | Description                                                                                                                                                                                                                      | Fix.                                                                                                                             |
| --------------------------------- | -------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | -------------------------------------------------------------------------------------------------------------------------------- |
| (Unable to connect) ERR           | We’re unable to establish a connection to the destination server.                                                                                                                                                                | Make sure that your host domain is publicly accessible to the internet.                                                          |
| (302) ERR (or another 3xx status) | The destination server attempted to redirect the request to another location. We consider redirect responses to webhook requests as failures.                                                                                    | Set the webhook endpoint destination to the URL resolved by the redirect.                                                        |
| (400) ERR (or other 4xx status)   | The destination server can’t or won’t process the request. This might occur when the server detects an error (400) when the destination URL has access restrictions (401, 403), or when the destination URL doesn’t exist (404). | Make sure that your endpoint is publicly accessible to the internet and make sure that your endpoint accepts a POST HTTP method. |
| (500) ERR (or other 5xx status)   | The destination server encountered an error while processing the request.                                                                                                                                                        | Review your application’s logs to understand why it’s returning a 500 error.                                                     |
| (TLS error) ERR                   | We couldn’t establish a secure connection to the destination server. These errors are usually caused by an issue with the SSL/TLS certificate or an intermediate certificate in the destination server’s certificate chain.      | Perform an [SSL server test](https://www.ssllabs.com/ssltest/) to find issues that might cause this error.                       |
| (Timed out) ERR                   | The destination server took too long to respond to the webhook request.                                                                                                                                                          | Make sure you defer complex logic and return a successful response immediately in your webhook handling code.                    |
