Fitbit Developers oversee the SDK and API forums. We're here to answer questions about Fitbit developer tools, assist with projects, and make sure your voice is heard by the development team.
Today is another exciting landmark in the evolution of the Fitbit OS Software Development Kit (SDK). We’re proud to announce a major enhancement: an entirely new way to build apps and clock faces for Fitbit OS. We have created a command-line interface that is compatible with macOS, Windows, and Linux, and allows developers to build and install Fitbit OS projects while using their favorite code editors, and their preferred version control system. This update takes Fitbit OS app development beyond Fitbit Studio for the very first time.
https://dev.fitbit.com/blog/2018-08-23-cli-tools/
Hi Jon,
Eager to get this running, but I can't get past the login step. The video shows the user already logged in, but the video says a browser will pop up with login. My browser does not launch so I can't log in and run the app on the sim.
sfo-m-vg0qvh:~$ npx fitbit
npx: installed 3 in 2.362s
command not found: fitbit
If I create a new project everything works perfectly as described. This only happened on a project that I downloaded from Studio.
Best Answer
Fitbit Developers oversee the SDK and API forums. We're here to answer questions about Fitbit developer tools, assist with projects, and make sure your voice is heard by the development team.
Found the isssue:
npm add --dev @Fitbit/sdk-cli
Missed the second step. Assumed the section on updating existing projects was all I needed to know. I got the sdk installed but not the cli.
Thanks! This is awesome !
Best AnswerHi,
Does anyone know why I am getting:
Fetch of https://api.fitbit.com/1/user/-/developer-relay/hosts/undefined returned status 404 Not Found
When I issue "$fitbit install"
I built and connected the Ionic.
Thanks!
Itamar
Best AnswerRe the prerequsites, git also seems to be mandatory.
npx create-fitbit-app...doesn't work for me without it.
If this is the case, could I suggest that the documentation be updated?
Fitbit Developers oversee the SDK and API forums. We're here to answer questions about Fitbit developer tools, assist with projects, and make sure your voice is heard by the development team.
Fitbit Developers oversee the SDK and API forums. We're here to answer questions about Fitbit developer tools, assist with projects, and make sure your voice is heard by the development team.
@Gondwana sorry about that, it seems it was added as a last minute dependency due to an known issue with one of the other dependencies (source-map). We'll drop that requirement once they publish their fix.
@JonFitbit wrote:@ihassin please run the following command from your project folder, and paste the output.
FITBIT_QA_COMMANDS=1 npx fitbit hosts
Best Answer
@JasonShort wrote:Can I make a request for a command that builds and loads the app in one step?
> npx fitbit-run
Hey Jason,
I too don't want to have the REPL dialog within fitbit$... Until Fitbit fixes this, I came up with an expect script:
#!/usr/bin/expect -f
#set timeout -1
spawn ./fitbit-cli.sh
expect "fitbit"
send -- "install\n"
expect "fitbit"
send -- "exit\r"
expect eof
fitbit-cli.sh:
#!/usr/bin/env bash
npx fitbit-build
npx fitbit
Check out in the demo app.
Initial experience with the CLI and Visual Studio Code is great, but why oh why no real time debugging/breakpoint support? Can you work on this next please!
Also, do I have to use GitHub, or can I use Git with Visual Studio Online?
> Also, do I have to use GitHub, or can I use Git with Visual Studio Online?
You can use any version control system and git hosting service you like. It has nothing to do with CLI tools.
Best Answer
Fitbit Developers oversee the SDK and API forums. We're here to answer questions about Fitbit developer tools, assist with projects, and make sure your voice is heard by the development team.
@JonFitbit wrote:@ihassin please run the following command from your project folder, and paste the output.
FITBIT_QA_COMMANDS=1 npx fitbit hosts
I tried doing this to see if I could get any clues about why my runtime output was in terms of build files/lines rather than source-mapped. Unfortunately, I couldn't find FITBIT_QA_COMMANDS anywhere. Is this a linux-specific thing?
Best Answer
Fitbit Developers oversee the SDK and API forums. We're here to answer questions about Fitbit developer tools, assist with projects, and make sure your voice is heard by the development team.
I tried doing this to see if I could get any clues about why my runtime output was in terms of build files/lines rather than source-mapped. Unfortunately, I couldn't find FITBIT_QA_COMMANDS anywhere. Is this a linux-specific thing?
It's not linux specific.
We're aware of some issues with source-mapping line numbers, hopefully it should be fixed in a upcoming update.
We're aware of some issues with source-mapping line numbers, hopefully it should be fixed in a upcoming update.
Thanks Jon; that would make be very happy!
I'm mystified about why I can't find FITBIT_QA_COMMANDS; makes me wonder whether there's something wrong with my installation.
Best AnswerFWIW, sussed it on Windows:
set FITBIT_QA_COMMANDS=1 npx fitbit
Best Answer