Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

SuperTokens SMTP Delivery - Nodemailer #848

Closed
DarkNeedle opened this issue May 29, 2024 · 4 comments
Closed

SuperTokens SMTP Delivery - Nodemailer #848

DarkNeedle opened this issue May 29, 2024 · 4 comments

Comments

@DarkNeedle
Copy link

Appears SuperTokens depends on Nodemailer for SMTP delivery (standard SMTP server)? Defining SMTP server info using the passwordless example results in:

Error: The edge runtime does not support Node.js 'stream' module. (This appears to be from Nodemailer as it does not support Edge runtimes).

@rishabhpoddar
Copy link
Member

Hey. We are aware of this issue. To et around this, you can define your own custom sendEmail function (https://supertokens.com/docs/passwordless/email-delivery/custom-method) in which you can use any library you like to send emails.

@DarkNeedle
Copy link
Author

DarkNeedle commented May 29, 2024

Is there any plans to address, even if embedding a custom SMTP library ? This issue seems to be hanging around for 1yr+

Did this ever work?
https://supertokens.com/docs/passwordless/email-delivery/smtp/configure-smtp

It's in the documentation, the default generated code its SuperTokens servers via API. The fact this SMTP delivery option is document but seems not to work is puzzling. Again, issue pending 1yr+

@rishabhpoddar
Copy link
Member

It works for non edge cases. I agree that the issue has been open since one year, however, since there is a rather straightforward workaround, it's very low in our list of priorities.

@rishabhpoddar
Copy link
Member

So there does not seem to be library that supports edge runtime, so instead, you should use an email sending service like AWS SES, mailchimp, sendgrid or resend. To use these, you can override the sendEmail function in the backend config and call the APIs for these services: https://supertokens.com/docs/passwordless/email-delivery/custom-method

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants