A REST API for shortening URLs
- MySQL instance with database named 'shrtr' (or whatever you choose)
git clone https://github.com/panutat/url-shortener.git
cd url-shortener
npm install
Update /config/development.json with your own MySQL credentials. Set 'cleanupAfterRestart' to false if persistence between API server restart is desired.
{
"db": {
"host": "127.0.0.1",
"user": "root",
"password": "root",
"database": "shrtr",
"cleanupAfterRestart": true,
"initialAutoIncrement": 11111111
}
}
npm run dev
npm run test
npm run lint