erramirez / wearable

A fork of the fitbitr package

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

wearable

The wearable package allows users to interact with activity tracker data in R using device API.

Currently this package allows for read/write functionality for interacting with personal Fitbit data.

Installation

wearable isn't available from CRAN yet, but you can get it from github with:

# install.packages("devtools")
devtools::install_github("tracker-neRds/wearable")

Preparation

API key

To get your own token (API key), you have to register your own application in here. For your reference, we share our setting:

After registration, you can get your own FITBIT_KEY and FITBIT_SECRET (referred to as OAuth 2.0 Client ID and Client Secret in the next figure).

If you set the following variables as a global variable, this package will use these values for API key.

# As a global variable
FITBIT_KEY    <- "<your-fitbit-key>"
FITBIT_SECRET <- "<your-firbit-secret>"
# If you want, Default: "http://localhost:1410/"
# FITBIT_CALLBACK <- "<your-fitbit-callback>" 

Or, you can set these values as a environment variable

Sys.setenv(FITBIT_KEY = "<your-fitbit-key>", FITBIT_SECRET = "<your-firbit-secret>")

-->

About

A fork of the fitbitr package

License:MIT License


Languages

Language:R 100.0%