Webhooks

Manage webhook endpoints, read the delivery log, and redeliver an event.

A webhook is an HTTPS endpoint FoPost POSTs signed events to. Subscribing, the event list, and signature verification are covered in the webhooks guide; this page is the endpoint reference, including the delivery log. Everything here needs the webhooks scope.

Endpoints

MethodPathWhat it does
GET/v1/webhooksList the webhooks in your workspaces
POST/v1/webhooksRegister an endpoint. The signing secret is returned once
PUT/v1/webhooks/{id}Change the URL, events, headers, or secret; enable or disable
DELETE/v1/webhooks/{id}Remove it. Deliveries stop immediately. Answers 204
POST/v1/webhooks/{id}/testSend a test post.published payload to this endpoint only. Answers 204
GET/v1/webhooks/{id}/deliveriesThe delivery log, newest first
GET/v1/webhooks/{id}/deliveries/{deliveryId}One attempt, with the payload that was sent
POST/v1/webhooks/{id}/deliveries/{deliveryId}/redeliverSend that delivery again

The delivery log

GET /v1/webhooks/{id}/deliveries
curl "https://api.fopost.com/v1/webhooks/$WEBHOOK_ID/deliveries?status=failed" \
  -H "X-API-Key: $FOPOST_API_KEY"

Every attempt to reach the endpoint is logged, whatever the outcome: the first send, each automatic retry, and each redelivery. Attempts are kept for 30 days.

FieldWhat it holds
eventThe event name, for example post.published
delivery_keyThe X-FoPost-Delivery header value. Every attempt of one event shares it
attempt1 for the first send; retries and redeliveries count up
statussuccess for a 2xx, failed for anything else, a timeout included
response_statusThe HTTP status your endpoint answered, or null when no response arrived
response_snippetUp to 500 characters of the response body, with anything credential-shaped redacted
duration_msHow long the request took
next_retry_atWhen the next automatic retry is due, or null
payload_hashSHA-256 of the body that was sent, for matching against what you received

status=success or status=failed filters the list; limit caps it at up to 200 (default 50).

GET /v1/webhooks/{id}/deliveries/{deliveryId}

The single read adds payload: the body exactly as it was sent, so you can replay it against a local handler.

Redeliver

POST /v1/webhooks/{id}/deliveries/{deliveryId}/redeliver
curl -X POST https://api.fopost.com/v1/webhooks/$WEBHOOK_ID/deliveries/$DELIVERY_ID/redeliver \
  -H "X-API-Key: $FOPOST_API_KEY"

The delivery is sent again with the identical body, so X-FoPost-Signature (the signature over the body) and X-FoPost-Delivery match the original attempt. X-FoPost-Timestamp and X-FoPost-Signature-256 are fresh, because they are what protects you from replays; a handler that verifies the timestamped signature accepts a redelivery the same way it accepts a retry.

A redelivery is one attempt, logged as the next attempt of that delivery, and is not retried automatically. It answers 204 once queued, and 409 with error: "webhook_paused" when the webhook is paused: enable it first. Deduplicate on X-FoPost-Delivery if your handler is not already idempotent.

In the dashboard, the same log and the redeliver action sit on each webhook under Webhooks. The agent can read it too: ask "did my webhook get the post.published event", or ask it to send a delivery again, which it proposes for your approval.

Next

Related documentation
  • API Overview

    Base URL, envelopes, pagination, and errors for the FoPost REST API.

  • Authentication

    API keys, scopes, and workspace binding.

  • Publishing

    Create a post, target accounts, publish it, and read the per-account result.

  • Scheduling

    Schedule a post, repeat it, and import a batch from a spreadsheet.

  • Media

    Upload files, list the media library, and attach media to a post.

  • Validation

    Check content, text length, and media against platform rules before a post exists.

  • Accounts

    List connected social accounts, check their health, and refresh credentials.

  • Workspaces

    Workspaces, labels, and how isolation works across them.

Was this helpful?

On this page