To get your OpenAps viewed onto your Nightscout site, start by using the following tool:(It would be a good idea to be disconnected from your pump and do a Bolus Wizard so you can check the status of your Nightscout uploading.) $nightscout autoconfigure-device-crud To view your data on your Nightscout site, start by doing the following:

$nightscout autoconfigure-device-crud <https://yourname.com yourplainapisecret>

So this would be your actual https://myname.azurewebsites.net or https://myname.herokuapp.com (without the carrots of course). Your API_SECRET is listed in your Azure or Heroku settings.

To test this: $openaps use ns shell preflight

To get aliases:

curl -sg https://gist.githubusercontent.com/bewest/d3db9ca1c144b845382c885138a8f66e/raw/181c5d6f29cd6489ecc9630786cf2c4937ddde79/bewest-aliases.json | openaps import

To pull data: $openaps gather-clean-data

To set up Nightscout reports:

curl -sg https://gist.githubusercontent.com/bewest/d3db9ca1c144b845382c885138a8f66e/raw/522155bae116983499bb1de30f10f52eb3c4b6b7/ns-reports.json | openaps import

To see your progress: $openaps do-everything

To add the Maximum Insulin On Board to be 2 units: oref0-mint-max-iob 2 max-iob.json

Then again, to check your progress: $openaps do-everything At this point, you should see treatment circles, information about the battery, etc.

To verify what was uploaded to Nightscout: $cat nightscout/uploaded.json

Then for the status: oref0 device-helper ns-status 'ns-status $*' | openaps import

Then: openaps use ns-status shell monitor/clock.json oref0-monitor/iob.json oref0-predict/oref0.json oref0-enacted/enacted-temp-basal.json monitor/battery.json monitor/reservoir.json monitor/status.json

You should see a lot of info. (Side note: the word “received” is spelled wrong.)

Make sure to save this as a report: openaps report add nightscout/openaps-status.json JSON ns-status shell monitor/clock.json oref0-monitor/iob.json oref0-predict/oref0.json oref0-enacted/enacted-temp-basal.json monitor/battery.json monitor/reservoir.json monitor/status.json

Now it needs to be invoked to test that it is getting data. openaps report invoke nightscout/openaps-status.json

Test uploading it: openaps use ns shell upload devicestatus.json nightscout/openaps-status.json

If it works, save it as a report: openaps report add nightscout/uploaded-recent-devicestatus.json JSON ns shell upload devicestatus.json nightscout/openaps-status.json added ns://JSON/shell/nightscout/uploaded-recent-devicestatus.json

Now those aliases we did earlier need adjustment for all of the recent work we just did: openaps alias add report-nightscout "report invoke nightscout/preflight.json nightscout/recent-treatments.json nightscout/uploaded.json nightscout/recent-missing-entries.json nightscout/uploaded-entries.json nightscout/openaps-status.json nightscout/uploaded-recent-devicestatus.json"

SUCCESS!!

To upload to Nightscout, use: $openaps do-everything To just test uploading to Nightscout, use: $openaps report-nightscout

Make sure to backup all the work you have just done: oref0 export-loop | tee backup-loop.json