post_company_bulletin

The post_company_bulletin method sends the specified bulletin to all users in all domains in the company.

📘

Note:

To get a list of all current bulletins, use the get_company method.

Syntax

{
    <credentials object>, 
    "company": <company_name>, 
    "bulletin": <bulletin_name>,     
    "type": auto | manual, 
    "test_email": <email_address> 
    },
}

Request fields for post_company_bulletin

The following fields can be used in the post_company_bulletin method:

RequiredObligationDefinition/Value
bulletinRequiredThe name of the bulletin you want to view.
companyRequiredThe name of the company.
test_emailOptionalSends the bulletin to only the specified email address.
typeRequiredSpecify the bulletin type.

Allowed values are:

auto — The bulletin is automatically sent to new users when their accounts are created.

manual — The bulletin is sent only when the post_company_bulletin method is run.

Response fields for post_company_bulletin

The following fields may be returned in response to the post_company_bulletin method:

Field nameObligationDescription/Value
errorReturned if success = falseA text string that explains the error.
error_numberReturned if success = falseA number that represents the error.
successAlways returnedIndicates whether the request was successful or not. Allowed values are true and false.

Examples for post_company_bulletin

Example 1

Request

{
  "credentials": {
    "user": "[email protected]",
    "password": "sw0rdfish"
  },
"company": "Example Corp", 
"bulletin": "Fridge",
"type": "manual",
"test_email": "[email protected]"
}

Response

{
  "success": true
}

Example 2

Sends a bulletin to all users in all domains in the company Example Corp.

Request

{
  "credentials": {
    "user": "[email protected]",
    "password": "sw0rdf1sh"
  },
  "company": "Example Corp",
  "bulletin": "Fridge",
  "type": "auto"
}

Response

{
  "success": true
}