Email Parser

Extract data from emails and automate your workflow

Documentation topics:

Creating a custom automated process with a script

In order to understand the following help topic you need some programming skills. Consider using our professional services for the specific email filtering needs you may have.

See also
Email Parser scripting SDK
Capturing text with scripts
Using scripts to filter emails
Example – Basic use of a script in an automated process

Email Parser provides specific automated processes for the most common tasks but sometimes a very specific automated process need to be done for the emails. For this purpose script automated processes and the  process that runs external program are provided.

To create your own script automated process you need to implement the function Run() as it is shown below:

using System;
using System.Text;
using System.IO;
using System.Net.Mail;
using System.Net.NetworkInformation;
using System.Collections.Specialized;
using EmailParser.Logic.ScriptingInterface;

public class MyAction : ScriptBasedAction
	public override bool Run(MailMessage email, NameValueCollection fields)
        // Check if the database server is online
        string database_server_ip_address = "";
        Ping pingSender = new Ping();
        PingReply reply = pingSender.Send(database_server_ip_address);
        if (reply.Status == IPStatus.Success)
            fields.Add("is_online_db_server", "yes");
            fields.Add("is_online_db_server", "no");

        return (true);