Goal: Build a project that demonstrates your ability to make GET and POST requests with any two APIs.
Completed the challenge? Share your project submission here.
- Fork this repository
- Edit the
readme.md
file - Add the link to your project's GitHub repo below the "Projects" heading (copy the example)
- Commit your changes
- Create a PR (pull request) to the
main
branch of my repo
Note:
- Make sure your repo is public
- Explain what your project does and how it works in your project
readme.md
file - Hide your private API keys
Tweet your project and tag @trycourier for a chance to win. Requirements:
- Project must use Courier API to send a notification
- Project must use one other API
- Offer is open for limited time
- Example_Project_Name: https://link_to_project
👻 Boo, the ghost, can only communicate with the real world through API requests. A very peculiar situation, but I don't make the rules. The most effective way to communicate with APIs is through notifications: 📧 emails, 💬 text messages, 📲 push notifications, 📳 direct messages, take your pick.
In index.js you will find "Ghostifications: Messages from the Afterlife", a simple Node.js project that allows 👻 Boo, the ghost, to communicate with the real world from the afterlife through 📞 notifications.
-
Create a Node.js app Create an empty file called
app.js
and add the following code to it:const http = require('http'); const hostname = '127.0.0.1'; const port = 3000; const server = http.createServer((req, res) => { res.statusCode = 200; res.setHeader('Content-Type', 'text/plain'); res.end('Hello World'); }); server.listen(port, hostname, () => { console.log(`Server running at http://${hostname}:${port}/`); });
-
Run your web server using the command
node app.js
You will get a response in the form of
Server running at <url>
-
Visit
http://localhost:3000
or the<url>
from the command's response to view itThe server will display "Hello World!", which you will recognize is from your app.js on line 9:
res.end('Hello World');
. Try changing the argument ofres.end()
to and re-run thenode app.js
command to see how you can manipulate your new app.