[Org] Onboarding welcome emails
@leowilkin is working on sending "welcome" emails to users who have just been onboarded. Here's a draft he sent me:
@leowilkin, go ahead and create an Event::OnboardingMailer. I'll then help with the scheduling of these emails.
You can get Rails to do most of the work for you by running:
bin/rails g mailer event/onboarding
It'll generate these files:
create app/mailers/event/onboarding_mailer.rb
invoke erb
create app/views/event/onboarding_mailer
create app/views/layouts/event/mailer.text.erb
create app/views/layouts/event/mailer.html.erb
- You can delete app/views/layouts/event/mailer.text.erb
- In app/views/layouts/event/mailer.html.erb, get rid of the HTMl shell and just put in the body of your email. Our mailer layout will handle the HTML shell.
If anyone wants to help me with this, would be appreciated! I have little to no idea what I'm doing, and absolutely no idea how to test this :)
I guess things I need help with:
- Making sure they're formatted correctly
- How/what nomenclature do I use for the second email?
- How do I put variables, like name, org name, and slug into the body?
- How do I test this? Thanks!!
I am more of a TypeScript backend dev than a Ruby on Rails dev, but I could help with email debugging on local dev/Codespaces regarding templating, but right now I am currently cooked at school. (Subscribing to this issue by the way for tracking process)
Making sure they're formatted correctly How do I test this?
https://guides.rubyonrails.org/action_mailer_basics.html#previewing-and-testing-mailers
How do I put variables, like name, org name, and slug into the body?
https://www.puppet.com/docs/puppet/5.5/lang_template_erb
Just make sure you declare your variables as instance variables (they begin with @), eg. @event
Small suggestion: IMO the email looks quite generic with the email layout, might be worth making it a text-only email instead? (Without the header/footer)
Also would be worth making the from name/address the name/email address of the person doing the onboarding (although I’m not sure how feasible this is)
Also would be worth making the from name/address the name/email address of the person doing the onboarding (although I’m not sure how feasible this is)
This is very do-able, you set the from parameter
@garyhtou is there anything I can do from my end to get this closer to prod? I appreciate you'll be a bit busy with the new flow & Mel.
Thanks @leowilkin! I have @rluodev helping out a bit. I'll finish this up next week.
Update: Originally, there are supposed to be two emails. The first being "Get started on HCB". the second being "how to build a website".
After talking with Mel, we're dropping the "how to build a website" email.
This was largely handled by the combination of:
- https://github.com/hackclub/hcb/pull/10933
- and our "please sign the contract" email
Are there any changes we'd like to make to the current system? Or are we satisfied for the time being?
@Luke-Oldenburg would be amazing if you could take this, and maybe work with @alexdevz to make a video that gets sent out once an organization is activated/person acceps invite with a Loom style v. short onboarding & highlight the key features of HCB?
Edit: like this, but for features! https://youtu.be/QTwhJy7nT_w
Would it be cool if we did something like this, @garyhtou: https://www.moxo.com/lp/client-onboarding
make a video that gets sent out once an organization is activated/person acceps invite with a Loom style v. short onboarding & highlight the key features of HCB?
Edit: like this, but for features! youtu.be/QTwhJy7nT_w
I don't mind doing this for continuity from the initial videos!