List messages for a bulk action job
email_security.investigate.bulk.messages.list(strjob_id, MessageListParams**kwargs) -> SyncV4PagePaginationArray[MessageListResponse]
GET/accounts/{account_id}/email-security/investigate/bulk/{job_id}/messages
List messages for a bulk action job
Security
API Token
The preferred authorization scheme for interacting with the Cloudflare API. Create a token.
Example:
API Email + API Key
The previous authorization scheme for interacting with the Cloudflare API, used in conjunction with a Global API key.
Example:
The previous authorization scheme for interacting with the Cloudflare API. When possible, use API tokens instead of Global API keys.
Example:
Accepted Permissions (at least one required)
Parameters
List messages for a bulk action job
import os
from cloudflare import Cloudflare
client = Cloudflare(
api_token=os.environ.get("CLOUDFLARE_API_TOKEN"), # This is the default and can be omitted
)
page = client.email_security.investigate.bulk.messages.list(
job_id="182bd5e5-6e1a-4fe4-a799-aa6d9a6ab26e",
account_id="023e105f4ecef8ad9ca31a8372d0c353",
)
page = page.result[0]
print(page.message_id){
"errors": [
{
"code": 1000,
"message": "message",
"documentation_url": "documentation_url",
"source": {
"pointer": "pointer"
}
}
],
"messages": [
{
"code": 1000,
"message": "message",
"documentation_url": "documentation_url",
"source": {
"pointer": "pointer"
}
}
],
"result": [
{
"action_params": {
"client_recipient": "client_recipient",
"destination": "Inbox",
"type": "MOVE",
"expected_disposition": "MALICIOUS"
},
"action_type": "MOVE",
"created_at": "2019-12-27T18:11:19.117Z",
"message_id": "182bd5e5-6e1a-4fe4-a799-aa6d9a6ab26e",
"postfix_id": "postfix_id",
"retry_count": 0,
"status": "PENDING",
"alert_id": "alert_id",
"email_message_id": "email_message_id",
"processed_at": "2019-12-27T18:11:19.117Z",
"retry_after": "2019-12-27T18:11:19.117Z",
"status_message": "status_message"
}
],
"result_info": {
"count": 0,
"per_page": 0,
"total_count": 0,
"next": "next",
"page": 0,
"previous": "previous"
},
"success": true
}Returns Examples
{
"errors": [
{
"code": 1000,
"message": "message",
"documentation_url": "documentation_url",
"source": {
"pointer": "pointer"
}
}
],
"messages": [
{
"code": 1000,
"message": "message",
"documentation_url": "documentation_url",
"source": {
"pointer": "pointer"
}
}
],
"result": [
{
"action_params": {
"client_recipient": "client_recipient",
"destination": "Inbox",
"type": "MOVE",
"expected_disposition": "MALICIOUS"
},
"action_type": "MOVE",
"created_at": "2019-12-27T18:11:19.117Z",
"message_id": "182bd5e5-6e1a-4fe4-a799-aa6d9a6ab26e",
"postfix_id": "postfix_id",
"retry_count": 0,
"status": "PENDING",
"alert_id": "alert_id",
"email_message_id": "email_message_id",
"processed_at": "2019-12-27T18:11:19.117Z",
"retry_after": "2019-12-27T18:11:19.117Z",
"status_message": "status_message"
}
],
"result_info": {
"count": 0,
"per_page": 0,
"total_count": 0,
"next": "next",
"page": 0,
"previous": "previous"
},
"success": true
}