Return message's top 200 lines in BoxTrapper queue

This function returns the first 200 lines of an email in the BoxTrapper queue.

Important:

When you disable the Receive Mail role, the system disables this function.

SecurityBasicAuth
Request
query Parameters
required
string or string

The account’s name, either an email address or the cPanel user’s username.

Important:

If you call this function in Webmail, the system ignores this parameter.

Example: email=user@example.com
queuefile
required
string

The message's filename.

Example: queuefile=example.msg
Responses
200

HTTP Request was successful.

Response Schema: application/json
apiversion
integer

The version of the API.

func
string

The name of the method called.

module
string

The name of the module called.

object
get/BoxTrapper/get_message
Request samples
uapi --output=jsonpretty \
  --user=username \
  BoxTrapper \
  get_message \
  email='user@example.com' \
  queuefile='example.msg'
Response samples
application/json
{
  • "apiversion": 3,
  • "func": "get_message",
  • "module": "BoxTrapper",
  • "result": {
    • "data": {
      • "content": "From user@example.com Tue May 07 08:30:36 2019\nReceived: from user by example.com with local (Exim 4.92) (envelope-from <root@yourserver.net>)\n id 1hO0B1-0003Ev-Md for user2@example.com; Tue, 07 May 2019 08:30:36 -0500\nFrom: user3@example.com\nSubject: Message\nMessage-Id: <E1hO0B1-0003Ev-Md@yourserver.net>\nDate: Tue, 07 May 2019 08:30:35 -0500\n\nThis is an email message",
      • "contents": null,
      • "queuefile": "example.msg"
      },
    • "errors": null,
    • "messages": null,
    • "metadata": { },
    • "status": 1,
    • "warnings": null
    }
}