#Newsletter webhook

When you set up a newsletter widget via the Poool's dashboard, it is possible to define the texts, the appearance and some optional features such as the newsletter identifier etc.
You can also retrieve these informations via the onRegister Poool event of Poool.

Poool allows you to go further by providing a webhook to define your own logic to process the received emails and to display custom errors.

Usage examples:
  • Check for duplicated emails
  • Check for emails validity

#Create your endpoint

As specified in the introduction section, you must first configure your own endpoint.
Here is the list of information sent by Poool:
You are now able to set up your own logic. To display errors inside your form, simply return a JSON payload.
ℹ️ Warning, the fieldKey associated to this error is email. It is therefore necessary to return a payload in the following format:
ℹ️ Be careful when configuring your endpoint. If you return a payload with the fieldKey email, it will be impossible to unlock the article.

#Activate your webhook

When your endpoint is ready, you can activate the webhook in your dashboard and specify the url.


The wall is now configured and an error is displayed under the newsletter field in case of invalid email.