@molecule/api-wearable-fitbit 1.0.4 → 1.0.5
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +8 -1
- package/package.json +2 -2
package/README.md
CHANGED
|
@@ -3,7 +3,7 @@ AUTO-GENERATED — DO NOT EDIT THIS FILE.
|
|
|
3
3
|
Generated by `mlcl sync-docs` from the package's src/index.ts JSDoc + mlcl/registry.json.
|
|
4
4
|
Edits here are overwritten on the next commit (molecule's pre-commit hook regenerates).
|
|
5
5
|
To change this document, edit the module-level JSDoc in src/index.ts.
|
|
6
|
-
Generated: 2026-
|
|
6
|
+
Generated: 2026-11-08T06:02:57.686Z
|
|
7
7
|
-->
|
|
8
8
|
|
|
9
9
|
# @molecule/api-wearable-fitbit
|
|
@@ -445,6 +445,7 @@ error path must be sanitized.
|
|
|
445
445
|
interface WearableProvider {
|
|
446
446
|
/** Stable provider key used for credential-store segregation, e.g. `"fitbit"`. */
|
|
447
447
|
readonly providerName: string
|
|
448
|
+
|
|
448
449
|
/**
|
|
449
450
|
* Reads the daily activity rollup for `(userId, date)`.
|
|
450
451
|
*
|
|
@@ -453,6 +454,7 @@ interface WearableProvider {
|
|
|
453
454
|
* @returns Normalized daily activity.
|
|
454
455
|
*/
|
|
455
456
|
getDailyActivity(userId: string, date: WearableDate): Promise<DailyActivity>
|
|
457
|
+
|
|
456
458
|
/**
|
|
457
459
|
* Reads sleep sessions bucketed under `(userId, date)`. Most days return
|
|
458
460
|
* a single primary session; multi-nap days return multiple.
|
|
@@ -462,6 +464,7 @@ interface WearableProvider {
|
|
|
462
464
|
* @returns All sleep sessions bucketed under that day.
|
|
463
465
|
*/
|
|
464
466
|
getDailySleep(userId: string, date: WearableDate): Promise<SleepSession[]>
|
|
467
|
+
|
|
465
468
|
/**
|
|
466
469
|
* Reads the daily heart-rate summary for `(userId, date)`.
|
|
467
470
|
*
|
|
@@ -470,6 +473,7 @@ interface WearableProvider {
|
|
|
470
473
|
* @returns Normalized daily heart-rate summary.
|
|
471
474
|
*/
|
|
472
475
|
getDailyHeartRate(userId: string, date: WearableDate): Promise<HeartRateSummary>
|
|
476
|
+
|
|
473
477
|
/**
|
|
474
478
|
* Reads body-weight entries for the user across `range`. Providers cap
|
|
475
479
|
* how far back a single call may reach — implementations should clamp
|
|
@@ -481,6 +485,7 @@ interface WearableProvider {
|
|
|
481
485
|
* @returns Weight entries, ordered by `recordedAt` ascending.
|
|
482
486
|
*/
|
|
483
487
|
getWeight(userId: string, range: WearableDateRange): Promise<WeightEntry[]>
|
|
488
|
+
|
|
484
489
|
/**
|
|
485
490
|
* Exchanges an OAuth authorization `code` for tokens and persists the
|
|
486
491
|
* resulting {@link UserConnection} via the bond's credentials store.
|
|
@@ -490,6 +495,7 @@ interface WearableProvider {
|
|
|
490
495
|
* @returns The freshly-minted connection (already persisted).
|
|
491
496
|
*/
|
|
492
497
|
connect(userId: string, code: string): Promise<UserConnection>
|
|
498
|
+
|
|
493
499
|
/**
|
|
494
500
|
* Forces a refresh of the user's access token using the stored refresh
|
|
495
501
|
* token. The rotated connection is persisted before being returned.
|
|
@@ -498,6 +504,7 @@ interface WearableProvider {
|
|
|
498
504
|
* @returns The rotated connection (already persisted).
|
|
499
505
|
*/
|
|
500
506
|
refreshConnection(userId: string): Promise<UserConnection>
|
|
507
|
+
|
|
501
508
|
/**
|
|
502
509
|
* Revokes (best-effort) and removes the user's connection record.
|
|
503
510
|
*
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@molecule/api-wearable-fitbit",
|
|
3
|
-
"version": "1.0.
|
|
3
|
+
"version": "1.0.5",
|
|
4
4
|
"description": "Fitbit Web API bond for molecule.dev — daily activity, sleep, heart-rate, and weight ingestion via OAuth 2.0 PKCE",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"main": "dist/index.js",
|
|
@@ -38,7 +38,7 @@
|
|
|
38
38
|
},
|
|
39
39
|
"devDependencies": {
|
|
40
40
|
"@molecule/api-bond": "1.0.4",
|
|
41
|
-
"@molecule/api-http": "1.0.
|
|
41
|
+
"@molecule/api-http": "1.0.5",
|
|
42
42
|
"@molecule/api-wearable": "1.0.3",
|
|
43
43
|
"@types/node": "26.6.5",
|
|
44
44
|
"typescript": "6.0.3",
|