1. Home
  2. Docs
  3. Developer Guide
  4. NeverBounce email validation via Webhooks

NeverBounce email validation via Webhooks

Email validation is the process that verifies whether or not an email address is valid or not. In order to grow a successful business, good reputation is key. Building a good reputation thought is not an easy path and requires lots of work.

Email contact with clients or prospects is a very important and as a business you need to maintain consistency. If you send emails to invalid email addresses, the bounce rate will be higher. Your mailbox provider will measure  it and rate your sender reputation.

You risk being classified as a spammer and your email account may be suspended.

Email validation lowers the bounce rate up to 97% and you will save yourself lots of trouble and have a good reputation also.

We are going to explain in details how you can achieve this with Flexie CRM Webhooks and NeverBounce email validator.

Setup NeverBounce

Login to NeverBounce  and navigate to Apps. In the Custom Integration panel click Add to create an app that will integrate with Flexie CRM.

Click Save to create the App and it will redirect to its settings.  There you will see the API Key that we will need for the integration webhook.

Next we will need the URL to post to in the NeverBounce API. If you open the NeverBounce API documentation you will have a URL to verify email addresses. There is also the option to verify lists of emails but for this article we will only cover the email address verification.

So in details, we are required a POST request to a given NeverBounce API URL.

Method: POST

URL: https://api.neverbounce.com/v4/single/check?key={api_key}&email={email}

We will replace {api_key} with the generated NeverBounce API Key and {email} with the email to be verified.

The response will have the details in the format below:

{
    "status": "success",
    "result": "valid",
    "flags": [
    "smtp_connectable",
    "has_dns",
    "has_dns_mx"
    ],
    "suggested_correction": "",
    "execution_time": 206
}

If the email address will be valid the “result” will have the “valid” value otherwise it will have the “invalid” value. We will always check for the result when getting this data back to Flexie.

Setup Flexie CRM Webhook to verify an email address

There are many ways on how to setup a workflow to validate email addresses. We could make the validation on entity insert and send a webhook to NeverBouce to verify if the email address is correct or not.

Here in this case we will perform this operation with a manual workflow. A manual workflow is reusable from any workflow by using the action Change Workflows when an event occurs.

To try this out you can go the an entity record, and select action Run Workflow. The only workflows listed that can be run on single records manually are the manual workflows. Then you go the the Received Payload Info button and check the result.

To access this result within the workflow for any purpose you can use  {{__data.webhook.result}} and to access all the payload {{__data.webhook}}.

To stay updated with the latest features, news and how-to articles and videos, please join our group on Facebook, Flexie CRM Academy.

How can we help?