See api-docs Menu

Test Config Without Account Email Settings Update

Use this API to test an Email Settings config without updating the account Email Settings configuration.

Resource URL


Header Parameters




Set to bearer <access_token>.

Set <access_token> to the access token you generated using the Generate Token API.

The access token must have been generated using an API credential pair created using the scope required to call this API. This API can be called using any one of the following scopes: Manage All.




Set to application/json.

Sample Email

Below is an example of a test email, verify that it’s sent from the correct domain.

Request Parameters

address string Required. Email Settings server address
domain string Required. Domain of the From address.
from string Required. The From email address in the message.
port integer Optional. Defaults to 2.5.
user_name string Optional. The user name of the account to authenticate with the Email Settings server.
password string Optional. The password of the account to authenticate with the Email Settings server.
use_tls boolean Optional. Defaults to true.

Sample Request Body

   "address": "",
   "use_tls": true,
   "from": "",
   "domain": "",
   "user_name": "user-name",
   "password": "password",
   "port": 587

Sample Responses

   "message": "Success",
   "statusCode": 200,
   "name": "Success"

Typically, this error means that your Authorization header value is missing or incorrectly formatted. The Authorization header value should use this format: bearer:<access_token>.

    "message": "Unauthorized",
    "statusCode": 401,
    "name": "UnauthorizedError"
   "message": "535 Authentication failed: The provided authorization grant is invalid, expired, or revoked\n",
   "statusCode": 500,
   "name": "InternalServerError"

Postman Collection

Replace sample variables indicated by {{ }} with your actual values.

Download for the Branding API

Sample Code


Replace sample values indicated by < > with your actual values.

Test Config Without Account Email Settings Update

curl 'https://<subdomain>/api/2/branding/email_settings/test' \
-X PUT \
-H "Authorization: bearer <access_token>" \
-H "Content-Type: application/json" \
-d '{
    "address": """,
    "domain": "",
    "from": ""

Have a Question?

Found a problem or a bug? Submit a support ticket.

Looking for walkthroughs or how-to guides on OneLogin's user and admin features? Check out the documentation in our Knowledge Base.

Have a product idea or request? Share it with us in our Ideas Portal.