Created
April 1, 2021 16:06
-
-
Save estebanmunchjones2019/1356264b1cc04f3090ef0026b19ccd4a to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// pages/api/subscription.js | |
export default function handler(req, res){ | |
//some code here to save the email to a database | |
const email = req.body.email; | |
return res.status(200).json({text: `${email} successfully subscribed`}); | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment