View and manage your MailBaby mail service orders.
All URIs are relative to https://api.mailbaby.net, except if the operation defines another base path.
| Method | HTTP request | Description |
|---|---|---|
| getMailOrderById() | GET /mail/{id} | Displays details for a single mail order |
| getMailOrders() | GET /mail | Displays a list of mail service orders |
getMailOrderById($id): \Interserver\Mailbaby\Model\MailOrderDetailDisplays details for a single mail order
Returns the full detail record for one specific mail order identified by its numeric id. In addition to the fields returned by GET /mail, this endpoint also includes the current SMTP password for the order. The username and password values returned here can be used directly to authenticate against relay.mailbaby.net:25 (SMTP AUTH) if you need to send email via a native SMTP client rather than through the REST API. The id path parameter is the same integer id value returned by GET /mail.
<?php
require_once(__DIR__ . '/vendor/autoload.php');
// Configure API key authorization: apiKeyAuth
$config = Interserver\Mailbaby\Configuration::getDefaultConfiguration()->setApiKey('X-API-KEY', 'YOUR_API_KEY');
// Uncomment below to setup prefix (e.g. Bearer) for API key, if needed
// $config = Interserver\Mailbaby\Configuration::getDefaultConfiguration()->setApiKeyPrefix('X-API-KEY', 'Bearer');
$apiInstance = new Interserver\Mailbaby\Api\ServicesApi(
// If you want use custom http client, pass your client which implements `GuzzleHttp\ClientInterface`.
// This is optional, `GuzzleHttp\Client` will be used as default.
new GuzzleHttp\Client(),
$config
);
$id = 39; // int | The numeric ID of the mail order.
try {
$result = $apiInstance->getMailOrderById($id);
print_r($result);
} catch (Exception $e) {
echo 'Exception when calling ServicesApi->getMailOrderById: ', $e->getMessage(), PHP_EOL;
}| Name | Type | Description | Notes |
|---|---|---|---|
| id | int | The numeric ID of the mail order. |
\Interserver\Mailbaby\Model\MailOrderDetail
- Content-Type: Not defined
- Accept:
application/json
[Back to top] [Back to API list] [Back to Model list] [Back to README]
getMailOrders(): \Interserver\Mailbaby\Model\MailOrder[]Displays a list of mail service orders
Returns every mail order (active and inactive) associated with your account. Each record includes the numeric id, the status (active or canceled), the SMTP username (always mb<id>), and an optional human-readable comment. The id values returned here are used as the id input parameter on all sending endpoints (/mail/send, /mail/advsend, /mail/rawsend) as well as the log and stats queries. When the id parameter is omitted on those calls the API automatically picks the first active order returned by this endpoint. To retrieve full details — including the current SMTP password — for a single order use GET /mail/{id}.
<?php
require_once(__DIR__ . '/vendor/autoload.php');
// Configure API key authorization: apiKeyAuth
$config = Interserver\Mailbaby\Configuration::getDefaultConfiguration()->setApiKey('X-API-KEY', 'YOUR_API_KEY');
// Uncomment below to setup prefix (e.g. Bearer) for API key, if needed
// $config = Interserver\Mailbaby\Configuration::getDefaultConfiguration()->setApiKeyPrefix('X-API-KEY', 'Bearer');
$apiInstance = new Interserver\Mailbaby\Api\ServicesApi(
// If you want use custom http client, pass your client which implements `GuzzleHttp\ClientInterface`.
// This is optional, `GuzzleHttp\Client` will be used as default.
new GuzzleHttp\Client(),
$config
);
try {
$result = $apiInstance->getMailOrders();
print_r($result);
} catch (Exception $e) {
echo 'Exception when calling ServicesApi->getMailOrders: ', $e->getMessage(), PHP_EOL;
}This endpoint does not need any parameter.
\Interserver\Mailbaby\Model\MailOrder[]
- Content-Type: Not defined
- Accept:
application/json
[Back to top] [Back to API list] [Back to Model list] [Back to README]