Skip to content

ticachica/ja-urlshortener-ms

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

7 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

API Basejump: URL Shortener

Free Code Camp project built on glitch using mongodb on mLab.

User Stories:

  • I can pass a URL as a parameter and I will receive a shortened URL in the JSON response
  • When I visit that shortened URL, it will redirect me to my original link.

Example creation usage

https://ja-urlshortener-ms.glitch.me/new/https://www.google.com

https://ja-urlshortener-ms.glitch.me/new/http://freecodecamp.com/news

Example creation output:

{ "original_url": "http://freecodecamp.com/news", "short_url": "https://ja-urlshortener-ms.glitch.me/4" }

Usage:

https://ja-urlshortener-ms.glitch.me/4

Will redirect to:

http://freecodecamp.com/news