Note
In order to run this application, you need to have a working Redis instance running.
- Clone the repository
- Set all required environment variables (as defined in
.env.example
) - Start your application
go run main.go
- Open your browser and go to
http://localhost:3000/
GET /list
curl http://localhost:3000/list?code=<AUTH_CODE>
POST /shorten
curl -X POST http://localhost:3000/shorten \
-d 'url=https://www.google.com'
GET /r/:shortUrl
curl http://localhost:3000/r/:shortUrl?code=<AUTH_CODE>
DELETE /d/:shortUrl
curl -X DELETE http://localhost:3000/d/:shortUrl