-
Notifications
You must be signed in to change notification settings - Fork 12
Developer API
objectivehtml edited this page Dec 8, 2014
·
36 revisions
****Developers can take complete control of Postmaster and harness the power of its underlying API's. The following are the API's current available to developers.
Before you can use your classes in Postmaster you must register them.
// Register multiple services at once
craft()->postmaster->registerServices(array(
'Craft\FooService',
'Craft\YourService',
));
// One service at a time
craft()->postmaster->registerService('Craft\FooService');
// Register multiple parcel types at once
craft()->postmaster->registerParcelTypes(array(
'Craft\FooParcelType',
'Craft\YourParcelType',
));
// One parcel type at a time
craft()->postmaster->registerParcelType('Craft\FooParcelType');
The