Skip to content

List API Documentation

List management endpoints for creating, updating, and managing email subscriber lists and their integration settings.

Create a List

POST /api.php

API Usage Notes

  • Authentication required: User API Key
  • Required permissions: List.Create
  • Legacy endpoint access via /api.php only (no v1 REST alias configured)
  • The endpoint is additive and backwards-compatible. Callers passing only SubscriberListName continue to receive the original response shape (no ConfirmationEmailID field present).

Request Body Parameters:

ParameterTypeRequiredDescription
CommandStringYesAPI command: list.create
SessionIDStringNoSession ID obtained from login
APIKeyStringNoAPI key for authentication
SubscriberListNameStringYesName of the subscriber list to create
DescriptionStringNoOptional human-readable description for the list
OptInModeStringNoSingle (default) or Double. Auto-promoted to Double when ConfirmationEmail is supplied or when the user group has ForceOptInList enabled.
SenderNameStringNoList-level default sender name
SenderEmailAddressStringNoList-level default sender email address
SenderCompanyStringNoList-level default sender company
SenderAddressStringNoList-level default sender postal address
ConfirmationEmailObjectNoOptional confirmation-email block. When supplied, the handler atomically creates the email row, links it to the list via RelOptInConfirmationEmailID, and returns the new ConfirmationEmailID in the response. OptInMode is auto-promoted to Double. See sub-fields below. Sending this key with an empty object/array opts you into the bundled flow and surfaces a missing-required-field error — it does NOT silently fall back to the legacy single-parameter behavior.

ConfirmationEmail sub-fields:

Sub-fieldTypeRequired When PresentDescription
SubjectStringYesEmail subject line
FromNameStringYesSender name
FromEmailStringYesSender email address
ContentTypeStringYesOne of HTML, Plain, or Both
HTMLContentStringYes when ContentType is HTML or BothHTML body
PlainContentStringYes when ContentType is Plain or BothPlain-text body
ReplyToNameStringNoReply-to display name
ReplyToEmailStringNoReply-to email address
PreHeaderTextStringNoInbox preview text
EmailNameStringNoInternal email label. Defaults to Confirmation email: {ListID}
ModeStringNoOne of Editor, Stripo, Unlayer, Empty, Template, Import. Defaults to Empty.
RelTemplateIDIntegerRequired when Mode is TemplateExisting email-template ID to base the confirmation email on.

Atomicity: When the bundled path is used and any step fails (validation, email creation, link update), the handler rolls back: it deletes the new email row, deletes the new list row, and drops the dynamic oempro_subscribers_<ListID> table. The caller sees an error response with no orphaned rows.

bash
curl -X POST https://example.com/api.php \
  -H "Content-Type: application/json" \
  -d '{
    "Command": "list.create",
    "SessionID": "your-session-id",
    "SubscriberListName": "My New List",
    "Description": "Customers who signed up via the spring 2026 promotion"
  }'
bash
curl -X POST https://example.com/api.php \
  -H "Content-Type: application/json" \
  -d '{
    "Command": "list.create",
    "SessionID": "your-session-id",
    "SubscriberListName": "Newsletter — Double Opt-In",
    "Description": "Subscribers who must confirm via email before receiving campaigns",
    "OptInMode": "Double",
    "SenderName": "Acme Marketing",
    "SenderEmailAddress": "marketing@acme.example",
    "SenderCompany": "Acme Inc.",
    "SenderAddress": "123 Main St, Anytown",
    "ConfirmationEmail": {
      "Subject": "Please confirm your subscription",
      "FromName": "Acme Marketing",
      "FromEmail": "marketing@acme.example",
      "ContentType": "Both",
      "HTMLContent": "<p>Hi, click <a href=\"%Link:Confirm%\">here</a> to confirm.</p>",
      "PlainContent": "Hi, click %Link:Confirm% to confirm your subscription.",
      "PreHeaderText": "Confirm your newsletter signup",
      "Mode": "Editor"
    }
  }'
json
{
  "Success": true,
  "ErrorCode": 0,
  "ErrorText": "",
  "ListID": 123
}
json
{
  "Success": true,
  "ErrorCode": 0,
  "ErrorText": "",
  "ListID": 124,
  "ConfirmationEmailID": 567
}
json
{
  "Success": false,
  "ErrorCode": [1, 3]
}
txt
0:  Success
1:  Missing subscriber list name
3:  User has exceeded maximum number of subscriber lists allowed by their user group
20: Invalid optinmode (must be Single or Double)
21: Missing required confirmationemail sub-field (subject, fromname, fromemail, or contenttype)
22: Invalid confirmationemail.contenttype (must be HTML, Plain, or Both)
23: confirmationemail.htmlcontent is required when contenttype is HTML or Both
24: confirmationemail.plaincontent is required when contenttype is Plain or Both
25: Invalid confirmationemail.mode (must be Editor, Stripo, Unlayer, Empty, Template, or Import)
26: confirmationemail.reltemplateid is required when confirmationemail.mode is Template
30: Confirmation email creation failed; list and email were rolled back

Get a List

POST /api.php

API Usage Notes

  • Authentication required: User API Key
  • Required permissions: List.Get
  • Legacy endpoint access via /api.php only (no v1 REST alias configured)

Request Body Parameters:

ParameterTypeRequiredDescription
CommandStringYesAPI command: list.get
SessionIDStringNoSession ID obtained from login
APIKeyStringNoAPI key for authentication
ListIDIntegerYesID of the list to retrieve
GetStatsBooleanNoWhether to include statistics (default: false)
bash
curl -X POST https://example.com/api.php \
  -H "Content-Type: application/json" \
  -d '{
    "Command": "list.get",
    "SessionID": "your-session-id",
    "ListID": 123,
    "GetStats": true
  }'
json
{
  "Success": true,
  "ErrorCode": 0,
  "List": {
    "ListID": 123,
    "Name": "My List",
    "RelOwnerUserID": 1,
    "EventListTrackerID": "abc123",
    "EventUserTrackerID": "xyz789",
    "EventTrackerVariables": {},
    "EventTrackerJS": "...",
    "EventTrackerProperties": [],
    "LastEventTrackedAt": "2024-01-15 10:30:00"
  }
}
json
{
  "Success": false,
  "ErrorCode": [1]
}
txt
0: Success
1: Missing list ID

Update a List

POST /api.php

API Usage Notes

  • Authentication required: User API Key
  • Required permissions: List.Update
  • Legacy endpoint access via /api.php only (no v1 REST alias configured)

Request Body Parameters:

ParameterTypeRequiredDescription
CommandStringYesAPI command: list.update
SessionIDStringNoSession ID obtained from login
APIKeyStringNoAPI key for authentication
SubscriberListIDIntegerYesID of the list to update
NameStringNoNew name for the list
DescriptionStringNoDescription for the list. Pass an empty string to clear it.
SenderNameStringNoDefault sender name for campaigns
SenderEmailAddressStringNoDefault sender email address
SenderCompanyStringNoSender company name
SenderAddressStringNoSender physical address
OptInModeStringNoOpt-in mode: "Single" or "Double"
OptInConfirmationEmailIDIntegerNoEmail ID for double opt-in confirmation
OptOutAddToSuppressionListStringNoAdd to list suppression list on unsubscribe: "Yes" or "No"
OptOutAddToGlobalSuppressionListStringNoAdd to global suppression list on unsubscribe: "Yes" or "No"
HideInSubscriberAreaStringNoHide list in subscriber area: "true" or "false"
SendServiceIntegrationFailedNotificationStringNoSend integration failure notifications: "true" or "false"
SendActivityNotificationStringNoSend activity notifications: "true" or "false"
SubscriptionConfirmationPendingPageURLStringNoURL for confirmation pending page
SubscriptionConfirmedPageURLStringNoURL for subscription confirmed page
SubscriptionErrorPageURLStringNoURL for subscription error page
UnsubscriptionConfirmedPageURLStringNoURL for unsubscription confirmed page
UnsubscriptionErrorPageURLStringNoURL for unsubscription error page
ReqByEmailSearchToAddressStringNoEmail address for subscription by email requests
ReqByEmailSubscriptionCommandStringNoCommand word for email subscription requests
ReqByEmailUnsubscriptionCommandStringNoCommand word for email unsubscription requests
SyncStatusStringNoData sync status: "Enabled" or "Disabled"
SyncPeriodStringNoSynchronization period
SyncSendReportEmailStringNoSend sync report emails: "Yes" or "No"
SyncMySQLHostStringNoMySQL host for data synchronization
SyncMySQLPortIntegerNoMySQL port for data synchronization
SyncMySQLUsernameStringNoMySQL username for sync
SyncMySQLPasswordStringNoMySQL password for sync
SyncMySQLDBNameStringNoMySQL database name for sync
SyncMySQLQueryStringNoSQL query for data synchronization
SyncFieldMappingStringNoField mapping configuration for sync
OptOutScopeStringNoUnsubscription scope: "This list" or "All lists"
OptOutSubscribeToIntegerNoList ID to subscribe to on unsubscription
OptOutUnsubscribeFromIntegerNoList ID to unsubscribe from on unsubscription
OptInSubscribeToIntegerNoList ID to subscribe to on subscription
OptInUnsubscribeFromIntegerNoList ID to unsubscribe from on subscription
OptionsObjectNoAdditional list options (JSON object). Supported keys: DoNotSendEmailCampaignIfRecipientIsEnrolledInJourneyOrAutoresponder (Boolean), PlainEmailHeader (String), PlainEmailFooter (String), HTMLEmailHeader (String), HTMLEmailFooter (String). Inner keys are matched case-insensitively, but values are always persisted under the canonical CamelCase keys shown here. Partial updates merge with the row's existing Options — keys you don't include in the payload are preserved. Email header/footer options override user-level settings for emails sent to this list.
bash
curl -X POST https://example.com/api.php \
  -H "Content-Type: application/json" \
  -d '{
    "Command": "list.update",
    "SessionID": "your-session-id",
    "SubscriberListID": 123,
    "Name": "Updated List Name",
    "OptInMode": "Double",
    "SenderName": "My Company",
    "SenderEmailAddress": "sender@example.com"
  }'
json
{
  "Success": true,
  "ErrorCode": 0,
  "ErrorText": "",
  "List": {
    "ListID": 123,
    "Name": "Updated List Name",
    "OptInMode": "Double",
    "SenderName": "My Company",
    "SenderEmailAddress": "sender@example.com"
  }
}
json
{
  "Success": false,
  "ErrorCode": [1, 2, 3, 4]
}
txt
0: Success
1: Missing subscriber list ID
2: Invalid subscriber list ID
3: Invalid opt-in mode
4: Invalid opt-out scope
5: Invalid send notification setting
6: Invalid hide in subscriber area setting
8: Missing sync configuration parameters
9: Invalid email address format for ReqByEmailSearchToAddress
10: Invalid suppression list option
11: Nothing to update

Archive a List

POST /api.php

API Usage Notes

  • Authentication required: User API Key
  • Required permissions: List.Update
  • Legacy endpoint access via /api.php only (no v1 REST alias configured)

Marks a list as archived by setting its ArchivedAt timestamp. Archived lists are hidden from lists.get by default (use Archived=true or Archived=all to retrieve them). Idempotent: re-archiving a list keeps the original ArchivedAt timestamp untouched.

Request Body Parameters:

ParameterTypeRequiredDescription
CommandStringYesAPI command: list.archive
SessionIDStringNoSession ID obtained from login
APIKeyStringNoAPI key for authentication
SubscriberListIDIntegerYesID of the list to archive
bash
curl -X POST https://example.com/api.php \
  -H "Content-Type: application/json" \
  -d '{
    "Command": "list.archive",
    "SessionID": "your-session-id",
    "SubscriberListID": 123
  }'
json
{
  "Success": true,
  "ErrorCode": 0,
  "ErrorText": ""
}
json
{
  "Success": false,
  "ErrorCode": [2],
  "ErrorText": ["Invalid subscriber list id"]
}
txt
0: Success
1: Missing subscriber list id
2: Invalid subscriber list id (not found or not owned by the authenticated user)

Unarchive a List

POST /api.php

API Usage Notes

  • Authentication required: User API Key
  • Required permissions: List.Update
  • Legacy endpoint access via /api.php only (no v1 REST alias configured)

Clears the ArchivedAt timestamp on a list, restoring it to active state.

Request Body Parameters:

ParameterTypeRequiredDescription
CommandStringYesAPI command: list.unarchive
SessionIDStringNoSession ID obtained from login
APIKeyStringNoAPI key for authentication
SubscriberListIDIntegerYesID of the list to unarchive
bash
curl -X POST https://example.com/api.php \
  -H "Content-Type: application/json" \
  -d '{
    "Command": "list.unarchive",
    "SessionID": "your-session-id",
    "SubscriberListID": 123
  }'
json
{
  "Success": true,
  "ErrorCode": 0,
  "ErrorText": ""
}
json
{
  "Success": false,
  "ErrorCode": [2],
  "ErrorText": ["Invalid subscriber list id"]
}
txt
0: Success
1: Missing subscriber list id
2: Invalid subscriber list id (not found or not owned by the authenticated user)

Clone a List

POST /api/v1/list.clone

API Usage Notes

  • Authentication required: User API Key
  • Required permissions: List.Create
  • Legacy endpoint access via /api.php is also supported

Duplicates an existing subscriber list, including its full custom-field schema. The new list is seeded from every settings column on the source row except identity, denormalized counters, and the confirmation-email link.

What is cloned

  • All list configuration columns (sender info, sync settings, opt-out behavior, redirection URLs, etc.).
  • All custom fields on the source list, with the complete column set (including Option1Option5, MergeTagAlias, and Meta). Set IncludeCustomFields=false to skip custom-field replication.

What is not cloned

  • ListID, CreatedOn, LastActivityAt, ArchivedAt (auto-managed).
  • ActiveSubscriberCount, SegmentCount (denormalized counters; the new list starts empty).
  • RelOptInConfirmationEmailID (left unset on the new list — call list.update afterwards if you need to attach a confirmation email).
  • Subscribers (the new list's subscriber table is created empty).

OptInMode is carried over from the source list. If the user's group has ForceOptInList=Enabled, OptInMode is overridden to Double, matching list.create.

Atomicity

If any custom-field replication fails, the new list is deleted (along with its dynamic subscribers and tags tables) and ErrorCode: [4] is returned. When IncludeCustomFields=false, the call degenerates to a single list creation with no rollback path.

Plug-in hook

Plugins::HookListener('Action', 'List.Create.Post', ...) fires for the new list with the same payload shape as list.create.

Request Body Parameters:

ParameterTypeRequiredDescription
CommandStringYesAPI command: list.clone
SessionIDStringNoSession ID obtained from login
APIKeyStringNoAPI key for authentication
SubscriberListIDIntegerYesID of the source list to clone
NameStringYesName for the new (cloned) list
IncludeCustomFieldsBooleanNoReplicate the source list's custom fields. Default: true
bash
curl -X POST https://example.com/api.php \
  -H "Content-Type: application/json" \
  -d '{
    "Command": "list.clone",
    "SessionID": "your-session-id",
    "SubscriberListID": 123,
    "Name": "My cloned list",
    "IncludeCustomFields": true
  }'
json
{
  "Success": true,
  "ErrorCode": 0,
  "ErrorText": "",
  "ListID": 456,
  "CustomFieldsCloned": 7
}
json
{
  "Success": false,
  "ErrorCode": [2],
  "ErrorText": ["Invalid subscriber list id"]
}
txt
0: Success
1: Missing source subscriber list id
2: Missing new list name (or invalid source list — not found or not owned by the authenticated user)
3: Subscriber list quota exceeded (LimitLists group setting)
4: Failed to clone the list (e.g. custom-field replication failed; the new list has been rolled back)

Get All Lists

POST /api.php

API Usage Notes

  • Authentication required: User API Key
  • Required permissions: Lists.Get
  • Legacy endpoint access via /api.php only (no v1 REST alias configured)

Returns the authenticated user's subscriber lists with full per-row metadata. Supports pagination, free-text search across Name and Description, and filtering by archive state.

Request Body Parameters:

ParameterTypeRequiredDescription
CommandStringYesAPI command: lists.get
SessionIDStringNoSession ID obtained from login
APIKeyStringNoAPI key for authentication
RecordsPerRequestIntegerNoNumber of records per page (default: 0 = all)
RecordsFromIntegerNoStarting record offset (default: 0)
OrderFieldStringNoField to order by (default: ListID). Possible values: ListID, Name, CreatedOn, ArchivedAt, ActiveSubscriberCount, SegmentCount, LastActivityAt. Any other value falls back to the default.
OrderTypeStringNoSort direction: ASC or DESC (default: ASC). Any other value falls back to the default.
SearchStringNoCase-insensitive substring match against Name and Description. Empty string disables the filter.
ArchivedStringNoArchive-state filter (default: false). Possible values: false (only active lists), true (only archived lists), all (no filter).

Response Shape

Each row returned in Lists includes every column from oempro_subscriber_lists (ListID, Name, Description, OptInMode, CreatedOn, ArchivedAt, ActiveSubscriberCount, SegmentCount, LastActivityAt, sender fields, sync fields, opt-in/opt-out URLs, etc.) plus the following computed fields:

FieldTypeDescription
SubscriberCountIntegerActive subscribers (Subscribed, non-Hard-bounced). 5-minute Redis cache. Identical to ActiveSubscriberCount for sort consistency, kept for backwards compatibility.
ActiveSubscriberCountIntegerDenormalized active subscriber count (column on the list row). Maintained via write-through on Subscribers::GetActiveTotal cache miss. Eventually consistent within the 5-minute Redis cache TTL. Sortable.
SegmentCountIntegerDenormalized segment count. Maintained atomically by Segments::Create / Segments::Delete. Sortable.
LastActivityAtString | nullMost recent list activity timestamp (subscription, unsubscription, import, bounce, send). Maintained at the Statistics::UpdateListActivityStatistics chokepoint. Null until the first activity. Sortable.
EncryptedSaltedListIDStringmd5(MD5_SALT . ListID) – useful for read-only public links.
SyncLastDateTimeStringLocalized "Never" placeholder substituted when the underlying value is 0000-00-00 00:00:00.
EventListTrackerIDStringHashids-encoded list ID for the website event tracker.
EventUserTrackerIDStringHashids-encoded user ID for the website event tracker.
EventTrackerVariablesObjectConfiguration object for the website event tracker JS.
EventTrackerJSStringPre-rendered <script>…</script> block for the website event tracker.
OptionsObject | nullDecoded JSON of list-level options (e.g. PlainEmailHeader, HTMLEmailFooter, DoNotSendEmailCampaignIfRecipientIsEnrolledInJourneyOrAutoresponder). Returned as a decoded object, matching the list.get response.

TotalListCount reflects the filtered total (i.e. it respects Search and Archived), so paginated callers can use it as the basis for page counts.

bash
curl -X POST https://example.com/api.php \
  -H "Content-Type: application/json" \
  -d '{
    "Command": "lists.get",
    "SessionID": "your-session-id",
    "RecordsPerRequest": 20,
    "RecordsFrom": 0,
    "OrderField": "Name",
    "OrderType": "ASC",
    "Search": "newsletter",
    "Archived": "false"
  }'
json
{
  "Success": true,
  "ErrorCode": 0,
  "ErrorText": "",
  "TotalListCount": 5,
  "Lists": [
    {
      "ListID": 123,
      "Name": "Spring Newsletter",
      "Description": "Customers from the spring 2026 promotion",
      "ArchivedAt": null,
      "RelOwnerUserID": 1,
      "OptInMode": "Single",
      "CreatedOn": "2026-04-01 09:12:33",
      "SubscriberCount": 12345,
      "Options": {
        "DoNotSendEmailCampaignIfRecipientIsEnrolledInJourneyOrAutoresponder": false
      },
      "EncryptedSaltedListID": "abc123...",
      "EventListTrackerID": "xyz789",
      "EventUserTrackerID": "def456",
      "EventTrackerVariables": {},
      "EventTrackerJS": "..."
    }
  ]
}
json
{
  "Success": false,
  "ErrorCode": []
}
txt
0: Success

Migration note: prior to v5.9.1 the Options field was returned as a raw JSON-encoded string. It is now returned as a decoded object/array, matching list.get. Callers that parsed the string client-side must remove that step.

Get Per-List Statistics

POST /api.php

API Usage Notes

  • Authentication required: User API Key
  • Required permissions: Lists.Get
  • Legacy endpoint access via /api.php only (no v1 REST alias configured)

Returns aggregate per-list statistics over a configurable lookback window. Designed for the "Lists browse" page stat strip and per-row metrics — one round-trip across oempro_subscriber_lists joined with the pre-aggregated oempro_stats_list_daily_aggregated (opens / clicks) and oempro_stats_activity (sent / subscriptions / unsubscriptions / imports / hard bounces) sources. Archived lists are excluded.

Request Body Parameters:

ParameterTypeRequiredDescription
CommandStringYesAPI command: lists.stats
SessionIDStringNoSession ID obtained from login
APIKeyStringNoAPI key for authentication
DaysIntegerNoLookback window in days. Default 30. Clamped to [1, 365].
ListIDsStringNoOptional comma-separated list of ListID values to scope the response to.

Per-row response shape

FieldTypeDescription
ListIDIntegerList identifier
NameStringList name
ActiveSubscriberCountIntegerDenormalized active subscriber count (PR #1910 phase 2a)
SegmentCountIntegerDenormalized segment count
LastActivityAtString|nullMost recent recorded list activity timestamp
UniqueOpensIntegerSum of UniqueOpens over the window
UniqueClicksIntegerSum of UniqueClicks over the window
TotalSentIntegerSum of TotalSentEmail over the window
NetGrowthIntegersubscriptions + imports - unsubscriptions - hard_bounces over the window
OpenRateFloat|nullUniqueOpens / TotalSent (industry-standard convention). null when TotalSent == 0.
ClickRateFloat|nullUniqueClicks / TotalSent. null when TotalSent == 0.

Top-level fields

  • Days — the actual window applied (echoed back after clamping).
  • TotalListCount — number of lists included in the response.
  • WeightedAvgOpenRate — subscriber-weighted average of OpenRate across the response set, weighted by ActiveSubscriberCount * TotalSent. null when no list in the response had any sends in the window.
  • Lists — array of per-list stat rows.
bash
curl -X POST https://example.com/api.php \
  -H "Content-Type: application/json" \
  -d '{
    "Command": "lists.stats",
    "SessionID": "your-session-id",
    "Days": 30
  }'
json
{
  "Success": true,
  "ErrorCode": 0,
  "ErrorText": "",
  "Days": 30,
  "TotalListCount": 2,
  "WeightedAvgOpenRate": 0.21,
  "Lists": [
    {
      "ListID": 11,
      "Name": "Buyers List",
      "ActiveSubscriberCount": 1250,
      "SegmentCount": 5,
      "LastActivityAt": "2026-04-29 14:33:01",
      "UniqueOpens": 312,
      "UniqueClicks": 41,
      "TotalSent": 1250,
      "NetGrowth": 18,
      "OpenRate": 0.2496,
      "ClickRate": 0.0328
    },
    {
      "ListID": 313,
      "Name": "MOCK DATA",
      "ActiveSubscriberCount": 1000,
      "SegmentCount": 0,
      "LastActivityAt": "2026-04-30 20:00:43",
      "UniqueOpens": 0,
      "UniqueClicks": 0,
      "TotalSent": 0,
      "NetGrowth": -1,
      "OpenRate": null,
      "ClickRate": null
    }
  ]
}
json
{
  "Success": false,
  "ErrorCode": []
}
txt
0: Success

Delete Lists

POST /api.php

API Usage Notes

  • Authentication required: User API Key
  • Required permissions: List.Delete
  • Legacy endpoint access via /api.php only (no v1 REST alias configured)

Request Body Parameters:

ParameterTypeRequiredDescription
CommandStringYesAPI command: lists.delete
SessionIDStringNoSession ID obtained from login
APIKeyStringNoAPI key for authentication
ListsStringYesComma-separated list of list IDs to delete
bash
curl -X POST https://example.com/api.php \
  -H "Content-Type: application/json" \
  -d '{
    "Command": "lists.delete",
    "SessionID": "your-session-id",
    "Lists": "123,456,789"
  }'
json
{
  "Success": true,
  "ErrorCode": 0,
  "ErrorText": ""
}
json
{
  "Success": false,
  "ErrorCode": [1]
}
txt
0: Success
1: List IDs are missing

Get List Assets

POST /api.php

API Usage Notes

  • Authentication required: User API Key
  • Required permissions: List.Get
  • Legacy endpoint access via /api.php only (no v1 REST alias configured)

Retrieves comprehensive list information including all related assets: segments, custom fields, subscriber tags, and autoresponders.

Request Body Parameters:

ParameterTypeRequiredDescription
CommandStringYesAPI command: list.assets
SessionIDStringNoSession ID obtained from login
APIKeyStringNoAPI key for authentication
ListIDIntegerYesID of the list to retrieve assets for
bash
curl -X POST https://example.com/api.php \
  -H "Content-Type: application/json" \
  -d '{
    "Command": "list.assets",
    "SessionID": "your-session-id",
    "ListID": 123
  }'
json
{
  "Success": true,
  "ErrorCode": 0,
  "List": {
    "ListID": 123,
    "Name": "My List"
  },
  "Segments": {
    "Success": true,
    "Segments": []
  },
  "CustomFields": {
    "Success": true,
    "CustomFields": []
  },
  "SubscriberTags": {
    "Success": true,
    "Tags": []
  },
  "AutoResponders": {
    "Success": true,
    "AutoResponders": []
  }
}
json
{
  "Success": false,
  "ErrorCode": [1]
}
txt
0: Success
1: Missing list ID

Add Integration URL

POST /api.php

DEPRECATION WARNING

This endpoint is deprecated and will be removed in a future Octeth release. Please migrate to the webhook-based integration system available through the Email Gateway API endpoints.

API Usage Notes

  • Authentication required: User API Key
  • Required permissions: List.Update
  • Legacy endpoint access via /api.php only (no v1 REST alias configured)

Request Body Parameters:

ParameterTypeRequiredDescription
CommandStringYesAPI command: listintegration.addurl
SessionIDStringNoSession ID obtained from login
APIKeyStringNoAPI key for authentication
SubscriberListIDIntegerYesID of the list for integration
URLStringYesIntegration webhook URL
EventStringYesEvent type to trigger webhook
bash
curl -X POST https://example.com/api.php \
  -H "Content-Type: application/json" \
  -d '{
    "Command": "listintegration.addurl",
    "SessionID": "your-session-id",
    "SubscriberListID": 123,
    "URL": "https://example.com/webhook",
    "Event": "Subscribe"
  }'
json
{
  "Success": true,
  "ErrorCode": 0,
  "ErrorText": "",
  "WebServiceIntegrationID": 456,
  "EventType": "Subscribe",
  "ServiceURL": "https://example.com/webhook"
}
json
{
  "Success": false,
  "ErrorCode": [1, 2, 3, 4]
}
txt
0: Success
1: Missing subscriber list ID
2: Missing URL
3: Missing event type
4: Invalid subscriber list ID

Delete Integration URLs

POST /api.php

DEPRECATION WARNING

This endpoint is deprecated and will be removed in a future Octeth release. Please migrate to the webhook-based integration system available through the Email Gateway API endpoints.

API Usage Notes

  • Authentication required: User API Key
  • Required permissions: List.Update
  • Legacy endpoint access via /api.php only (no v1 REST alias configured)

Request Body Parameters:

ParameterTypeRequiredDescription
CommandStringYesAPI command: listintegration.deleteurls
SessionIDStringNoSession ID obtained from login
APIKeyStringNoAPI key for authentication
URLsStringYesComma-separated list of web service integration IDs
bash
curl -X POST https://example.com/api.php \
  -H "Content-Type: application/json" \
  -d '{
    "Command": "listintegration.deleteurls",
    "SessionID": "your-session-id",
    "URLs": "456,789,012"
  }'
json
{
  "Success": true,
  "ErrorCode": 0,
  "ErrorText": ""
}
json
{
  "Success": false,
  "ErrorCode": [1]
}
txt
0: Success
1: Web service integration URL IDs are missing

Get Integration URLs

POST /api.php

DEPRECATION WARNING

This endpoint is deprecated and will be removed in a future Octeth release. Please migrate to the webhook-based integration system available through the Email Gateway API endpoints.

API Usage Notes

  • Authentication required: User API Key
  • Required permissions: List.Get
  • Legacy endpoint access via /api.php only (no v1 REST alias configured)

Request Body Parameters:

ParameterTypeRequiredDescription
CommandStringYesAPI command: listintegration.geturls
SessionIDStringNoSession ID obtained from login
APIKeyStringNoAPI key for authentication
SubscriberListIDIntegerYesID of the list to get integration URLs for
EventStringNoFilter by specific event type
bash
curl -X POST https://example.com/api.php \
  -H "Content-Type: application/json" \
  -d '{
    "Command": "listintegration.geturls",
    "SessionID": "your-session-id",
    "SubscriberListID": 123,
    "Event": "Subscribe"
  }'
json
{
  "Success": true,
  "ErrorCode": 0,
  "ErrorText": "",
  "URLs": [
    {
      "WebServiceIntegrationID": 456,
      "RelListID": 123,
      "EventType": "Subscribe",
      "ServiceURL": "https://example.com/webhook"
    }
  ]
}
json
{
  "Success": false,
  "ErrorCode": [1]
}
txt
0: Success
1: Missing subscriber list ID

Test Integration URL

POST /api.php

DEPRECATION WARNING

This endpoint is deprecated and will be removed in a future Octeth release. Please migrate to the webhook-based integration system available through the Email Gateway API endpoints.

API Usage Notes

  • Authentication required: User API Key
  • Required permissions: List.Update
  • Legacy endpoint access via /api.php only (no v1 REST alias configured)

Request Body Parameters:

ParameterTypeRequiredDescription
CommandStringYesAPI command: listintegration.testurl
SessionIDStringNoSession ID obtained from login
APIKeyStringNoAPI key for authentication
URLStringYesIntegration webhook URL to test
bash
curl -X POST https://example.com/api.php \
  -H "Content-Type: application/json" \
  -d '{
    "Command": "listintegration.testurl",
    "SessionID": "your-session-id",
    "URL": "https://example.com/webhook"
  }'
json
{
  "Success": true,
  "ErrorCode": 0,
  "ErrorText": ""
}
json
{
  "Success": false,
  "ErrorCode": [1]
}
txt
0: Success
1: URL is missing

Generate Subscription Form HTML

POST /api.php

DEPRECATION WARNING

This endpoint is deprecated and will be removed in a future Octeth release. Modern integration methods should use direct API calls via the subscriber.create endpoint or use embedded JavaScript-based subscription forms.

API Usage Notes

  • Authentication required: User API Key
  • Required permissions: List.Get
  • Legacy endpoint access via /api.php only (no v1 REST alias configured)

Request Body Parameters:

ParameterTypeRequiredDescription
CommandStringYesAPI command: listintegration.generatesubscriptionformhtmlcode
SessionIDStringNoSession ID obtained from login
APIKeyStringNoAPI key for authentication
SubscriberListIDIntegerYesID of the list for the subscription form
CustomFieldsStringNoComma-separated custom field IDs to include in form
EmailAddressStringStringNoLabel text for email address field
SubscribeButtonStringStringNoText for subscribe button
HTMLSpecialCharsStringNoApply htmlspecialchars encoding (default: "true")
bash
curl -X POST https://example.com/api.php \
  -H "Content-Type: application/json" \
  -d '{
    "Command": "listintegration.generatesubscriptionformhtmlcode",
    "SessionID": "your-session-id",
    "SubscriberListID": 123,
    "CustomFields": "1,2,3",
    "EmailAddressString": "Your Email",
    "SubscribeButtonString": "Join Now"
  }'
json
{
  "Success": true,
  "ErrorCode": 0,
  "ErrorText": "",
  "HTMLCode": [
    "&lt;form action=&quot;https://example.com/subscribe.php&quot; method=&quot;post&quot;&gt;",
    "&lt;input type=&quot;text&quot; name=&quot;FormValue_Fields[EmailAddress]&quot;&gt;",
    "..."
  ]
}
json
{
  "Success": false,
  "ErrorCode": [1]
}
txt
0: Success
1: Missing subscriber list ID

Generate Unsubscription Form HTML

POST /api.php

DEPRECATION WARNING

This endpoint is deprecated and will be removed in a future Octeth release. Modern integration methods should use direct API calls via the subscriber.unsubscribe endpoint or use embedded JavaScript-based unsubscription forms.

API Usage Notes

  • Authentication required: User API Key
  • Required permissions: List.Get
  • Legacy endpoint access via /api.php only (no v1 REST alias configured)

Request Body Parameters:

ParameterTypeRequiredDescription
CommandStringYesAPI command: listintegration.generateunsubscriptionformhtmlcode
SessionIDStringNoSession ID obtained from login
APIKeyStringNoAPI key for authentication
SubscriberListIDIntegerYesID of the list for the unsubscription form
UnsubscribeButtonStringStringNoText for unsubscribe button
bash
curl -X POST https://example.com/api.php \
  -H "Content-Type: application/json" \
  -d '{
    "Command": "listintegration.generateunsubscriptionformhtmlcode",
    "SessionID": "your-session-id",
    "SubscriberListID": 123,
    "UnsubscribeButtonString": "Opt Out"
  }'
json
{
  "Success": true,
  "ErrorCode": 0,
  "ErrorText": "",
  "HTMLCode": [
    "&lt;form action=&quot;https://example.com/unsubscribe.php&quot; method=&quot;post&quot;&gt;",
    "&lt;input type=&quot;text&quot; name=&quot;FormValue_EmailAddress&quot;&gt;",
    "..."
  ]
}
json
{
  "Success": false,
  "ErrorCode": [1]
}
txt
0: Success
1: Missing subscriber list ID

Any questions? Contact us.