Akismet
4 hooks fired by Akismet: 3 filters and 1 actions across 4 call sites.
4 hooks fired by Akismet: 3 filters and 1 actions across 4 call sites. 4 of the 4 call sites are described by a docblock, at the call or on the constant that names the hook; the rest are listed with their signature and call sites only. Paths are relative to the plugin directory.
xpac_akismet_comment_check_data
Filter · 2 arguments · 1 call site
Filters the payload posted to Akismet's comment-check endpoint.
comment_content carries eligible declared answers except the four the form's field map relocates. Password and confirmation values are already absent. This is the seam for withholding another field from the classifier: unset the key and it does not leave the site. Removing api_key or comment_content leaves the request unanswerable, so the check fails closed and the submission is quarantined.
apply_filters( 'xpac_akismet_comment_check_data', $data, $externalSubmission )$data(array) — The request body, keyed as Akismet names its fields.$submission(Submission) — A callback-safe copy without write-only answers.
Fired from:
packages/Akismet/Addon.php:581
xpac_akismet_missing_api_key
Action · 1 argument · 1 call site
Fires when a form asked for an Akismet check and no key answered.
The protected submission fails closed and is quarantined. The callback receives a copy without password, confirmation, or undeclared request values.
do_action( 'xpac_akismet_missing_api_key', $externalSubmission )$submission(Submission) — Redacted submission copy.
Fired from:
packages/Akismet/Addon.php:458
xpac_akismet_request_timeout
Filter · 2 arguments · 1 call site
Filters the timeout, in seconds, of the Akismet comment-check request.
The call is synchronous and the visitor is waiting on it, so this is also the longest one attempt can hold a submission. The value is clamped to 1–30 seconds. A fast transport failure is retried once, so the worst case is roughly twice what this returns.
apply_filters( 'xpac_akismet_request_timeout', 15.0, $data )$timeout(float) — Timeout in seconds. Default 15.$data(array) — The request body about to be posted.
Fired from:
packages/Akismet/Addon.php:668
xpac_forms_enable_verification
Filter · 3 arguments · 1 call site
Filters whether an anti-spam provider runs its check for this submission.
Evaluated only after the form's own toggle for the provider is already
on, because the call is the right operand of a short-circuiting &&.
Returning true therefore cannot switch on a check the form has turned
off; returning false skips the check, leaving the validation result
exactly as the preceding filters left it.
Each provider passes its own slug as the third argument, so a callback can disable one without touching the others. The slugs in use are "akismet" (this call site), "google-recaptcha" and "cloudflare-captcha". Forms' built-in Honeypot check never fires this filter and so cannot be disabled through it.
apply_filters( 'xpac_forms_enable_verification', true, $externalSubmission, 'akismet' )$enable(bool) — Whether to run the provider's check. Default true.$submission(Submission) — A callback-safe copy without write-only answers.$provider(string) — Slug of the provider asking. Always "akismet" here.
Fired from:
packages/Akismet/Addon.php:489