Newer Version Available
ReferralsRepository
The ReferralsRepository interface invokes and
manages referral-related REST API requests. Use this class to interact with the Salesforce
Referral Marketing APIs and manage referral-related operations.
Methods
enrollNewCustomerAsAdvocateOfPromotion
Enroll a new member to a given promotion.
| Parameter | Type | Description |
|---|---|---|
| country | String | The name of the country of the member. |
| String | Required. The email ID of the member. | |
| enrollmentChannel | String | Channel used to join the referral program. Possible values are:
|
| firstName | String | Required. The first name of the member. |
| lastName | String | Required. The last name of the member. |
| memberStatus | String | Status of the new advocate after enrollment. Possible values are:
|
| promotionName | String | Required. The promotion name to enroll for. |
| promotionCode | String | Required. The promotion code to enroll for. |
| state | String | The name of the state of the member. |
| transactionalJournalFrequency | String | Frequency at which transaction statements must be generated for the advocate.
Possible values are:
|
| transactionalJournalMethod | String | Preferred method of receiving transaction journal statements. Possible values are: |
enrollExistingAdvocateToPromotionWithMembershipNumber
Enroll an existing member to a given promotion using the membership number.
| Parameter | Type | Description |
|---|---|---|
| promotionName | String | Required. The promotion name to enroll for. |
| promotionCode | String | Required. The promotion code to enroll for. |
| membershipNumber | String | Required. The membership number of the existing member. |
enrollExistingAdvocateToPromotionWithContactId
Enroll an existing member to a given promotion using the contact ID.
| Parameter | Type | Description |
|---|---|---|
| promotionName | String | Required. The promotion name to enroll for. |
| promotionCode | String | Required. The promotion code to enroll for. |
| contactId | String | Required. The contact ID of the existing member. |
enrollExistingAdvocateToNewPromotion
Enroll an existing member to a new promotion.
| Parameter | Type | Description |
|---|---|---|
| promotionName | String | Required. The promotion name to enroll for. |
| promotionCode | String | Required. The promotion code to enroll for. |
sendReferrals
Send referral emails to the given recipients.
| Parameter | Type | Description |
|---|---|---|
| referralCode | String | Required. The referral code to share with the recipients. |
| emails | List<String> | Required. A list of recipient emails to share the referral code with. |