SMTP Users

📘

Do you have any questions on our Email API? Write to us at [email protected]

/settings/addSmtp

Creates a new SMTP user.

Example Request

{
    "owner_id": "example id",
    "token": "example token",
    "total_limit": 1000,
    "hourly_limit": 100
}

Example Success Response

{
    "status": "success",
    "message": "Smtp User Added",
    "smtp_user_name": "smtp12345",
    "smtp_password": "examplepassword"
}

Example Error Response

{
    "status": "error",
    "code": -1,
    "name": "AuthenticationError",
    "message": "Token MissMatch"
}

Parameters

ParameterTypeDescription
owner_id*stringa valid SendCleanUser Id
token*stringa valid token
total_limit*integertotal sending limit for the SMTP user
hourly_limit*integerhourly sending limit for the SMTP user

*compulsory field

Return Value: Success

struct — the results of adding an SMTP user

FieldTypeDescription
statusstringsuccess
messagestringhuman readable message
smtp_user_namestringnewly created SMTP user name
smtp_passwordstringnewly created SMTP password

Return Value: Error

struct — the error results when attempting to add an SMTP user

FieldTypeDescription
statusstringerror
messagestringhuman readable message
typestringone of the error types listed below

Error Types

ValidationError — The parameters passed to the API call are invalid or not provided when required.

GeneralError — An unexpected error occurred processing the request. SendClean Developers will be notified.

AuthenticationError — Provided owner_id and token was not matched.


/settings/editSmtp

Modifies an existing SMTP user.

Example Request

{
    "owner_id": "example id",
    "token": "example token",
    "smtp_user_name": "smtp12345",
    "total_limit": 2000,
    "hourly_limit": 200,
    "status": "Enable"
}

Example Success Response

{
    "status": "success",
    "message": "Smtp User Updated"
}

Example Error Response

{
    "status": "error",
    "code": -1,
    "name": "AuthenticationError",
    "message": "Token MissMatch"
}

Parameters

ParameterTypeDescription
owner_id*stringa valid SendCleanUser Id
token*stringa valid token
smtp_user_name*stringa valid SMTP user name
total_limitintegerupdated total sending limit
hourly_limitintegerupdated hourly sending limit
statusstringEnable or Disable

*compulsory field

Return Value: Success

struct — the results of editing an SMTP user

FieldTypeDescription
statusstringsuccess
messagestringhuman readable message

Return Value: Error

struct — the error results when attempting to edit an SMTP user

FieldTypeDescription
statusstringerror
messagestringhuman readable message
typestringone of the error types listed below

Error Types

ValidationError — The parameters passed to the API call are invalid or not provided when required.

GeneralError — An unexpected error occurred processing the request. SendClean Developers will be notified.

AuthenticationError — Provided owner_id and token was not matched.


/settings/resetSmtpPassword

Resets the password for an existing SMTP user.

Example Request

{
    "owner_id": "example id",
    "token": "example token",
    "smtp_user_name": "smtp12345"
}

Example Success Response

{
    "status": "success",
    "message": "Smtp Password Reset",
    "smtp_user_name": "smtp12345",
    "smtp_password": "newexamplepassword"
}

Example Error Response

{
    "status": "error",
    "code": -1,
    "name": "AuthenticationError",
    "message": "Token MissMatch"
}

Parameters

ParameterTypeDescription
owner_id*stringa valid SendCleanUser Id
token*stringa valid token
smtp_user_name*stringa valid SMTP user name

*compulsory field

Return Value: Success

struct — the results of resetting SMTP password

FieldTypeDescription
statusstringsuccess
messagestringhuman readable message
smtp_user_namestringSMTP user name
smtp_passwordstringnew SMTP password

Return Value: Error

struct — the error results when attempting to reset SMTP password

FieldTypeDescription
statusstringerror
messagestringhuman readable message
typestringone of the error types listed below

Error Types

ValidationError — The parameters passed to the API call are invalid or not provided when required.

GeneralError — An unexpected error occurred processing the request. SendClean Developers will be notified.

AuthenticationError — Provided owner_id and token was not matched.


/settings/listSmtp

Retrieves all SMTP users associated with an account.

Example Request

{
    "owner_id": "example id",
    "token": "example token"
}

Example Success Response

{
    "status": "success",
    "smtp_data": [
        {
            "smtp_user_name": "smtp12345",
            "smtp_password": "examplepassword",
            "status": "Enable",
            "total_limit": 1000,
            "hourly_limit": 100
        }
    ]
}

Example Error Response

{
    "status": "error",
    "code": -1,
    "name": "AuthenticationError",
    "message": "Token MissMatch"
}

Parameters

ParameterTypeDescription
owner_id*stringa valid SendCleanUser Id
token*stringa valid token

*compulsory field

Return Value: Success

struct — the results of listing SMTP users

FieldTypeDescription
statusstringsuccess
smtp_dataarrayarray of SMTP user objects

**smtp_data[]**fields:

FieldTypeDescription
smtp_user_namestringSMTP user name
smtp_passwordstringSMTP password
statusstringEnable or Disable
total_limitintegertotal sending limit
hourly_limitintegerhourly sending limit

Return Value: Error

struct — the error results when attempting to list SMTP users

FieldTypeDescription
statusstringerror
messagestringhuman readable message
typestringone of the error types listed below

Error Types

ValidationError — The parameters passed to the API call are invalid or not provided when required.

GeneralError — An unexpected error occurred processing the request. SendClean Developers will be notified.

AuthenticationError — Provided owner_id and token was not matched.


Did this page help you?