Jisan-mia / rest-api

Rest api from scratch with deno

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Routing on the Server

Ways to define routes

  • Conditionally route requests (if/else, switch, regex, URLPattern)
  • Different responses, Different requests
  • Split up our Server code by function

Networking Topics

What happens when we make a request to: https://www.google.com

First let's learn what is URL?

  • URL -> Uniform Resource Locater
  • different parts of a url is shown below image

URL

DNS

  • DNS -> Domain Name System

Alt text

IP Address

  • IP -> Internet Protocol

Alt text

Network Ports

Alt text


Alt text

Network Protocols: Rules of communication(across networks)

  • HTTP/HTTPS
  • TCP/UDP
  • IP
  • ...many more

OSI Model

Alt text

HTTP 1.1

Alt text

HTTP 2

Alt text

Basic HTTP Headers

Alt text

HTTP headers characteristics

Alt text

HTTP Request Methods

Alt text

HTTP Response status codes

Alt text

HTTPS: Secure version of HTTP

Alt text

TCP: Transmission Control Protocol

Alt text

TCP Headers

Alt text

UDP: User Diagram Protocol, alternative to tcp

Alt text

UDP Headers

Alt text

IP: Internet Protocol

Alt text

IP Headers

Alt text

MIME Types

Alt text

NB: All the above images were collected from Tech with Nader's rest-api tutorial

About

Rest api from scratch with deno


Languages

Language:TypeScript 95.5%Language:HTML 4.5%