With Drupal and Civi latest, is it possible to send an email with a one-time login url?
We have a scenario in which an admin grants a membership to a new contact. We want this new contact to automatically be given a new user account, and the correct role for their membership, and then send them an email giving them details about their new membership, as well as how to access their membership materials. (Their membership materials are on Drupal pages that are only visible to that membership's role).
So far we've succeeded in all of the above, using Drupal Rules.
However, to make their life easier I'd like to send them a one-time login so they can quickly make a password and get on with their life!
I'd prefer not to use the Drupal 'New Account' email for this purpose, since that has to be the same for all possible new users of the site. Also, we looked into not creating a user for them, and just sending them to the Drupal new user registration page. But that's clunky and these users are not internet savvy; they get lost.
In Drupal rules' 'Send HTML Email' action there is a token for the one-time user login: civicrm-user:one-time-login-url. However, it's not populated. And inspecting $civicrm_user via php print_r in the email shows no sign of this variable.
I did wonder if CiviRules could do all of the above, but I can't see any way to make a user from it, nor any token for a one-time user login - quite naturally since this would be a Drupal thing.
So... any ideas about how to progress this? I'm grateful for your thoughts.