Untitled
unknown
plain_text
a month ago
591 B
2
Indexable
import { Resend } from 'resend' const resend = new Resend(process.env.RESEND_API_KEY) export async function POST() { try { const { data, error } = await resend.emails.send({ from: 'Wealth Farming Dev <no-reply@mail-resend.wealthfarming.org>', to: ['mynameismrbinh@gmail.com'], subject: 'Hello world', text: 'Hello WF dev.... content here', }) if (error) { return Response.json({ error }, { status: 500 }) } return Response.json(data) } catch (error) { return Response.json({ error }, { status: 500 }) } }
Editor is loading...
Leave a Comment