Get Debug Events is a WordPress ability from WP Mail SMTP — usable via Easy MCP AI, which connects Claude, ChatGPT, and any AI assistant to your site.
Install Free Plugin →Get Debug Events
Read-onlyList recorded WP Mail SMTP debug events — the errors and debug entries logged when the site attempts to send email.
Requires the WP Mail SMTP plugin on WordPress 6.9+ for the Abilities API (the registrar only registers abilities when wp_register_ability() and wp_register_ability_category() exist). The ability is additionally gated on the caller holding the plugin's manage-options capability (manage_options by default, filterable via wp_mail_smtp_core_get_capability_manage_options), the same capability that guards the Debug Events admin screen.
What it does
This ability lists the debug events WP Mail SMTP has recorded — every logged error and debug entry generated while the site attempted to send mail through its configured SMTP connection or provider (SendGrid, Mailgun, SES, Gmail, Outlook, Zoho, etc). Each returned event has an id, a created_date, a severity of either 'error' or 'debug', and the event's content text. You can filter to just errors or just debug entries with severity, and page through results with limit and offset. This is the same data shown on the plugin's Debug Events admin screen, so giving an AI assistant this ability lets it diagnose 'why isn't email sending?' style questions directly from a conversation — pulling the latest failures, spotting a recurring SMTP auth error, or confirming whether a fix actually stopped new errors from appearing — without the user opening WP Mail SMTP's dashboard.
See it in action
You ask your AI assistant
"Show me the last 10 error-severity debug events from WP Mail SMTP — I want to see what's been failing with our outgoing email."
Inputs
| Name | Type | Required | Description |
|---|---|---|---|
| limit | integer | No | Maximum number of events to return (1-100). Defaults to 20. |
| offset | integer | No | Number of events to skip. Defaults to 0. |
| severity | string | No | Filter events by severity: error or debug. Omit to return both. |
Returns
An object with an 'events' array (each with id, created_date in ISO 8601 UTC, severity, and content) plus 'total', 'limit', and 'offset' fields describing the page of results returned.
Permission
The current user must have the WP Mail SMTP manage-options capability (manage_options by default, filterable via wp_mail_smtp_core_get_capability_manage_options) — the same capability that gates the plugin's Debug Events admin screen.