Skip to main content

Email body converter

A simple extension that can convert the email HTML body into a PDF and upload it to a queue as a new document.

An additional feature is that it can also convert HTML attachments into PDFs.

The original API endpoint documentation can be found here.

Installation

Email body converter is a webhook maintained by Rossum. To use it, follow these steps:

  1. Log in to your Rossum account.
  2. Navigate to Extensions → My extensions.
  3. Click on Create extension.
  4. Fill in the following fields:
    1. Name: Email body converter
    2. Trigger events: email.received
    3. Extension type: Webhook
    4. URL (see below)
    5. In "Advanced settings" select Token owner (should have Admin access)
  5. Click Create the webhook.
  6. Fill in the Configuration field. See Available configuration options below.
EnvironmentWebhook URL
EU1 Irelandhttps://elis.rossum.ai/svc/email-converter/api/v1/convert
EU2 Frankfurt
US east coasthttps://us.app.rossum.ai/svc/email-converter/api/v1/convert
Japan Tokyo

Available configuration options

{
// Each object in the `configurations` list represents a specific configuration (distinguished by
// the queue IDs).
"configurations": [
{
// Required! List of queue IDs this configuration applies to. A single configuration can be
// used for multiple queues, specified in this list.
"queue_ids": [172636],

// Minimum number of characters in the email body to convert it to PDF. Default is 0.
"minimal_email_character_count": 5,

// Skip conversion if supported files are present (`true` to skip, `false` to convert the
// email body to PDF). Supported files include email attachments supported by Rossum and any
// additional files converted to PDF as part of the webhook call (e.g., HTML attachments
// converted to PDF). Default is `false`.
"skip_if_supported_files_present": false,

// Optional. List of attachment types to convert to PDF. Supported values: "html", "txt"
"convert_attachments": ["html", "txt"],

// Optional. Specifies the style for TXT files, which are first converted to HTML and then
// to PDF. This configuration is added as an HTML style tag to affect the appearance of
// the TXT in the converted PDF.
"txt_style": "@page { size: letter landscape; margin: 2cm; } pre { white-space: pre-wrap; }"
}
]
}