- AdonisV5
- Typescript
- Postgres
- VS Code with EditorConfig, ESLint and Prettier
To clone and run this application, you'll need Git, Node.js >= v14.16.x installed on your computer.
From your command line:
# Clone this repository
$ git clone [email protected]:luizxsoto/wiser-challenge-shortener.git
# Go into the repository
$ cd wiser-challenge-shortener
# Install dependencies
$ npm i
# Test the app
$ npm run test
# Run the app
$ npm run dev
- Shorten URL
-
Min length: 5 and Max length: 10
-
Only letters and numbers
-
Save in database
-
Redirect when getting shortened url
-
Tests
-
Expected behavior:
// request body { "url": "http://wisereducacao.com" } // response body { "new_url": "http://localhost:8081/abc123ab" }
- Shortened url expiration date: 60 seconds