Skip to content

Rebranding API Documentation

Theme and white-label rebranding endpoints for customizing the Octeth interface appearance, logos, and product branding.

Create a Theme

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: theme.create
SessionIDStringNoSession ID obtained from admin login
APIKeyStringNoAdmin API key for authentication
TemplateStringYesTemplate code (must match an installed template)
ThemeNameStringYesName for the new theme
ProductNameStringNoCustom product name for white-label branding
ThemeSettingsStringNoTheme CSS settings in format: tag````value\ntag````value (newline-separated)
bash
curl -X POST https://example.com/api.php \
  -H "Content-Type: application/json" \
  -d '{
    "Command": "theme.create",
    "SessionID": "admin-session-id",
    "Template": "weefive",
    "ThemeName": "My Custom Theme",
    "ProductName": "My Email Platform",
    "ThemeSettings": "primary-color||||#0066cc\nbackground-color||||#ffffff"
  }'
json
{
  "Success": true,
  "ErrorCode": 0,
  "ThemeID": 123
}
json
{
  "Success": false,
  "ErrorCode": [1, 2, 3]
}
txt
0: Success
1: Missing template parameter
2: Missing theme name parameter
3: Invalid template code (template not found or not installed)

Get a Theme

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: theme.get
SessionIDStringNoSession ID obtained from admin login
APIKeyStringNoAdmin API key for authentication
ThemeIDIntegerYesID of the theme to retrieve
bash
curl -X POST https://example.com/api.php \
  -H "Content-Type: application/json" \
  -d '{
    "Command": "theme.get",
    "SessionID": "admin-session-id",
    "ThemeID": 123
  }'
json
{
  "Success": true,
  "ErrorCode": 0,
  "Theme": {
    "ThemeID": 123,
    "Template": "weefive",
    "ThemeName": "My Custom Theme",
    "ProductName": "My Email Platform",
    "LogoData": "",
    "LogoType": "",
    "LogoSize": 0,
    "LogoFileName": "",
    "ThemeSettings": "primary-color||||#0066cc\nbackground-color||||#ffffff"
  }
}
json
{
  "Success": false,
  "ErrorCode": [1, 2]
}
txt
0: Success
1: Missing theme ID parameter
2: Theme not found

Update a Theme

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: theme.update
SessionIDStringNoSession ID obtained from admin login
APIKeyStringNoAdmin API key for authentication
ThemeIDIntegerYesID of the theme to update
TemplateStringNoNew template code (must match an installed template)
ThemeNameStringNoNew theme name
ProductNameStringNoNew product name for white-label branding
LogoDataStringNoBase64-encoded logo image data
LogoTypeStringNoLogo MIME type (e.g., "image/png", "image/jpeg")
LogoSizeIntegerNoLogo file size in bytes
LogoFileNameStringNoOriginal logo filename
ThemeSettingsStringNoTheme CSS settings in format: tag````value\ntag````value (newline-separated)
bash
curl -X POST https://example.com/api.php \
  -H "Content-Type: application/json" \
  -d '{
    "Command": "theme.update",
    "SessionID": "admin-session-id",
    "ThemeID": 123,
    "ThemeName": "Updated Theme Name",
    "ProductName": "Updated Product Name",
    "ThemeSettings": "primary-color||||#ff6600\nbackground-color||||#f5f5f5"
  }'
json
{
  "Success": true,
  "ErrorCode": 0,
  "ErrorText": ""
}
json
{
  "Success": false,
  "ErrorCode": [3, 4, 5]
}
txt
0: Success
3: Invalid template code (template not found or not installed)
4: Missing theme ID parameter
5: Theme not found

Get All Themes

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: themes.get
SessionIDStringNoSession ID obtained from admin login
APIKeyStringNoAdmin API key for authentication
bash
curl -X POST https://example.com/api.php \
  -H "Content-Type: application/json" \
  -d '{
    "Command": "themes.get",
    "SessionID": "admin-session-id"
  }'
json
{
  "Success": true,
  "ErrorCode": 0,
  "Themes": [
    {
      "ThemeID": 1,
      "Template": "weefive",
      "ThemeName": "Default Theme",
      "ProductName": "Octeth",
      "ThemeSettings": "primary-color||||#0066cc\nbackground-color||||#ffffff"
    },
    {
      "ThemeID": 123,
      "Template": "weefive",
      "ThemeName": "My Custom Theme",
      "ProductName": "My Email Platform",
      "ThemeSettings": "primary-color||||#ff6600\nbackground-color||||#f5f5f5"
    }
  ]
}
json
{
  "Success": false,
  "ErrorCode": []
}
txt
0: Success

Delete Themes

POST /api.php

API Usage Notes

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

Deletes one or more themes. The system prevents deletion of the default theme and the last remaining theme to ensure at least one theme is always available.

Request Body Parameters:

ParameterTypeRequiredDescription
CommandStringYesAPI command: theme.delete
SessionIDStringNoSession ID obtained from admin login
APIKeyStringNoAdmin API key for authentication
ThemesStringYesComma-separated list of theme IDs to delete
bash
curl -X POST https://example.com/api.php \
  -H "Content-Type: application/json" \
  -d '{
    "Command": "theme.delete",
    "SessionID": "admin-session-id",
    "Themes": "123,456"
  }'
json
{
  "Success": true,
  "ErrorCode": 0
}
json
{
  "Success": false,
  "ErrorCode": [1, 2]
}
txt
0: Success
1: Missing themes parameter (theme IDs required)
2: Cannot delete the last remaining theme (at least one theme must exist)

Any questions? Contact us.