Install node.js
-
Clone the repo
-
Run:
$ npm install
-
Create API keys for your planmill by visiting
https://online.planmill.com/{instance}/api/registrations.jsp
. Give it a Client ID and usehttp://localhost
as alowed redirect URIs -
Create config file
config.json
and fill in the missing information:{ "apiEndpoint": "https://online.planmill.com/{instance}/api/1.5", "tokenUrl": "https://online.planmill.com/{instance}/api/oauth2/token", "user": "{Client ID}", "pass": "{Client Secret}" }
You can place the config.json wherever you like and point to it using
--config
flag. Default search locations include current directory and~/.config/planmill/
-
Run
npm start
and enjoy! -
Make a symlink to a script that runs this app to your
/usr/local/bin
or similar to make this CLI available everywhere e.g.#!/bin/bash node /var/www/planmill-fetch/index.js