3

Scenario - scheduled reminders for auto-renew membership goes out

It notifies folk that 'hey your membership will auto renew in xx days'

but what if we want to include a link so they can cancel it?

Can this be done? What would it look like? Would it require a special token to be able to send the right crid?

1
  • I think this just won't be possible due to issues if contact has multiple CRID therefore perhaps best to send them to their civi 'user dashboard'
    – petednz - fuzion
    Feb 7 at 0:18

1 Answer 1

5

Technically it's possible to do using a token processor hook. Each membership is linked to contribution recur via civicrm_membership.contribution_recur_id so if you are using Membership entity for sending reminders you could use membership id to fetch contribution recur id and build the cancel subscription URL.

You could also use smarty to add logic inside the reminder message using the above logic if you don't want to go via hook implementation.

Note: Not all payment processor allows to cancel the subscription from Civi, however, the common ones do. In case it doesn't you will need to exclude the cancel subscription URL or build the cancel subscription URL of the payment gateway.

Edited: Also I found out now that you could generate cancel subscription using mid i.e membership id, civicrm/contribute/unsubscribe?reset=1&mid=123

HTH

Pradeep

2
  • Even mid can be used instead crid Feb 7 at 1:37
  • Thanks is pretty conprehensive!
    – Marsh
    Feb 8 at 21:33

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.