Delete connection is a WordPress ability from SureMail — usable via Easy MCP AI, which connects Claude, ChatGPT, and any AI assistant to your site.

Install Free Plugin →

Delete connection

Destructive
SureMail Email & CRM suremails/delete-connection

Permanently deletes an email connection by ID, an action that cannot be undone.

Requires the SureMail plugin installed on WordPress 6.9+ (for Abilities API support). Every ability also requires the current user to have the 'manage_options' capability. Abilities that create, modify, resend, or delete data are additionally gated behind separate site options: the destructive abilities (delete-connection, delete-email-logs) require the 'suremails_abilities_api_delete' option to be enabled, and the write abilities (add-connection, update-connection, send-test-email, resend-email, update-settings) require the 'suremails_abilities_api_edit' option to be enabled.

What it does

This ability permanently removes an email connection and its credentials by ID. If the deleted connection was the site's default sender, the remaining connection with the highest priority automatically becomes the new default; if it was the only connection, the site loses all email-sending capability until a new one is added. Because this is irreversible, the plugin instructs an AI assistant to always confirm the connection title and email with the user before calling it.

See it in action

You ask your AI assistant

"Delete the email connection with ID conn_456 — I no longer need that SMTP account."

Inputs

Name Type Required Description
id string Yes The connection ID to delete. Obtain this from list-connections.

Returns

An object with the deleted connection's id, a result message, and the (possibly reassigned) default_connection object.

Permission

Requires the 'suremails_abilities_api_delete' site option to be enabled, and the current user must have the 'manage_options' capability.

Newsletter

The AI + WordPress space moves fast. Keep up.

New tools, workflow ideas, and product updates — be the first to know what's next.

No spam, unsubscribe anytime.