WP Webhooks / Docs / fswa_error
Action since v1.0.0

fswa_error

Fires after a failed delivery attempt — an HTTP error response, a transport error, or a vault credential that could not be decrypted.

$

/ Signature

do_action( 'fswa_error', $trigger, $url, $error )

/ When it fires

Fires once per failed attempt — the inline synchronous attempt, every queued attempt and retry, and test sends — after the attempt is logged and before the retry decision is made. Any non-2xx status counts (3xx, 4xx, 5xx). It does not fire when the URL fails validation (invalid, or not HTTPS) or when conditions skip the delivery. It carries no payload, response or attempt number: for those, listen on fswa_delivery_event (failed_attempt / permanently_failed).

/ Parameters

NameInTypeReqDescription
$triggerparamstringyesWordPress action name.
$urlparamstringyesEndpoint URL of the attempt, after `fswa_webhook_url`; on HTTP and transport failures it also carries any configured query parameters.
$errorparamstringyesA short error message: `HTTP 503` for an error response, the `WP_Error` message for a transport failure (connection refused, timeout, SSL), or `Credential could not be decrypted.`

/ Examples

Log every failed delivery attempt

add_action( 'fswa_error', function ( $trigger, $url, $error ) {
    error_log( "[fswa] Delivery failed: {$trigger} → {$url} ({$error})" );
}, 10, 3 );

/ Related

Ready

Your next automation is
one sentence away.

$ wp plugin install flowsystems-webhook-actions --activate