Skip to content

Send email with sendgrid. #3677

Closed Answered by thephpguy
thephpguy asked this question in Q&A
Apr 1, 2023 · 2 comments · 2 replies
Discussion options

You must be logged in to vote

Had another looksee at the code and realized it takes an object. Looks like the documentation is out of date on this.

Here is how I got it to work:

  const o = {
    templateId: 'd-a7d630b2dede0',
    from: 'support@m...ventures.com',
    to: 'b@th...uy.com',
    data: { test: "test"}
  };

  const x = await sendgridService.sendEmail(o);

Replies: 2 comments 2 replies

Comment options

You must be logged in to vote
2 replies
@srindom
Comment options

@thephpguy
Comment options

Answer selected by srindom
Comment options

You must be logged in to vote
0 replies
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
2 participants