Skip to content
0:00 / 0:00

#node.js#restapi#httpmodule

Vanilla Node.js REST API | No Framework

Traversy Media

2.4M subscribers • 27 videos on Hallway

YouTube
  • Recommended by 2 people: 2 in engineering communities.
  • Presented by Brad Traversy
  • Linked in the descriptionbradtraversy/vanilla-node-rest-api
  • May be out of date. Uploaded 6 years ago, in an area where tools change fast.

Beginner. No background in the topic needed.

175K views6 years ago2 recommendations

Web developmentProgramming languagesNode.js, Deno and BunHTTP, REST and GraphQLJavaScript

Brad Traversy demonstrates how to build a REST API using only vanilla Node.js and the built-in HTTP module without any frameworks.

Let's create a REST API using Node.js only, without Express Code: github.com/bradtraversy/vanilla-node-rest-api 💖 Support The Channel! patreon.com/traversymedia Website & Brad Traversy Udemy Course Links: traversymedia.com Follow Traversy Media: twitter.com/traversymedia instagram.com/traversymedia facebook.com/traversymedia Timestamps: - Intro - Getting Started - HTTP Create Server - Send a Simple Response - Simple Routing - Create The Model & Controller - Get All Products - Get Product By ID - Create Product - Getting Body Data - Updating Products - Deleting Products

Why it's here

2 people recommend this

What people say. Recommended for understanding what Express does under the hood by building a REST API with vanilla Node.js.

u/Notimecelduvin r/node • Recommends

On “Learn Node before Express?”

I recommend this Traversy Media tutorial where he builds a Rest API with Node without a framework. It should give you a decent grasp of what's happening under the hood when working with Express. I think most of us would agree you don't have to be a Node whizz before starting out with Express. You just need to be familiar with the JS syntax and the common built-in modules (path, os, http and maybe a few others).

u/CraftyAdventurerin r/node • Recommends

On “Do you ever use node without express (or an equivalent framework?)”

Traversy media recently did a tutorial on building a REST API without express. It's a nice video to see what are some things that express does. Video here

u/CraftyAdventurerin r/node • Recommends

On “Can someone share some youtube links or from any other platform where the creator builds things with just http instead of using express”

link to this video

u/Anbaraenin r/node • Mentions

On “how to send csv file from postman to nodejs?”

Sorry, I didn't fully understand your question. My understanding of what you're asking: * You are running a Node.js server * You are running Postman * You want to send (POST) a CSV file from Postman into Node.js and then do something with the response. Here's the minimal amount of code to do this; const http = require("http") const PORT = 8989 const httpServer = http.createServer((req, res) => { let body = '' req.on('data', (chunk) => { body += chunk.toString() }) req.on('end', () => { // do something with the 'body' variable, this now contains your entire CSV as a string. // as an example, I'm sending it right back to the c…