You can mark your webhook events as processed in bulk or individually.
- Bulk: Return HTTP status code 200 to consider all received events as successfully processed.
- Individual: Return HTTP status code 202 to apply an additional requirement for processed orders. Add the ID number of the event you would like to process. In a new line, repeat as necessary.
All other HTTP status codes are marked as failures. We recommend returning failed status codes in the 50X range, depending on the cause of the failure.
If a webhook event is not marked as processed, FastSpring automatically attempts to repost the event every 10 minutes for 24 hours, or until it is processed successfully. This corresponds with the “Failed but will be retried” status on the Webhook Log.
If the event is not marked as processed within 24 hours, FastSpring discontinues attempts to repost the webhook event. This corresponds with the “Permanently Failed” status on the Webhook Log.
However, you can still retrieve permanently failed events from the /events API endpoint. A red tag labeled Failed in last 24 hours appears on the card of the affected webhook event. The tag disappears when there are no failed events in the past 24 hours.
If your server does not process an event successfully, you can retrieve it any of these ways:
- Resend it manually from the Webhook Log. Go to Developer Tools > Webhooks > Log.
- Resend it manually from the order’s details page.
- Resend it manually from the subscription’s details page.
- Make a GET call to the /events/unprocessed endpoint.
After you process the missed events, mark the events as processed with a POST to the /events endpoint. This way, they will not return with future unprocessed events.
We recommend setting up an automatically scheduled task to automatically retrieve missed webhook events. After parsing the events, the script should mark them as processed.