{"id":23522011,"url":"https://github.com/veerendra2/fitbit-cli","last_synced_at":"2025-04-19T19:43:35.151Z","repository":{"id":269610238,"uuid":"907087273","full_name":"veerendra2/fitbit-cli","owner":"veerendra2","description":"Access your Fitbit ⌚️ data at your terminal 💻","archived":false,"fork":false,"pushed_at":"2024-12-24T19:20:55.000Z","size":224,"stargazers_count":1,"open_issues_count":4,"forks_count":0,"subscribers_count":1,"default_branch":"main","last_synced_at":"2024-12-24T20:20:03.753Z","etag":null,"topics":["cli","fitbit","fitbit-api","pip","python"],"latest_commit_sha":null,"homepage":"","language":"Python","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/veerendra2.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2024-12-22T19:16:26.000Z","updated_at":"2024-12-23T15:51:42.000Z","dependencies_parsed_at":null,"dependency_job_id":"401e2b79-091a-4f04-a68c-54bf2cfefc4e","html_url":"https://github.com/veerendra2/fitbit-cli","commit_stats":null,"previous_names":["veerendra2/fitbit-cli"],"tags_count":2,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/veerendra2%2Ffitbit-cli","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/veerendra2%2Ffitbit-cli/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/veerendra2%2Ffitbit-cli/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/veerendra2%2Ffitbit-cli/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/veerendra2","download_url":"https://codeload.github.com/veerendra2/fitbit-cli/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":231150306,"owners_count":18335340,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["cli","fitbit","fitbit-api","pip","python"],"created_at":"2024-12-25T17:14:48.645Z","updated_at":"2025-04-19T19:43:35.131Z","avatar_url":"https://github.com/veerendra2.png","language":"Python","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Fitbit CLI\n\n[![Release](https://github.com/veerendra2/fitbit-cli/actions/workflows/release.yml/badge.svg)](https://github.com/veerendra2/fitbit-cli/actions/workflows/release.yml) [![PyPI - Status](https://img.shields.io/pypi/status/fitbit-cli)\n](https://pypi.org/project/fitbit-cli/) [![PyPI - Version](https://img.shields.io/pypi/v/fitbit-cli)\n](https://pypi.org/project/fitbit-cli/)\n\n\u003e This is not an official Fitbit CLI\n\nAccess your Fitbit data directly from your terminal 💻. View 💤 sleep logs, ❤️ heart rate, 🏋️‍♂️ activity levels, 🩸 SpO2, and more, all presented in a simple, easy-to-read table format!\n\n\u003cp align=\"center\"\u003e\n  \u003cimg alt=\"Fitbit logo\", width=\"250\" src=\"https://raw.githubusercontent.com/veerendra2/fitbit-cli/refs/heads/main/assets/Fitbit_Logo_White_RGB.jpg\"\u003e\n\u003c/p\u003e\n\n[![asciicast](https://asciinema.org/a/696114.svg)](https://asciinema.org/a/696114)\n\n## Supported Web APIs\n\n\u003e Only `GET` APIs are supported!\n\n| API                                                                                                                     | Status |\n| ----------------------------------------------------------------------------------------------------------------------- | ------ |\n| [User](https://dev.fitbit.com/build/reference/web-api/user/)                                                            | ✅     |\n| [Sleep](https://dev.fitbit.com/build/reference/web-api/sleep/)                                                          | ✅     |\n| [SpO2](https://dev.fitbit.com/build/reference/web-api/spo2/)                                                            | ✅     |\n| [Heart Rate Time Series](https://dev.fitbit.com/build/reference/web-api/heartrate-timeseries/)                          | ✅     |\n| [Active Zone Minutes (AZM) Time Series](https://dev.fitbit.com/build/reference/web-api/active-zone-minutes-timeseries/) | ✅     |\n| [Activity](https://dev.fitbit.com/build/reference/web-api/activity/)                                                    | ✅     |\n\n## Usage Guide\n\n1. Install the Fitbit CLI\n\n```bash\npython -m pip install fitbit-cli\n```\n\n2. Help\n\n```bash\nfitbit-cli -h\nusage: fitbit-cli [-h] [-i] [-s [DATE[,DATE]]] [-o [DATE[,DATE]]] [-e [DATE[,DATE]]] [-a [DATE[,DATE]]] [-u] [-v]\n\nFitbit CLI -- Access your Fitbit data at your terminal.\n\noptions:\n  -h, --help            show this help message and exit\n  -i, --init-auth       Initialize Fitbit iterative authentication setup\n  -v, --version         Show fitbit-cli version\n\nAPIs:\n  Specify date ranges (ISO 8601 format: YYYY-MM-DD) for the following arguments.\n  You can provide a single date or a range (start,end). If not provided, defaults to today's date.\n\n  -s, --sleep [DATE[,DATE]]\n                        Show sleep data\n  -o, --spo2 [DATE[,DATE]]\n                        Show SpO2 data\n  -e, --heart [DATE[,DATE]]\n                        Show Heart Rate Time Series data\n  -a, --active-zone [DATE[,DATE]]\n                        Show Active Zone Minutes (AZM) Time Series data\n  -u, --show-user-profile\n                        Show user profile data\n```\n\n3. Register Fitbit App\n\n   1. Go to [https://dev.fitbit.com/apps](https://dev.fitbit.com/apps)\n   2. Click on \"REGISTER AN APP\" tab\n   3. Follow below example and register an app\n\n     \u003cp align=\"left\"\u003e\n       \u003cimg alt=\"Fitbit logo\", width=\"700\" src=\"https://raw.githubusercontent.com/veerendra2/fitbit-cli/refs/heads/main/assets/fitbit-app-registration.png\"\u003e\n     \u003c/p\u003e\n\n4. Run the following command to set up interactive authentication and store the Fitbit token locally\n\n   ```bash\n    fitbit-cli --init-auth\n   ```\n\n   For a visual guide, see the Asciinema recording below\n   [![asciicast](https://asciinema.org/a/696115.svg)](https://asciinema.org/a/696115)\n\n5. Start using it 😎\n\n```bash\n$ fitbit-cli -s\n                                   Sleep Data Summary 😴\n┏━━━━━━━━━━━━┳━━━━━━━━━━━━━━┳━━━━━━━━━━━━━━━━┳━━━━━━━━━━━━━━┳━━━━━━━━━━━━━━┳━━━━━━━━━━━━━━━┓\n┃ Date 📆    ┃ Deep Sleep 🛏 ┃ Light Sleep 💤 ┃ REM Sleep 🌙 ┃ Wake Time ⏰ ┃ Efficiency 💯 ┃\n┡━━━━━━━━━━━━╇━━━━━━━━━━━━━━╇━━━━━━━━━━━━━━━━╇━━━━━━━━━━━━━━╇━━━━━━━━━━━━━━╇━━━━━━━━━━━━━━━┩\n│ 2024-12-25 │ 139 min      │ 190 min        │ 155 min      │ 54 min       │ 55%           │\n└────────────┴──────────────┴────────────────┴──────────────┴──────────────┴───────────────┘\n```\n\n_**NOTE: The token is valid for only 8 hours, `fitbit-cli` automatically refreshes the token when it expires.**_\n\n## Local Development\n\n- [Fitbit Docs](https://dev.fitbit.com/build/reference/web-api/)\n- [OAuth Tutorial](https://dev.fitbit.com/build/reference/web-api/troubleshooting-guide/oauth2-tutorial/)\n\n```bash\ngit clone git@github.com:veerendra2/fitbit-cli.git\ncd fitbit-cli\n\npython -m venv venv\nsource venv/bin/activate\npython -m pip install -e .\n```\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fveerendra2%2Ffitbit-cli","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fveerendra2%2Ffitbit-cli","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fveerendra2%2Ffitbit-cli/lists"}