@bikefinder/sdk 0.6.0 → 0.8.0
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 +4 -2
- package/dist/device-schema.d.ts +48 -199
- package/dist/device-schema.js +56 -237
- package/dist/generated/index.d.ts +1 -1
- package/dist/generated/sdk.gen.d.ts +1 -1
- package/dist/generated/sdk.gen.js +9 -5
- package/dist/generated/types.gen.d.ts +519 -203
- package/dist/generated/zod.gen.d.ts +1955 -619
- package/dist/generated/zod.gen.js +2327 -238
- package/dist/index.d.ts +0 -2
- package/dist/index.js +0 -4
- package/openapi/api.json +3146 -929
- package/package.json +1 -1
package/README.md
CHANGED
|
@@ -58,7 +58,7 @@ The handwritten entry point only configures clients, authentication and disposal
|
|
|
58
58
|
|
|
59
59
|
Hey API owns all settings and observation value types. The public `DeviceSettings` export is the generated request type; `ObservationFact` combines catalog-defined metric names/IDs with the generated `Observation` value for that metric. Its known fields stay typed while read models allow additive fields. `generate-device-sdk.mjs` emits protocol schema/catalog data and workflow descriptors; it does not compile another set of settings or observation interfaces. No second schema-to-TypeScript compiler is required.
|
|
60
60
|
|
|
61
|
-
Staff diagnostics use the same tracker inventory ID as `getStaffTracker`. Use `requests.readStaffTrackerObservations({path: {id},
|
|
61
|
+
Staff diagnostics use the same tracker inventory ID as `getStaffTracker`. Use `requests.readStaffTrackerObservations({path: {id}, body: {series: [{definitionId, subject?}]}})` for current values, `getStaffTrackerSettings` to read settings, and `updateStaffTrackerSettings` to patch typed settings with an expected version. Current observation reads use POST with the same JSON selection as their realtime subscriptions; account batches use GET with `readStaffAccounts({query: {ids}})`. `getStaffTrackerCommandCatalog` returns definitions and availability together. The generated `staffRealtime.hub.watchObservations`, `watchCommand(id, operationId)` and `watchSettings` methods return native SignalR streams. Staff tracker pages accept `StaffTrackerPageRequest` with an optional exact `selection`, matching REST filters. See the [tracker diagnostics map](../../docs/api/diagnostics.md) for database, identity and acceptance semantics.
|
|
62
62
|
|
|
63
63
|
Command and firmware acceptance returns `202` with a `Location` status URL. Recover a command with `getStaffTrackerCommand({path: {id, operationId}})` using the original caller-generated UUID; its numeric hardware request ID is receipt evidence. Do not allocate a new UUID after an uncertain write. SDK 0.2 introduced the tracker resource layout; SDK 0.3 standardizes legacy LTE states (`queued`, `dispatched`, `expired`) and request kinds (`queue`, `cancel`) on lower-case strings. Firmware enum inputs accept strings, with numeric inputs rejected. Consumers must pin the matching prelaunch release.
|
|
64
64
|
|
|
@@ -102,7 +102,9 @@ package's npm settings. See [npm trusted publishing](https://docs.npmjs.com/trus
|
|
|
102
102
|
|
|
103
103
|
Command HTTP reads return `TrackerCommand`; command subscriptions return `CommandUpdate` with a command or an explicit read issue. Requests, broker publication and `execution.completed` are distinct stages on that resource. A completion includes its outcome, unavailable observation names and authenticated receipt time. Command output values are separate typed observations delivered through the observation endpoints and streams.
|
|
104
104
|
|
|
105
|
-
Version **0.
|
|
105
|
+
Version **0.7.0** reads selected current observations with a typed JSON body instead of repeated URL parameters. Pass `{path: {id}, body: {series: [{definitionId, subject?}]}}` to `readStaffTrackerObservations`. All registered observations, including request-scoped command events, support latest-value reads and streams. Observation `requestId` metadata is retained when recorded; older facts may lack it.
|
|
106
|
+
|
|
107
|
+
Version **0.6.0** aligned command receipts and independent domain observations. Consumers upgrading from 0.5 must read command output from the observation stream instead of a nested response-data union. `execution.accepted` is removed; use `publishedAt` for broker publication and `execution.completed` for the terminal device result.
|
|
106
108
|
|
|
107
109
|
## Observation timestamps
|
|
108
110
|
|
package/dist/device-schema.d.ts
CHANGED
|
@@ -485,78 +485,16 @@ export declare const observationValueSchema: {
|
|
|
485
485
|
readonly CellReading: {
|
|
486
486
|
readonly type: "object";
|
|
487
487
|
readonly properties: {
|
|
488
|
-
readonly
|
|
489
|
-
readonly type: "integer";
|
|
490
|
-
readonly minimum: 1;
|
|
491
|
-
readonly maximum: 999;
|
|
492
|
-
};
|
|
493
|
-
readonly mnc: {
|
|
494
|
-
readonly type: "integer";
|
|
495
|
-
readonly minimum: 0;
|
|
496
|
-
readonly maximum: 999;
|
|
497
|
-
};
|
|
498
|
-
readonly tac: {
|
|
499
|
-
readonly type: "integer";
|
|
500
|
-
readonly minimum: 0;
|
|
501
|
-
readonly maximum: 4294967295;
|
|
502
|
-
};
|
|
503
|
-
readonly cellId: {
|
|
504
|
-
readonly type: "integer";
|
|
505
|
-
readonly minimum: 0;
|
|
506
|
-
readonly maximum: 4294967295;
|
|
507
|
-
};
|
|
508
|
-
readonly pci: {
|
|
509
|
-
readonly anyOf: readonly [{
|
|
510
|
-
readonly type: "integer";
|
|
511
|
-
readonly minimum: 0;
|
|
512
|
-
readonly maximum: 4294967295;
|
|
513
|
-
}, {
|
|
514
|
-
readonly type: "null";
|
|
515
|
-
}];
|
|
516
|
-
};
|
|
517
|
-
readonly earfcn: {
|
|
518
|
-
readonly anyOf: readonly [{
|
|
519
|
-
readonly type: "integer";
|
|
520
|
-
readonly minimum: 0;
|
|
521
|
-
readonly maximum: 4294967295;
|
|
522
|
-
}, {
|
|
523
|
-
readonly type: "null";
|
|
524
|
-
}];
|
|
525
|
-
};
|
|
526
|
-
readonly rsrp: {
|
|
527
|
-
readonly anyOf: readonly [{
|
|
528
|
-
readonly type: "number";
|
|
529
|
-
readonly minimum: -200;
|
|
530
|
-
readonly maximum: 0;
|
|
531
|
-
}, {
|
|
532
|
-
readonly type: "null";
|
|
533
|
-
}];
|
|
534
|
-
};
|
|
535
|
-
readonly rsrq: {
|
|
488
|
+
readonly rat: {
|
|
536
489
|
readonly anyOf: readonly [{
|
|
537
|
-
readonly type: "
|
|
538
|
-
readonly
|
|
539
|
-
readonly maximum: 20;
|
|
490
|
+
readonly type: "string";
|
|
491
|
+
readonly enum: readonly ["lteM", "nbIot"];
|
|
540
492
|
}, {
|
|
541
493
|
readonly type: "null";
|
|
542
494
|
}];
|
|
543
495
|
};
|
|
544
|
-
|
|
545
|
-
|
|
546
|
-
readonly additionalProperties: false;
|
|
547
|
-
};
|
|
548
|
-
readonly CellNeighbour: {
|
|
549
|
-
readonly type: "object";
|
|
550
|
-
readonly properties: {
|
|
551
|
-
readonly pci: {
|
|
552
|
-
readonly type: "integer";
|
|
553
|
-
readonly minimum: 0;
|
|
554
|
-
readonly maximum: 4294967295;
|
|
555
|
-
};
|
|
556
|
-
readonly earfcn: {
|
|
557
|
-
readonly type: "integer";
|
|
558
|
-
readonly minimum: 0;
|
|
559
|
-
readonly maximum: 4294967295;
|
|
496
|
+
readonly identity: {
|
|
497
|
+
readonly $ref: "#/$defs/CellIdentity";
|
|
560
498
|
};
|
|
561
499
|
readonly rsrp: {
|
|
562
500
|
readonly anyOf: readonly [{
|
|
@@ -577,35 +515,7 @@ export declare const observationValueSchema: {
|
|
|
577
515
|
}];
|
|
578
516
|
};
|
|
579
517
|
};
|
|
580
|
-
readonly required: readonly ["
|
|
581
|
-
readonly additionalProperties: false;
|
|
582
|
-
};
|
|
583
|
-
readonly CellularEnvironment: {
|
|
584
|
-
readonly type: "object";
|
|
585
|
-
readonly properties: {
|
|
586
|
-
readonly serving: {
|
|
587
|
-
readonly $ref: "#/$defs/CellReading";
|
|
588
|
-
};
|
|
589
|
-
readonly rat: {
|
|
590
|
-
readonly type: "string";
|
|
591
|
-
readonly enum: readonly ["lteM", "nbIot"];
|
|
592
|
-
};
|
|
593
|
-
readonly globalCells: {
|
|
594
|
-
readonly type: "array";
|
|
595
|
-
readonly items: {
|
|
596
|
-
readonly $ref: "#/$defs/CellReading";
|
|
597
|
-
};
|
|
598
|
-
readonly maxItems: 5;
|
|
599
|
-
};
|
|
600
|
-
readonly neighbours: {
|
|
601
|
-
readonly type: "array";
|
|
602
|
-
readonly items: {
|
|
603
|
-
readonly $ref: "#/$defs/CellNeighbour";
|
|
604
|
-
};
|
|
605
|
-
readonly maxItems: 17;
|
|
606
|
-
};
|
|
607
|
-
};
|
|
608
|
-
readonly required: readonly ["serving", "rat", "globalCells", "neighbours"];
|
|
518
|
+
readonly required: readonly ["rat", "identity", "rsrp", "rsrq"];
|
|
609
519
|
readonly additionalProperties: false;
|
|
610
520
|
};
|
|
611
521
|
readonly WifiAccessPoint: {
|
|
@@ -4423,74 +4333,19 @@ export declare const observationValueSchema: {
|
|
|
4423
4333
|
};
|
|
4424
4334
|
};
|
|
4425
4335
|
};
|
|
4426
|
-
readonly "
|
|
4427
|
-
readonly
|
|
4428
|
-
readonly
|
|
4429
|
-
readonly
|
|
4430
|
-
readonly title: "Serving cell signal power (RSRP)";
|
|
4431
|
-
readonly description: "Reference signal received power of the last known serving cell, in dBm.";
|
|
4336
|
+
readonly "radio.servingCell": {
|
|
4337
|
+
readonly $ref: "#/$defs/CellReading";
|
|
4338
|
+
readonly title: "Serving cell";
|
|
4339
|
+
readonly description: "One serving-cell reading from readily available modem data, without a neighbor or GCI measurement. Includes available radio technology, identity and signal values; unresolved fields are null.";
|
|
4432
4340
|
readonly "x-bf": {
|
|
4433
|
-
readonly definitionId:
|
|
4341
|
+
readonly definitionId: 174;
|
|
4434
4342
|
readonly role: "measurement";
|
|
4435
4343
|
readonly subject: "device";
|
|
4436
4344
|
readonly producer: "device";
|
|
4437
4345
|
readonly requestScoped: false;
|
|
4438
4346
|
readonly presentation: {
|
|
4439
|
-
readonly displayName: "Serving cell
|
|
4440
|
-
readonly description: "
|
|
4441
|
-
readonly hiddenByDefault: false;
|
|
4442
|
-
readonly unit: "dBm";
|
|
4443
|
-
};
|
|
4444
|
-
};
|
|
4445
|
-
};
|
|
4446
|
-
readonly "network.rsrq": {
|
|
4447
|
-
readonly type: "number";
|
|
4448
|
-
readonly minimum: -60;
|
|
4449
|
-
readonly maximum: 20;
|
|
4450
|
-
readonly title: "Serving cell signal quality (RSRQ)";
|
|
4451
|
-
readonly description: "Reference signal received quality of the last known serving cell, in dB.";
|
|
4452
|
-
readonly "x-bf": {
|
|
4453
|
-
readonly definitionId: 104;
|
|
4454
|
-
readonly role: "measurement";
|
|
4455
|
-
readonly subject: "device";
|
|
4456
|
-
readonly producer: "device";
|
|
4457
|
-
readonly requestScoped: false;
|
|
4458
|
-
readonly presentation: {
|
|
4459
|
-
readonly displayName: "Serving cell signal quality (RSRQ)";
|
|
4460
|
-
readonly description: "Reference signal received quality of the last known serving cell, in dB.";
|
|
4461
|
-
readonly hiddenByDefault: false;
|
|
4462
|
-
readonly unit: "dB";
|
|
4463
|
-
};
|
|
4464
|
-
};
|
|
4465
|
-
};
|
|
4466
|
-
readonly "network.servingCell": {
|
|
4467
|
-
readonly type: "object";
|
|
4468
|
-
readonly properties: {
|
|
4469
|
-
readonly rat: {
|
|
4470
|
-
readonly anyOf: readonly [{
|
|
4471
|
-
readonly type: "string";
|
|
4472
|
-
readonly enum: readonly ["lteM", "nbIot"];
|
|
4473
|
-
}, {
|
|
4474
|
-
readonly type: "null";
|
|
4475
|
-
}];
|
|
4476
|
-
};
|
|
4477
|
-
readonly identity: {
|
|
4478
|
-
readonly $ref: "#/$defs/CellIdentity";
|
|
4479
|
-
};
|
|
4480
|
-
};
|
|
4481
|
-
readonly required: readonly ["rat", "identity"];
|
|
4482
|
-
readonly additionalProperties: false;
|
|
4483
|
-
readonly title: "Network serving cell";
|
|
4484
|
-
readonly description: "One passive serving-cell identity fact. Identity fields need a consistent cell context; omit unresolved fields instead of filling from an old cell. Independently timed signal measurements and extended scans remain separately selectable.";
|
|
4485
|
-
readonly "x-bf": {
|
|
4486
|
-
readonly definitionId: 105;
|
|
4487
|
-
readonly role: "measurement";
|
|
4488
|
-
readonly subject: "device";
|
|
4489
|
-
readonly producer: "device";
|
|
4490
|
-
readonly requestScoped: false;
|
|
4491
|
-
readonly presentation: {
|
|
4492
|
-
readonly displayName: "Network serving cell";
|
|
4493
|
-
readonly description: "One passive serving-cell identity fact. Identity fields need a consistent cell context; omit unresolved fields instead of filling from an old cell. Independently timed signal measurements and extended scans remain separately selectable.";
|
|
4347
|
+
readonly displayName: "Serving cell";
|
|
4348
|
+
readonly description: "One serving-cell reading from readily available modem data, without a neighbor or GCI measurement. Includes available radio technology, identity and signal values; unresolved fields are null.";
|
|
4494
4349
|
readonly hiddenByDefault: false;
|
|
4495
4350
|
readonly formatter: "fields";
|
|
4496
4351
|
readonly fields: readonly [{
|
|
@@ -4503,6 +4358,14 @@ export declare const observationValueSchema: {
|
|
|
4503
4358
|
}, {
|
|
4504
4359
|
readonly path: "identity.tac";
|
|
4505
4360
|
readonly label: "TAC";
|
|
4361
|
+
}, {
|
|
4362
|
+
readonly path: "rsrp";
|
|
4363
|
+
readonly label: "RSRP";
|
|
4364
|
+
readonly unit: "dBm";
|
|
4365
|
+
}, {
|
|
4366
|
+
readonly path: "rsrq";
|
|
4367
|
+
readonly label: "RSRQ";
|
|
4368
|
+
readonly unit: "dB";
|
|
4506
4369
|
}];
|
|
4507
4370
|
};
|
|
4508
4371
|
};
|
|
@@ -5290,19 +5153,23 @@ export declare const observationValueSchema: {
|
|
|
5290
5153
|
};
|
|
5291
5154
|
};
|
|
5292
5155
|
};
|
|
5293
|
-
readonly "radio.
|
|
5294
|
-
readonly
|
|
5295
|
-
readonly
|
|
5296
|
-
|
|
5156
|
+
readonly "radio.cells": {
|
|
5157
|
+
readonly type: "array";
|
|
5158
|
+
readonly items: {
|
|
5159
|
+
readonly $ref: "#/$defs/CellReading";
|
|
5160
|
+
};
|
|
5161
|
+
readonly maxItems: 23;
|
|
5162
|
+
readonly title: "Measured cells";
|
|
5163
|
+
readonly description: "Cells returned by an explicitly requested neighbor or GCI measurement, including the serving cell when available. Partial neighbors retain only their known identity fields. A one-cell result means the broader measurement found only one cell; an empty array is a successful measurement with no cells. A serving-only request does not produce this observation.";
|
|
5297
5164
|
readonly "x-bf": {
|
|
5298
|
-
readonly definitionId:
|
|
5165
|
+
readonly definitionId: 175;
|
|
5299
5166
|
readonly role: "measurement";
|
|
5300
5167
|
readonly subject: "device";
|
|
5301
5168
|
readonly producer: "device";
|
|
5302
5169
|
readonly requestScoped: false;
|
|
5303
5170
|
readonly presentation: {
|
|
5304
|
-
readonly displayName: "
|
|
5305
|
-
readonly description: "
|
|
5171
|
+
readonly displayName: "Measured cells";
|
|
5172
|
+
readonly description: "Cells returned by an explicitly requested neighbor or GCI measurement, including the serving cell when available. Partial neighbors retain only their known identity fields. A one-cell result means the broader measurement found only one cell; an empty array is a successful measurement with no cells. A serving-only request does not produce this observation.";
|
|
5306
5173
|
readonly hiddenByDefault: false;
|
|
5307
5174
|
readonly formatter: "cellScan";
|
|
5308
5175
|
};
|
|
@@ -8174,41 +8041,15 @@ export declare const observationDefinitions: readonly [{
|
|
|
8174
8041
|
}];
|
|
8175
8042
|
};
|
|
8176
8043
|
}, {
|
|
8177
|
-
readonly id:
|
|
8178
|
-
readonly name: "
|
|
8044
|
+
readonly id: 174;
|
|
8045
|
+
readonly name: "radio.servingCell";
|
|
8179
8046
|
readonly role: "measurement";
|
|
8180
8047
|
readonly subject: "device";
|
|
8181
8048
|
readonly producer: "device";
|
|
8182
8049
|
readonly requestScoped: false;
|
|
8183
8050
|
readonly presentation: {
|
|
8184
|
-
readonly displayName: "Serving cell
|
|
8185
|
-
readonly description: "
|
|
8186
|
-
readonly hiddenByDefault: false;
|
|
8187
|
-
readonly unit: "dBm";
|
|
8188
|
-
};
|
|
8189
|
-
}, {
|
|
8190
|
-
readonly id: 104;
|
|
8191
|
-
readonly name: "network.rsrq";
|
|
8192
|
-
readonly role: "measurement";
|
|
8193
|
-
readonly subject: "device";
|
|
8194
|
-
readonly producer: "device";
|
|
8195
|
-
readonly requestScoped: false;
|
|
8196
|
-
readonly presentation: {
|
|
8197
|
-
readonly displayName: "Serving cell signal quality (RSRQ)";
|
|
8198
|
-
readonly description: "Reference signal received quality of the last known serving cell, in dB.";
|
|
8199
|
-
readonly hiddenByDefault: false;
|
|
8200
|
-
readonly unit: "dB";
|
|
8201
|
-
};
|
|
8202
|
-
}, {
|
|
8203
|
-
readonly id: 105;
|
|
8204
|
-
readonly name: "network.servingCell";
|
|
8205
|
-
readonly role: "measurement";
|
|
8206
|
-
readonly subject: "device";
|
|
8207
|
-
readonly producer: "device";
|
|
8208
|
-
readonly requestScoped: false;
|
|
8209
|
-
readonly presentation: {
|
|
8210
|
-
readonly displayName: "Network serving cell";
|
|
8211
|
-
readonly description: "One passive serving-cell identity fact. Identity fields need a consistent cell context; omit unresolved fields instead of filling from an old cell. Independently timed signal measurements and extended scans remain separately selectable.";
|
|
8051
|
+
readonly displayName: "Serving cell";
|
|
8052
|
+
readonly description: "One serving-cell reading from readily available modem data, without a neighbor or GCI measurement. Includes available radio technology, identity and signal values; unresolved fields are null.";
|
|
8212
8053
|
readonly hiddenByDefault: false;
|
|
8213
8054
|
readonly formatter: "fields";
|
|
8214
8055
|
readonly fields: readonly [{
|
|
@@ -8221,6 +8062,14 @@ export declare const observationDefinitions: readonly [{
|
|
|
8221
8062
|
}, {
|
|
8222
8063
|
readonly path: "identity.tac";
|
|
8223
8064
|
readonly label: "TAC";
|
|
8065
|
+
}, {
|
|
8066
|
+
readonly path: "rsrp";
|
|
8067
|
+
readonly label: "RSRP";
|
|
8068
|
+
readonly unit: "dBm";
|
|
8069
|
+
}, {
|
|
8070
|
+
readonly path: "rsrq";
|
|
8071
|
+
readonly label: "RSRQ";
|
|
8072
|
+
readonly unit: "dB";
|
|
8224
8073
|
}];
|
|
8225
8074
|
};
|
|
8226
8075
|
}, {
|
|
@@ -8692,15 +8541,15 @@ export declare const observationDefinitions: readonly [{
|
|
|
8692
8541
|
readonly formatter: "bleScan";
|
|
8693
8542
|
};
|
|
8694
8543
|
}, {
|
|
8695
|
-
readonly id:
|
|
8696
|
-
readonly name: "radio.
|
|
8544
|
+
readonly id: 175;
|
|
8545
|
+
readonly name: "radio.cells";
|
|
8697
8546
|
readonly role: "measurement";
|
|
8698
8547
|
readonly subject: "device";
|
|
8699
8548
|
readonly producer: "device";
|
|
8700
8549
|
readonly requestScoped: false;
|
|
8701
8550
|
readonly presentation: {
|
|
8702
|
-
readonly displayName: "
|
|
8703
|
-
readonly description: "
|
|
8551
|
+
readonly displayName: "Measured cells";
|
|
8552
|
+
readonly description: "Cells returned by an explicitly requested neighbor or GCI measurement, including the serving cell when available. Partial neighbors retain only their known identity fields. A one-cell result means the broader measurement found only one cell; an empty array is a successful measurement with no cells. A serving-only request does not produce this observation.";
|
|
8704
8553
|
readonly hiddenByDefault: false;
|
|
8705
8554
|
readonly formatter: "cellScan";
|
|
8706
8555
|
};
|