Closed kensac closed 10 months ago
E-mail service is complete and merged.
Created functions that handle basic pre-processing to make serve as an abstraction on top of the SendGrid client as we don't need too much functionality. Passed the service to app state so we can integrate with routes. closing issue however this needs firebase to be set up so that we can get templates.
This comment is a development update to keep track of progress.
As of this comment, we use mrml to read and process mjml files. This still needs the mjml file to be available locally because I haven't set up the firebase upload service. The mrml parses and reads the mjml templates and converts them to HTML for use by sendgrid-rs.
We use handlebars to populate all the handlebars in the HTML template. This is hardcoded test values right now but should be a pretty simple change when I implement the rest of the function.
I need to get rid of all the unwraps and switch to a more runtime friendly approach. I also need to test whether sendgrid-rs works locally and if there are any additional things we need to add to the sendgrid functionality.
Another check I need to make is whether the sendgrid rs has internal pooling. This can be of a few types :-
For type 1 and 2, we can add sendgrid to our state which will make sending e-mails very easy for developing routes. For type 3 we will have to explore (but I doubt type 3 is the case)