Thank you so much, I am a new dev and am trying to get a newsletter down and couldnt find much support with axios and other next tools and didnt really feel like reading docs. Your video broke it down a lot and explained it xtremely well. Good luck out there
but this is basically me messaging me ? when I check who sent the email it is the user we entered so how can random people mail me for my portfolio website?
Very nice tutorial! I did almost the same thing, but instead I used resend to send the emails. By the way, you're so fast using VIM. do you have any tutorial about how do you configured it?
I'd think about attack vectors. If someone were to abuse the endpoint what would happen? Who is damaged? How bad will it be? Most of the time a contact form is not going to be abused. You can also look into rate limits on the Mailgun side to protect against abuse. Of course, if an attacker *does* abuse the form, then implementing Google Captcha is a good solution to stop bots.
Hey! I made it close to the end but the only step that isn't working for me is the actual sending of the email: Error sending email: [Error: Unauthorized] { status: 401, details: 'Forbidden', type: 'MailgunAPIError' }
Thanks Ethan very much for your great session, i would like to ask if i would like to use Swagger openAPI in this session, is it possible? if yes which part should i replace it with swagger? i got a bit confused about swagger usage and how can i fit it inside my form ! thank you
@@ethan_mick oh yes it did. An idea for your next tuto : "creating an custom API for a webpage" you explanation is so clear so I would like to watch you explaining this stuff, this days working with APIs is important.
@@automioai Thanks! I do have a video on creating a REST API in Next.js: ru-vid.com/video/%D0%B2%D0%B8%D0%B4%D0%B5%D0%BE-Sv1b-P2dO2E.html Do you want to see something more? What would that be?
You'll need to hook that up server side with your email provider. For example, Mailgun (documentation.mailgun.com/en/latest/api-sending.html#sending) you can add an `attachment` key.
This depends a little bit your backend. Most services let you create a "mailing list" and you can just send a single email to that list. Otherwise, you'd need to iterate over the items in your database or service and send an email to each user.
Thanks! I'll add that to my list. If you want to see my old blog source code, you can check it out here: github.com/ethanmick/ethanmick.com (This is NO LONGER my blog, but might give you some ideas)