Answers.Body: <p>I think the unsubscribe link either needs mailing id or group id. The other option would be to create a profile with groups and opt-out field. And the include the profile as a unsubscribe link </p>
  
  <pre><code>https://example.com/civicrm/profile/edit?reset=1&amp;gid=2&amp;id={contact.contact_id}&amp;{contact.checksum}
  </code></pre>
  
  <p>Where gid is a profile id.</p>
  
  <p>Cheers</p>
  
  <p>Pradeep</p>
  
Answers.ContentLicense: CC BY-SA 4.0
Answers.CreationDate: 2019-05-09T18:34:57.213Z
Answers.LastActivityDate: 2019-05-09T18:34:57.213Z
Answers.UserDisplayName: Pradeep Nayak
Body: <p>I would like to send a transactional email with unsubscribe/opt-out url included. It usually gets triggered by civirules when the person gets added to a group. when email is sent the unsubscribe url does not render. civirules have suggested I hardcode the link. I have tried <code>https://example.com/civicrm/mailing/unsubscribe?reset=1&amp;cid={contact.contact_id}&amp;{contact.checksum}</code>
  But with this link I get "Missing Parameters" errors. What is missing here? thanks</p>
  
Tags: <email><civirules>
Title: How to hardcode the unsubscribe /optout URL in a transactional email?
ThreadText: # How to hardcode the unsubscribe /optout URL in a transactional email?
  
  (Asked by: username_0 on 2019-05-09)
  
  I would like to send a transactional email with unsubscribe/opt-out url included. It usually gets triggered by civirules when the person gets added to a group. when email is sent the unsubscribe url does not render. civirules have suggested I hardcode the link. I have tried `https://example.com/civicrm/mailing/unsubscribe?reset=1&cid={contact.contact_id}&{contact.checksum}`
  But with this link I get "Missing Parameters" errors. What is missing here? thanks
  
  **Tags:** email, civirules
  
  
  ---
  
  ## 1 answers
  
  ### Answer by username_1 on 2019-05-09. Score: 1
  
  I think the unsubscribe link either needs mailing id or group id. The other option would be to create a profile with groups and opt-out field. And the include the profile as a unsubscribe link
  
  ```
  https://example.com/civicrm/profile/edit?reset=1&gid=2&id={contact.contact_id}&{contact.checksum}
  
  ```
  
  Where gid is a profile id.
  
  Cheers
  
  username_1
  
  
  ---
  
  