Adds new holders to a referral code as referees. The data sent in the request is upserted into the customer data.
If the request returns an error even for one customer, you have to resend the whole request. Customer data is upserted if the data for all customers is correct.
To use this endpoint, you must have the following permissions:
customers.modify)vouchers.publish)๐ To add a holder as a referrer, use the Create Publication endpoint.
๐ Alternative endpoint
This endpoint is an alternative to the Add Referral Code Holders endpoint. The URL was re-designed to retrieve the referral member holders without providing the
campaignIdas a path paremeter.
The access token received from the authorization server in the OAuth 2.0 flow.
Unique referral code or its identifier.
"MmFAzfDe"
Specify the customer data to be upserted as redeemable holders.
Request body schema for POST v1/referrals/{campaignId}/members/{memberId}/holders and POST v1/referrals/members/{memberId}/holders.
Array of holders to be added to a referral card as referees. You have to send at least one object in the array up to a maximum of 100 objects. You can send either a source_id or id, or both; however, at least one of them is required. If both are sent, Voucherify checks id to upsert that customer's data.
A set of custom key/value pairs that you can attach to the redeemable holders sent in the array. The value can be a string, number, boolean, date, datetime, image URL, or object. The metadata must meet the metadata schema for publications. The metadata object stores all custom attributes assigned to the redeemable holder.
Returns a list of redeemable holder objects.
Response body schema for POST v1/referrals/{campaignId}/members/{memberId}/holders and POST v1/referrals/members/{memberId}/holders.
Contains an array of referral card holders who are the customers sent in the request.