Skip to content
VuloMail
Developers · API v1.0

Everything on this page is the supported surface. The minor version rises when something is added; the major version only on a breaking change. Anything not listed here is internal.

my-plugin/includes/sms.php
function my_plugin_send_sms( $number, $text ) {
	$delegate = function_exists( 'vulomail_send_sms' )
		&& version_compare( vulomail_api_version(), '1.0', '>=' )
		&& vulomail_is_sms_ready()
		&& get_option( 'my_plugin_use_vulomail' ); // your own opt-in

	if ( $delegate ) {
		$sent = vulomail_send_sms( $number, $text, array( 'source' => 'my-plugin' ) );
		if ( true === $sent ) {
			return true;
		}
	}

	return my_plugin_own_gateway()->send( $number, $text );
}

Make it opt-in, send once, and only fall back to your own gateway after VuloMail returns a WP_Error. Check readiness at send time, not at load.

Functions

Five functions. Guard every call.

Wait for vulomail_loaded and wrap calls in function_exists() so your plugin keeps working without VuloMail.

vulomail_api_version()stringe.g. "1.0"
vulomail_is_email_ready()boolA usable email connection exists and routing is on.
vulomail_is_sms_ready()boolA usable SMS connection exists and SMS is on.
vulomail_send_email( array $args )true|WP_Errorto, subject, message required; headers, attachments, source optional.
vulomail_send_sms( $to, $message, $args )true|WP_Errorsource optional. HTML stripped; 1,530 characters max.
Actions

Hear about every outcome.

vulomail_loadedVuloMail has booted
vulomail_email_sentMessage $message, Result $result
vulomail_email_failedEvery connection failed
vulomail_sms_sent$number, $body, Result $result
vulomail_sms_failed$number, $body, Result $result

Core's wp_mail_succeeded and wp_mail_failed also fire for email VuloMail delivers.

Filters

Change what you need.

vulomail_should_handle_emailReturn false to leave one message to WordPress
vulomail_email_messageChange a message before it's sent and logged
vulomail_sms_messageChange an SMS; return '' to cancel it
vulomail_email_providersAdd or replace email adapters
vulomail_sms_providersAdd or replace SMS adapters
vulomail_sms_triggersAdd SMS alert definitions
vulomail_log_dataChange a log row, or return false to skip it
vulomail_diagnosticsAdd rows to Tools → Diagnostics
vulomail_http_timeout · vulomail_smtp_timeoutSeconds; default 15
vulomail_rest_controllersAdd REST controllers
REST · vulomail/v1

Administrators only. Secrets never included.

Every route requires manage_options and, for cookie auth, an X-WP-Nonce header. Secret connection fields always come back masked.

GET/overviewDashboard data for 7, 30 or 90 days
GET · POST/settingsRead or save settings
GET · POST/connectionsList, create or update connections (secrets masked)
DELETE/connections/{id}Remove; a deleted primary is replaced by the backup
GET · DELETE/logsQuery or clear the log
GET/logs/{id}One entry with attempts and headers
POST/logs/{id}/resendResend through current routing
POST/tools/test-email · /tools/test-smsTest through live routing or one connection
GET/tools/diagnosticsEvery check's result

Make it opt-in

Installing VuloMail shouldn't silently change how your plugin delivers. Offer a setting, off by default for existing sites.

Keep your content

Templates, recipients and the decision to send stay in your plugin. VuloMail is only the transport.

One-way dependency

Your plugin calls VuloMail. VuloMail never calls into another plugin. WooCommerce alerts are the one exception.

Ship delivery you don't have to maintain.

Hand your email and SMS to VuloMail when it's present, and keep your own behaviour when it isn't.