Move a message
client.emailSecurity.investigate.move.create(stringinvestigateId, MoveCreateParams { account_id, destination } params, RequestOptionsoptions?): SinglePage<MoveCreateResponse { success, completed_at, completed_timestamp, 6 more } >
POST/accounts/{account_id}/email-security/investigate/{investigate_id}/move
Moves a single message to a specified mailbox folder (Inbox, JunkEmail, DeletedItems, RecoverableItemsDeletions, or RecoverableItemsPurges). Requires active integration.
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)
Move a message
import Cloudflare from 'cloudflare';
const client = new Cloudflare({
apiToken: process.env['CLOUDFLARE_API_TOKEN'], // This is the default and can be omitted
});
// Automatically fetches more pages as needed.
for await (const moveCreateResponse of client.emailSecurity.investigate.move.create(
'4Njp3P0STMz2c02Q-2024-01-05T10:00:00-12345678',
{ account_id: '023e105f4ecef8ad9ca31a8372d0c353', destination: 'Inbox' },
)) {
console.log(moveCreateResponse.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": [
{
"success": true,
"completed_at": "2019-12-27T18:11:19.117Z",
"completed_timestamp": "2019-12-27T18:11:19.117Z",
"destination": "destination",
"item_count": 0,
"message_id": "message_id",
"operation": "operation",
"recipient": "recipient",
"status": "status"
}
],
"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": [
{
"success": true,
"completed_at": "2019-12-27T18:11:19.117Z",
"completed_timestamp": "2019-12-27T18:11:19.117Z",
"destination": "destination",
"item_count": 0,
"message_id": "message_id",
"operation": "operation",
"recipient": "recipient",
"status": "status"
}
],
"success": true
}