user_notify

The user_notify method checks to see if the specified user has any unseen mail in their Inbox.

This method can be run by the following admin types:

  • company
  • company_mail
  • company_mail2
  • company_view
  • domain
  • mail
  • workgroup

Syntax

{
    <credentials object>, 
    "user": <mailbox_name>
}

Request fields for user_notify

The following fields can be used in the user_notify method:

Field name

Obligation

Definition/Value

user

Required

The user's email address.

Response fields for user_notify

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

Field name

Obligation

Description/Value

error

Returned if success = false

A text string that explains the error.

error_number

Returned if success = false

A number that represents the error.

new_mail

Returned if success = true

Indicates whether or not there is unseen mail in the specified user's Inbox. Allowed values are true and false.

success

Always returned

Indicates whether the request was successful or not. Allowed values are true and false.

Examples for user_notify

Request

{
  "credentials": {
    "user": "[email protected]",
    "password": "pencil75"
  },
  "user": "[email protected]
}

Response

If the Inbox contains unread mail

{
  "success": true,
  "new_mail": true,
  "audit": "pin28_514b678124"
}

Response

If the Inbox does not contain any unread mail

{
  "success": true,
  "new_mail": false,
  "audit": "hammer28_514b678124"
}