REST API Changes

The REST API requires some more involved changes, but should still be relatively straightforward. Most of the payload structure remains the same with one exception (see below). The main change is how a user is authenticated via the API.

Authentication

Rejoiner 1 required generating an HMAC key based on an API Key,API Secret, the request method, and the request payload. Rejoiner 2 moves to a simpler, token-based API Key. To authenticate a request, you can simply set the Authorization HTTP Header to "Rejoiner YOUR_API_KEY".

Example:

curl -H "Authorization: Rejoiner YOUR_API_KEY" "https://rj2.rejoiner.com/api/v1/YOUR_SITE_ID/ping/"

Endpoint URLs

Most of the endpoint URLs have changed. This is necessary since Rejoiner 2 is a separate application. You can find a mapping of the Rejoiner 1 URLs to the Rejoiner 2 URLs below:

ENDPOINT REJOINER 1 URL REJOINER 2 URL
Convert Customer /api/1.0/site/SITE_ID/lead/convert /api/v1/SITE_ID/customer/convert/
Cancellation /api/1.0/site/SITE_ID/lead/cancel /api/v1/SITE_ID/customer/cancel/
Unsubscribe Customer /api/1.0/site/SITE_ID/lead/unsubscribe /api/v1/SITE_ID/customer/unsubscribe/
Record Consent /api/1.0/site/SITE_ID/lead/opt_in /api/v1/SITE_ID/customer/opt_in/
Add-To-List /api/1.0/site/SITE_ID/contact_add /api/v1/SITE_ID/lists/LIST_ID/contacts/
Retrieve Lists /api/1.0/site/SITE_ID/lists /api/v1/SITE_ID/lists/

Still need help? Contact Us Contact Us