Name (singular): Draft
Name (plural): Drafts
Alias (uri): draft
Identifier (ID): cerberusweb.contexts.mail.draft

Records API

These fields are available in the Records API and packages:

Req'd Field Type Notes
  is_queued boolean 1 for true, 0 for false
  links links An array of record type:id tuples to link to. Prefix with - to unlink.
  name text The subject line of the draft message
  params object JSON-encoded key/value object
  queue_delivery_date number (0-4294967296)
  queue_fails number (0-4294967296)
  ticket_id number The ID of the ticket for ticket.reply or ticket.forward
  to text The To: line of the draft message
  token text A random unique token for this draft, copied to the eventual message for tracing
x type text The type of draft: mail.compose, mail.transactional, ticket.reply, or ticket.forward
  updated timestamp The date/time when this record was last modified
  worker_id number The ID of the worker who owns the draft

params (mail.compose)

Req'd Key Value
  bcc The Bcc: recipients
  bucket_id The bucket ID to move the ticket to
  cc The Cc: recipients
  content The message content
  custom_fields An object with custom field IDs as keys and their values
  custom_fields_uri A read-only object with custom field URIs as keys and their values
  format parsedown (Markdown), or blank for plaintext
  file_ids An array of attachment IDs
x group_id The group ID to move the ticket to
  headers An array of email headers to set, with header names as keys
  html_template_id An optional HTML template ID if format is parsedown
  message_custom_fields An object with message custom field IDs as keys and their values
  message_custom_fields_uri A read-only object with message custom field URIs as keys and their values
  options_gpg_encrypt 1 to enable PGP encryption, 0 (or omit) to disable
  options_gpg_sign 1 to enable PGP signatures, 0 (or omit) to disable
  org_id The org ID to assign
  org_name The org name to assign
  owner_id The worker ID to assign
  send_at The optional timestamp to deliver the message at
  status_id 0 (open), 1 (waiting), 2 (closed)
  subject The message Subject:
  ticket_reopen When the status is waiting or closed, the timestamp to reopen at
x to The To: recipients

params (mail.transactional)

Req'd Key Value
  bcc The Bcc: recipients
  cc The Cc: recipients
  content The message content
  file_ids An array of attachment IDs
  format parsedown (Markdown), or blank for plaintext
  from The From: sender (uses system default if omitted)
  from_personal The personal From: sender (uses system default if omitted)
  headers An array of email headers to set, with header names as keys
  html_template_id An optional HTML template ID if format is parsedown
  options_gpg_encrypt 1 to enable PGP encryption, 0 (or omit) to disable
  options_gpg_sign 1 to enable PGP signatures, 0 (or omit) to disable
  reply_to The optional Reply-To:
  return_path The optional Return-Path:
x subject The message Subject:
x to The To: recipients

params (ticket.reply / ticket.forward)

Req'd Key Value
  bcc The Bcc: recipients
  bucket_id The bucket ID to move the ticket to
  cc The Cc: recipients
  content The message content
  custom_fields An object with custom field IDs as keys and their values
  custom_fields_uri A read-only object with custom field URIs as keys and their values
  file_ids An array of attachment IDs
  format parsedown (Markdown), or blank for plaintext
  group_id The group ID to move the ticket to
  headers An array of email headers to set, with header names as keys
  html_template_id An optional HTML template ID if format is parsedown
  in_reply_message_id The message ID being responded to
  message_custom_fields An object with message custom field IDs as keys and their values
  message_custom_fields_uri A read-only object with message custom field URIs as keys and their values
  options_gpg_encrypt 1 to enable PGP encryption, 0 (or omit) to disable
  options_gpg_sign 1 to enable PGP signatures, 0 (or omit) to disable
  owner_id The worker ID to assign
  send_at The optional timestamp to deliver the message at
  status_id 0 (open), 1 (waiting), 2 (closed)
  subject The message Subject:
  ticket_reopen When the status is waiting or closed, the timestamp to reopen at
  to The To: recipients

Dictionary Placeholders

These placeholders are available in dictionaries for automations, snippets, and API responses:

Field Type Description
_context text Record type extension ID
_label text Label
_type text Record type alias
content text Content
id number Id
name text Name
params dictionary Params
ticket_ record Ticket
to text To
token text Token
type text Type
updated date Updated
worker_ record Worker

These optional placeholders are also available with key expansion in dictionaries and the API:

Field Type Description
comment_count number Comment count on the record
comments comments Comments
custom_<id> mixed Custom Fields

Search Query Fields

These filters are available in draft search queries:

Field Type Description
id: number Id
is.queued: boolean Is Queued
name: text Name
queue.deliverAt: date Delivery Date
queue.fails: number # Fails
ticket.id: chooser Ticket Id
to: text To
token: text Token
type: text Message Type
updated: date Updated
worker: record Worker
worker.id: chooser Worker

Worklist Columns

These columns are available on draft worklists:

Column Description
cf_<id> Custom Field
m_hint_to To
m_id Id
m_is_queued Is Queued
m_name Name
m_queue_delivery_date Delivery Date
m_queue_fails # Fails
m_token Token
m_type Message Type
m_updated Updated
m_worker_id Worker