Skip to main content
All CollectionsGetting Started
Create your first template to extract text from emails
Create your first template to extract text from emails

How to use the template editor to tell Parseur which data points to extract from your documents

Updated over 2 months ago

This tutorial assumes that you already created a mailbox and sent your first email. If not, check out this article to get started.

Prefer to watch a video?

Step 1: Open the template editor

You can create your first template in two ways, using the wizard and using the standard flow.

Option 1: Open the template editor from the wizard

If you have just created your template, the Wizard will offer you to create your first template.

Option 2: Open the template editor the standard way

Every template needs to be created from a base document.

Head over to the Documents section on the left menu. Then locate the email you want to create a template from and click on the + button.

Step 2: Get acquainted with the template editor

When you create your first template, the Template Editor tutorial opens. You can revisit that tutorial by clicking on the "How to use this editor" link at the top right corner of the screen.

The Template Editor is where you will show which information you want to retrieve from documents.

Let's go through each section of this screen:

  1. Template Name: give your template a name (name must be unique in a mailbox)

  2. View As: leave this on Rich for now. Other modes can be useful but are for an advanced usage.

  3. Available tab: lists the fields used in other templates. As this is your first template, the list is empty.

  4. Used tab: lists the fields currently captured from the document for this template. As you haven't created any field yet, this list is also empty.

  5. Extra tab (this tab may be hidden behind the drop-down menu on smaller screens): lists additional metadata fields you may want to add to your parsed results. See below for more information.

  6. Action: leave this on Processed. Skip and Delete can be used when you want to discard emails from being processed.

  7. Status: leave this on Enabled. If you set this to Disabled, the template won't be used (useful when making tests).

  8. Reprocess all unprocessed documents: leave this checked. Uncheck this if you don't want unprocessed documents to be reprocessed using this template (useful when making tests if you have a large number of older unprocessed documents you don't want to process anymore).

Step 3: Create your first field

In Parseur, a field represents a piece of information you want to extract.

The animation below shows you how to add your first field.

To add a field:

  1. Select the piece of text you want to capture

  2. The "New Field" button becomes available

  3. Click this button, this will add a new entry to the Used fields section

  4. Name your field

  5. Click the "Tick mark" icon (or press Enter)

Step 4: Create all remaining fields and save

Repeat the steps described above for every field you want to capture.

Step 5: Add metadata fields (optional)

You may want to extract additional metadata information that is not present in the document body, like for instance the Sender's email address, the date the email was sent to, etc. 

Head over to the Metadata tab next to the Fields tab 

For more information check out our Using Metadata Fields article.

Step 6: Save the template

Once finished, click "Create".

You will now see that your document has been processed.

For each document, you can perform 8 actions:

  • View: display the email and the parsed data

  • Re-run parsing: useful if you updated the template and want to refresh the captured data

  • Create a new template based on the document

  • Skip document: Parseur will now ignore it

  • Copy document to another mailbox

  • View the logs to see an audit trail of what happened to the document (new! not shown on the screen capture)

  • Launch the template debugger to see which parts of the document match or not a template

  • Delete the document

The recommended action shown is a darker blue.

In this case, it is "View". Click on it.

Step 7: Check the results

Make sure that all the data were captured correctly.

In this screen you see:

  • At the top, metadata info about the document, including the number of credits that were used

  • At the top right, the action buttons (hover them for more information)

  • On the left, the email

  • On the right, the parsed data extracted (based on the template indicated at the top)

If everything looks correct, congratulations! You have parsed your first email.

Now send more emails and verify that your data is correctly extracted. Create new templates as necessary.

Frequently Asked Questions

How can I add an email sample to an existing template?

This feature is only available for OCR (PDFs) documents, unfortunately. For emails, you can use the debugger to see which part of the email didn't match the template and then either adjust the template manually or create a new template.

What's Next?

Did this answer your question?