interval / server

Interval Server is the central node used to run applications developed with the Interval SDK.
https://interval.com
MIT License
137 stars 44 forks source link

help@interval.com sender address prevents email/account confirmation #2

Closed redlumxn closed 10 months ago

redlumxn commented 11 months ago

In order to create Organization API Keys the account email needs to be confirmed. As per the documentation, a Postmark API key is required in order to send the emails. However, after creating a Postmark account and setting the key to the POSTMARK_API_KEY env var, I get the below error.

While your account is pending approval, all recipient addresses must share the same domain as the 'From' address. The domain of the 'From' address is 'interval.com', but you are attempting to send email to the following domain(s): 'MYCOMPANY.com'

Obviously this is a limitation on Postmark, but even when if the account is approved, I don't think emails should come from an interval.com address. It would be better to pass this as another env variable. I'm happy to submit a PR but wanted to check if there is anything else that needs to be taken into account.

This seems to be the line in question setting the from address:

https://github.com/interval/server/blob/0369bde42c7d2488234fd2f113b50817ae1d56bc/src/emails/sender.ts#L92

jacobmischka commented 11 months ago

Definitely an oversight on our part, this should be configurable as well.

tonyfromundefined commented 11 months ago

We are also trying to use interval, but are experiencing the same problem.

solumos commented 10 months ago

+1, looks like this is fixed in the main branch with #6 but it hasn't been published to npm

alexarena commented 10 months ago

Thanks for making the change @batuhan! Released to npm and Docker as 1.0.3 🙌