API that returns an integer value in a specific range.
Parrot requires Node.js to run. It also uses nodemon for development.
$ npm install
$ npm run dev
$ npm start
An official image is available at Docker Hub
A docker configuration file is provided so that an image can also be built.
$ docker build -t randomizer .
$ docker run --rm -ti -p 3000:3000 randomizer
Randomizer can be called with min, max or no parameters.
Examples:
$ curl -X GET 'http://localhost:3000/random'
2562129742708042
$ curl -X GET 'http://localhost:3000/random?max=10'
3
$ curl -X GET 'http://localhost:3000/random?max=10&min=5'
8