Files
piratepoet/doc
Rodrigo Primo e64ba70561 Remove minimum required PHP version
This commit removes a reference to the minimum required PHP version (which is presumably outdated as it mentions PHP 5.6) from the MailPoet API documentation.

I'm assuming that the minimum required version to use the API is the same as the one to run MailPoet. If that is the case, I don't see a reason to mention it in the API documentation, and removing it has the benefit of reducing the maintenance burden when the minimum required version is updated.
2021-01-18 12:28:50 +01:00
..
2021-01-18 12:28:50 +01:00
2020-03-24 14:12:49 +01:00

MailPoet 3 - Documentation for Integrators

This is a place where we put documentation for developers who want to build an extension for MailPoet 3 plugin. If you are a user looking for a user guide please visit our knowledge base.

MailPoet API

MailPoet API is the officially supported way to integrate with the MailPoet 3 plugin. It focuses on functionality for managing subscribers. Developers integrating MailPoet functionality in their own plugins or projects are strongly discouraged against using other functions and classes within MailPoet codebase! We are continually refactoring as part of our rapid development process, and backward compatibility is not guaranteed.

Basics

MailPoet API is distributed within MailPoet3 plugin and it is implemented as a PHP class. Currently supported version is v1.

Instantiation

if (class_exists(\MailPoet\API\API::class)) {
  $mailpoet_api = \MailPoet\API\API::MP('v1');
}

Class \MailPoet\API\API becomes available once MailPoet plugin is loaded by WordPress.

Available API Methods

Usage examples

You can check some basic examples here.