https://github.com/tadeubdev/url-shortener
A simple url shortener
https://github.com/tadeubdev/url-shortener
Last synced: over 1 year ago
JSON representation
A simple url shortener
- Host: GitHub
- URL: https://github.com/tadeubdev/url-shortener
- Owner: tadeubdev
- Created: 2021-12-23T16:37:35.000Z (over 4 years ago)
- Default Branch: master
- Last Pushed: 2021-12-23T17:01:36.000Z (over 4 years ago)
- Last Synced: 2025-02-09T11:26:26.028Z (over 1 year ago)
- Language: TypeScript
- Size: 3.91 KB
- Stars: 0
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
URL Shortener
-----
This repository is part of the challenge [Encurtador de URLs](https://github.com/backend-br/desafios/tree/master/1%20-%20Easy/Encurtador%20de%20URL) by [backend-br](https://github.com/backend-br).
The challenge is to make a simple API in any language or any framework, that receive a url passed by a POST request and return this url shortened.\
After that, when someone acccess this shortened url, they need to be redirected to the primary url or to an 404 page.\
A shortened url can have a expiration time that can be defined for us.
**e.g.:**
```
[POST] api/short
{ url: 'http://google.com' }
Return: { newUrl: 'http://localhost/123asdf456' }
[GET] http://localhost/123asdf456
Redirect to: https://google.com
```