W
Wasp•8mo ago
Louis Deconinck

Dummy Email Provider OpenSaas

I will only be using Google OAuth for authentication and no email authentication (OpenSaas). Do I still need a email provider? The docs (https://docs.opensaas.sh/guides/email-sending/) state the following: "Note that your app will not build if using the Dummy provider and you must switch to a production-ready provider in order to do so."
OpenSaaS.sh
Email Sending
Open SaaS is a free, open-source, full-stack SaaS starter kit for React + NodeJS.
5 Replies
kapa.ai
kapa.ai•8mo ago
Hi @Louis Deconinck. I'm kapa.ai, your friendly support bot. I will try to answer your question by searching through the knowledge base. :wave: ---------------------- Yes, even if you are using Google OAuth for authentication, you still need an email provider. This is because Wasp uses the email provider for features like email verification and password reset flows. However, as you mentioned, the Dummy provider is not suitable for production use. It is only meant to be used during development. If you try building your app with the Dummy provider, the build will fail. For production, you need to switch to a production-ready provider. Wasp supports several email providers out of the box, including SMTP. Many transactional email providers (e.g. Mailgun, SendGrid but also others) can also use SMTP, so you can use them as well. Here is how you can set up the SMTP provider in your main.wasp file:
app Example {
...
emailSender: {
provider: SMTP,
}
}
app Example {
...
emailSender: {
provider: SMTP,
}
}
And then, add the following env variables to your .env.server file:
SMTP_HOST=
SMTP_USERNAME=
SMTP_PASSWORD=
SMTP_PORT=
SMTP_HOST=
SMTP_USERNAME=
SMTP_PASSWORD=
SMTP_PORT=
You can find more information about setting up email providers in the Wasp documentation (https://wasp-lang.dev/docs/advanced/email#providers). ---------------------- Note: you can ask me a follow up question by @ mentioning me again :speech_balloon: ---------------------- Sorry @Louis Deconinck, I seem to be having a bit of trouble. Don't worry though, I've pinged my support and they will try to fix me up! :technologist: Perhaps try again in 15mins?
Louis Deconinck
Louis DeconinckOP•8mo ago
@Wasp Team Kapa gives this as a reason why I still need an email provider: "This is because Wasp uses the email provider for features like email verification and password reset flows.". However I'm explicitly only using Google OAuth, so I assume that does not apply to me. Do I still need an email provider for using OpenSaas (the docs say I do, but I just don't know why).
miho
miho•8mo ago
@kapa.ai you have a non-sensical answer 😄 the user is not using email auth therefore not using email verification or passwod reset. If in your code base, the emailSender is used, then you need an email provider. If you are not using it in any way, you can omit the email sender. https://wasp-lang.dev/docs/advanced/email
Sending Emails | Wasp
With Wasp's email-sending feature, you can easily integrate email functionality into your web application.
kapa.ai
kapa.ai•8mo ago
Let me check the knowledge base for you. One moment! :books: ---------------------- I apologize for the confusion. If you're only using Google OAuth for authentication and not using any features that require sending emails (like email verification or password reset), then you don't need to set up an email provider in Wasp. The emailSender setup is required only if your application needs to send emails. If you're not using any such features, you can omit this setup from your main.wasp file. For more information, you can refer to the Wasp documentation (https://wasp-lang.dev/docs/advanced/email). ---------------------- Note: you can ask me a follow up question by @ mentioning me again :speech_balloon: ---------------------- Sorry @miho, I seem to be having a bit of trouble. Don't worry though, I've pinged my support and they will try to fix me up! :technologist: Perhaps try again in 15mins?
Filip
Filip•8mo ago
I see that all's been said here. @Louis Deconinck Any further questions on your side? 🙂
Want results from more Discord servers?
Add your server