Ive been trying to add a registration successfull email feature to my node js user login project.Please help.
i used the following code:
var SGmail = require('@sendgrid/mail')
SGmail.setApikey("SG.XXXX");
const msg = {
to: '@gmail.com',
from: '@gmail.com',
subject: 'Sending with Twilio SendGrid is Fun',
text: 'and easy to do anywhere, even with Node.js',
html: 'and easy to do anywhere, even with Node.js',
};
sgMail.send(msg);
Hello @emilfrancis2027,
Can you please verify what version of this SDK you are using?
If you hare on the latest version, then this example should work for you.
Thanks!
With Best Regards,
Elmer
I actually made a pretty stupid mistake .the K in setApiKey should be in uppercase ,i mistyped that.
Thanks a lot for replying Elmer
I actually made a pretty stupid mistake .the K in setApiKey should be in
uppercase ,i mistyped that.
On Tue, May 28, 2019 at 11:27 PM Elmer Thomas notifications@github.com
wrote:
Hello @emilfrancis2027 https://github.com/emilfrancis2027,
Can you please verify what version of this SDK you are using?
If you hare on the latest version, then this example
https://github.com/sendgrid/sendgrid-nodejs/blob/master/use-cases/single-email-single-recipient.md#send-a-single-email-to-a-single-recipient
should work for you.Thanks!
With Best Regards,
Elmer
—
You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub
https://github.com/sendgrid/sendgrid-nodejs/issues/936?email_source=notifications&email_token=AMFOC374RSHGYVA5227J2GLPXVXARA5CNFSM4HPWFWP2YY3PNVWWK3TUL52HS4DFVREXG43VMVBW63LNMVXHJKTDN5WW2ZLOORPWSZGODWM54GA#issuecomment-496623128,
or mute the thread
https://github.com/notifications/unsubscribe-auth/AMFOC3YFXK4BNOUVM4TDSATPXVXARANCNFSM4HPWFWPQ
.
Thanks for following up!
Most helpful comment
Thanks a lot for replying Elmer
I actually made a pretty stupid mistake .the K in setApiKey should be in
uppercase ,i mistyped that.
On Tue, May 28, 2019 at 11:27 PM Elmer Thomas notifications@github.com
wrote: