Skip to content

Delivery Server API Documentation

Delivery server management endpoints for creating, updating, deleting, and retrieving SMTP delivery servers. These endpoints are admin-only and manage the SMTP servers used to send email campaigns.

Create a Delivery Server

POST /api.php

API Usage Notes

  • Authentication required: Admin API Key
  • Legacy endpoint access via /api.php only (no v1 REST alias configured)

Request Body Parameters:

ParameterTypeRequiredDescription
CommandStringYesAPI command: deliveryserver.create
SessionIDStringNoSession ID obtained from login
APIKeyStringNoAPI key for authentication
DeliveryServerNameStringYesName of the delivery server
SendMethodSMTPHostStringYesSMTP server hostname or IP address
SendMethodSMTPPortIntegerYesSMTP server port (e.g., 25, 587, 465)
SendMethodSMTPSecureStringYesSecurity protocol: "false", "ssl", or "tls"
SendMethodSMTPTimeoutIntegerYesConnection timeout in seconds (must be numeric)
SendMethodSMTPAuthBooleanYesWhether SMTP authentication is required: true or false
SendMethodSMTPUsernameStringConditionalSMTP username (required if SendMethodSMTPAuth is true)
SendMethodSMTPPasswordStringNoSMTP password
DomainSettings_LinkTrackingStringYesDomain for link tracking (e.g., "track.example.com")
DomainSettings_OpenTrackingStringYesDomain for open tracking (e.g., "open.example.com")
DomainSettings_MFromStringYesMail From domain (e.g., "bounce.example.com")
DomainSettings_EnforcedFromStringNoEnforced From email address (must be valid email format)
SenderInfoAsMFromStringNoUse sender info as MFrom: "Enabled" or "Disabled" (default: "Disabled")
SenderInfoAsFromStringNoUse sender info as From: "Enabled" or "Disabled" (default: "Disabled")
bash
curl -X POST https://example.com/api.php \
  -H "Content-Type: application/json" \
  -d '{
    "Command": "deliveryserver.create",
    "SessionID": "admin-session-id",
    "DeliveryServerName": "Primary SMTP Server",
    "SendMethodSMTPHost": "smtp.example.com",
    "SendMethodSMTPPort": 587,
    "SendMethodSMTPSecure": "tls",
    "SendMethodSMTPTimeout": 30,
    "SendMethodSMTPAuth": true,
    "SendMethodSMTPUsername": "smtp_user",
    "SendMethodSMTPPassword": "smtp_password",
    "DomainSettings_LinkTracking": "track.example.com",
    "DomainSettings_OpenTracking": "open.example.com",
    "DomainSettings_MFrom": "bounce.example.com",
    "DomainSettings_EnforcedFrom": "noreply@example.com"
  }'
json
{
  "Success": true,
  "ErrorCode": 0,
  "ErrorText": "",
  "DeliveryServerID": 123
}
json
{
  "Success": false,
  "ErrorCode": [1, 2, 3],
  "ErrorText": ["Missing deliveryservername", "Missing sendmethodsmtphost", "Missing sendmethodsmtpport"]
}
txt
0: Success
1: Missing deliveryservername
2: Missing sendmethodsmtphost
3: Missing sendmethodsmtpport
4: Missing sendmethodsmtpsecure
5: Missing sendmethodsmtptimeout
6: Missing sendmethodsmtpauth
7: Missing sendmethodsmtpusername
8: Missing sendmethodsmtppassword
9: Missing domainsettings_linktracking
10: Missing domainsettings_opentracking
11: Missing domainsettings_mfrom
12: Missing domainsettings_enforcedfrom
13: Invalid sendmethodsmtpsecure value (must be: false, ssl, tls)
14: Invalid sendmethodsmtpauth value (must be: true, false)
15: Invalid sendmethodsmtptimeout value (must be numeric)
16: Invalid email address value for domainsettings_enforcedfrom

Save Delivery Server Test Results

POST /api.php

API Usage Notes

  • Authentication required: Admin API Key
  • Legacy endpoint access via /api.php only (no v1 REST alias configured)

Request Body Parameters:

ParameterTypeRequiredDescription
CommandStringYesAPI command: deliveryserver.testresults
SessionIDStringNoSession ID obtained from login
APIKeyStringNoAPI key for authentication
DeliveryServerIDIntegerYesID of the delivery server
TestResultsObjectYesVerification test results object
TestResults.SPFBooleanYesSPF record verification result
TestResults.DKIMBooleanYesDKIM record verification result
TestResults.DMARCBooleanYesDMARC record verification result
TestResults.SenderDomainBooleanYesSender domain verification result
TestResults.LinkDomainBooleanYesLink tracking domain verification result
TestResults.OpenDomainBooleanYesOpen tracking domain verification result
TestResults.EmailDeliveryBooleanYesEmail delivery test result
LastCheckedAtStringYesLast verification timestamp (format: "YYYY-MM-DD HH:MM:SS")
bash
curl -X POST https://example.com/api.php \
  -H "Content-Type: application/json" \
  -d '{
    "Command": "deliveryserver.testresults",
    "SessionID": "admin-session-id",
    "DeliveryServerID": 123,
    "TestResults": {
      "SPF": true,
      "DKIM": true,
      "DMARC": true,
      "SenderDomain": true,
      "LinkDomain": true,
      "OpenDomain": true,
      "EmailDelivery": true
    },
    "LastCheckedAt": "2025-12-28 10:30:00"
  }'
json
{
  "Success": true,
  "ErrorCode": 0,
  "ErrorText": ""
}
json
{
  "Success": false,
  "ErrorCode": [1, 3],
  "ErrorText": ["Missing deliveryserverid", "Invalid deliveryserverid"]
}
txt
0: Success
1: Missing deliveryserverid
2: Missing test_results
3: Invalid deliveryserverid
4: Missing last_checked_at

Update a Delivery Server

POST /api.php

API Usage Notes

  • Authentication required: Admin API Key
  • Legacy endpoint access via /api.php only (no v1 REST alias configured)

Request Body Parameters:

ParameterTypeRequiredDescription
CommandStringYesAPI command: deliveryserver.update
SessionIDStringNoSession ID obtained from login
APIKeyStringNoAPI key for authentication
DeliveryServerIDIntegerYesID of the delivery server to update
DeliveryServerNameStringYesName of the delivery server
SendMethodSMTPHostStringYesSMTP server hostname or IP address
SendMethodSMTPPortIntegerYesSMTP server port (e.g., 25, 587, 465)
SendMethodSMTPSecureStringYesSecurity protocol: "false", "ssl", or "tls"
SendMethodSMTPTimeoutIntegerYesConnection timeout in seconds (must be numeric)
SendMethodSMTPAuthBooleanYesWhether SMTP authentication is required: true or false
SendMethodSMTPUsernameStringConditionalSMTP username (required if SendMethodSMTPAuth is true)
SendMethodSMTPPasswordStringNoSMTP password
DomainSettings_LinkTrackingStringYesDomain for link tracking (e.g., "track.example.com")
DomainSettings_OpenTrackingStringYesDomain for open tracking (e.g., "open.example.com")
DomainSettings_MFromStringYesMail From domain (e.g., "bounce.example.com")
DomainSettings_EnforcedFromStringNoEnforced From email address (must be valid email format)
SenderRotationSettingsStringNoSender rotation configuration
SenderInfoAsMFromStringNoUse sender info as MFrom: "Enabled" or "Disabled"
SenderInfoAsFromStringNoUse sender info as From: "Enabled" or "Disabled"
SenderRotationStringNoEnable sender rotation: "Enabled" or "Disabled"
bash
curl -X POST https://example.com/api.php \
  -H "Content-Type: application/json" \
  -d '{
    "Command": "deliveryserver.update",
    "SessionID": "admin-session-id",
    "DeliveryServerID": 123,
    "DeliveryServerName": "Updated SMTP Server",
    "SendMethodSMTPHost": "smtp2.example.com",
    "SendMethodSMTPPort": 587,
    "SendMethodSMTPSecure": "tls",
    "SendMethodSMTPTimeout": 30,
    "SendMethodSMTPAuth": true,
    "SendMethodSMTPUsername": "new_user",
    "SendMethodSMTPPassword": "new_password",
    "DomainSettings_LinkTracking": "track.example.com",
    "DomainSettings_OpenTracking": "open.example.com",
    "DomainSettings_MFrom": "bounce.example.com",
    "SenderRotation": "Enabled"
  }'
json
{
  "Success": true,
  "ErrorCode": 0,
  "ErrorText": "",
  "DeliveryServerID": 123
}
json
{
  "Success": false,
  "ErrorCode": [17],
  "ErrorText": ["Delivery server not found"]
}
txt
0: Success
1: Missing deliveryservername
2: Missing sendmethodsmtphost
3: Missing sendmethodsmtpport
4: Missing sendmethodsmtpsecure
5: Missing sendmethodsmtptimeout
6: Missing sendmethodsmtpauth
7: Missing sendmethodsmtpusername
8: Missing sendmethodsmtppassword
9: Missing domainsettings_linktracking
10: Missing domainsettings_opentracking
11: Missing domainsettings_mfrom
12: Missing domainsettings_enforcedfrom
13: Invalid sendmethodsmtpsecure value (must be: false, ssl, tls)
14: Invalid sendmethodsmtpauth value (must be: true, false)
15: Invalid sendmethodsmtptimeout value (must be numeric)
16: Invalid email address value for domainsettings_enforcedfrom
17: Delivery server not found

Delete Delivery Servers

POST /api.php

API Usage Notes

  • Authentication required: Admin API Key
  • Legacy endpoint access via /api.php only (no v1 REST alias configured)

Request Body Parameters:

ParameterTypeRequiredDescription
CommandStringYesAPI command: deliveryservers.delete
SessionIDStringNoSession ID obtained from login
APIKeyStringNoAPI key for authentication
DeliveryServerIDStringYesComma-separated list of delivery server IDs to delete (e.g., "123,456,789")
bash
curl -X POST https://example.com/api.php \
  -H "Content-Type: application/json" \
  -d '{
    "Command": "deliveryservers.delete",
    "SessionID": "admin-session-id",
    "DeliveryServerID": "123,456"
  }'
json
{
  "Success": true,
  "ErrorCode": 0
}
json
{
  "Success": false,
  "ErrorCode": [1]
}
txt
0: Success
1: Missing deliveryserverid

Get Delivery Servers

POST /api.php

API Usage Notes

  • Authentication required: Admin API Key
  • Legacy endpoint access via /api.php only (no v1 REST alias configured)

Request Body Parameters:

ParameterTypeRequiredDescription
CommandStringYesAPI command: deliveryservers.get
SessionIDStringNoSession ID obtained from login
APIKeyStringNoAPI key for authentication
bash
curl -X POST https://example.com/api.php \
  -H "Content-Type: application/json" \
  -d '{
    "Command": "deliveryservers.get",
    "SessionID": "admin-session-id"
  }'
json
{
  "Success": true,
  "ErrorCode": 0,
  "DeliveryServers": {
    "123": {
      "DeliveryServerID": "123",
      "Name": "Primary SMTP Server",
      "ConnectionParams": {
        "smtp_host": "smtp.example.com",
        "smtp_port": 587,
        "smtp_secure": "tls",
        "smtp_timeout": 30,
        "smtp_auth": true,
        "smtp_username": "smtp_user",
        "smtp_password": "smtp_password"
      },
      "Domains": {
        "link_tracking": "track.example.com",
        "open_tracking": "open.example.com",
        "mfrom_domain": "bounce.example.com",
        "enforced_from": "noreply@example.com",
        "senderinfo_as_mfrom": false,
        "senderinfo_as_from": false
      },
      "VerificationResults": {
        "email_delivery": true,
        "spf": true,
        "dkim": true,
        "dmarc": true,
        "sender_domain": true,
        "link_domain": true,
        "open_domain": true
      },
      "VerificationLastCheckedAt": "2025-12-28 10:30:00"
    }
  }
}
json
{
  "Success": false,
  "ErrorCode": 2
}
txt
0: Success
2: No delivery servers found

Any questions? Contact us.