- Have a single view of your customers, unifying Dynamic user information with your CRM and marketing data.
- Enable powerful on-chain automations and marketing campaigns (like XMTP messaging) based on Dynamic webhook events.
Prerequisites
This guide builds on the serverless guide, so you should have already completed that guide and have a working serverless function. It also assumes you already have a Holder account.Step 1: Get your Authentication token
For Holder.xyz, you’ll need to follow a couple of steps in order to get the token you’ll need to authenticate with the API. The fastest way is to follow this guide: https://docs.holder.xyz/holder-api/authentication. Come back here once you have your token! You’ll be passing this in the header of API requests like so:Step 2: Define your API request
The choice is yours as to which library you use, we will use Fetch here. First we need to know our base URL, which ishttps://api.holder.xyz/
. We will be using the POST
method to create a new user, and we will be hitting the /contacts
endpoint. The full reference for that endpoint is here.
We need to pass a primaryIdentifier which in our case will be email, and a value, which is the email itself. So putting it together it will look something like this:
Step 3: Plug in your serverless function
Going back to our Serverless guide at Step 3, all we have to do now is add in our Holder function call: