@bikefinder/sdk 0.1.5 → 0.1.7
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 +12 -10
- package/dist/device-schema.d.ts +50 -57
- package/dist/device-schema.js +29 -45
- package/dist/generated/sdk.gen.js +93 -93
- package/dist/generated/types.gen.d.ts +45 -45
- package/dist/generated/zod.gen.d.ts +130 -240
- package/dist/generated/zod.gen.js +17 -28
- package/dist/index.d.ts +1 -1
- package/dist/workflow-schema.d.ts +4 -4
- package/dist/workflow-schema.js +4 -4
- package/openapi/api.json +26 -43
- package/package.json +1 -1
|
@@ -9094,14 +9094,14 @@ export const zDeviceSettings = z
|
|
|
9094
9094
|
bleAdvertisingEnabled: z.boolean().optional(),
|
|
9095
9095
|
bleAdvertisingRequiresExternalPower: z.boolean().optional(),
|
|
9096
9096
|
bleAdvertisingIntervalUnits: z.int().gte(32).lte(16384).optional(),
|
|
9097
|
-
mode: z.
|
|
9097
|
+
mode: z.string().optional(),
|
|
9098
9098
|
poweredReportIntervalSeconds: z.int().gte(30).lte(86400).optional(),
|
|
9099
|
-
|
|
9100
|
-
|
|
9101
|
-
|
|
9102
|
-
|
|
9103
|
-
|
|
9104
|
-
|
|
9099
|
+
standardIdleSeconds: z.int().gte(60).lte(604800).optional(),
|
|
9100
|
+
securityIdleSeconds: z.int().gte(60).lte(604800).optional(),
|
|
9101
|
+
trackingIdleSeconds: z.int().gte(10).lte(86400).optional(),
|
|
9102
|
+
standardMinimumRestSeconds: z.int().gte(0).lte(86400).optional(),
|
|
9103
|
+
securityMinimumRestSeconds: z.int().gte(0).lte(86400).optional(),
|
|
9104
|
+
trackingMinimumRestSeconds: z.int().gte(0).lte(86400).optional(),
|
|
9105
9105
|
psmResidenceSeconds: z.int().gte(0).lte(86400).optional(),
|
|
9106
9106
|
commandListenSeconds: z.int().gte(0).lte(3600).optional(),
|
|
9107
9107
|
gnssSearchTimeoutSeconds: z.int().gte(1).lte(3600).optional(),
|
|
@@ -9282,7 +9282,7 @@ export const zDeviceWorkCompletedValue = z
|
|
|
9282
9282
|
activityEntries: zDeviceObservationValuesActivityEntries,
|
|
9283
9283
|
recoveries: zDeviceObservationValuesRecoveryCounts,
|
|
9284
9284
|
saturated: z.boolean(),
|
|
9285
|
-
mode: z.
|
|
9285
|
+
mode: z.string(),
|
|
9286
9286
|
})
|
|
9287
9287
|
.catchall(z.unknown());
|
|
9288
9288
|
export const zAwsWorkCompletedObservation = z
|
|
@@ -9336,19 +9336,8 @@ export const zAwsWorkCompletedReading = z.union([
|
|
|
9336
9336
|
export const zDeviceWorkflowExecutionValue = z
|
|
9337
9337
|
.object({
|
|
9338
9338
|
workflowVersion: z.int().gte(1).lte(65535),
|
|
9339
|
-
mode: z.
|
|
9340
|
-
state: z.
|
|
9341
|
-
"idle",
|
|
9342
|
-
"battery",
|
|
9343
|
-
"connect",
|
|
9344
|
-
"cell",
|
|
9345
|
-
"wifi",
|
|
9346
|
-
"publish",
|
|
9347
|
-
"listen",
|
|
9348
|
-
"gps",
|
|
9349
|
-
"gpsPublish",
|
|
9350
|
-
"rest",
|
|
9351
|
-
]),
|
|
9339
|
+
mode: z.string(),
|
|
9340
|
+
state: z.string(),
|
|
9352
9341
|
owner: z.enum([
|
|
9353
9342
|
"workflow",
|
|
9354
9343
|
"command",
|
|
@@ -13018,14 +13007,14 @@ export const zReadDeviceSettings = z
|
|
|
13018
13007
|
bleAdvertisingEnabled: z.boolean().optional(),
|
|
13019
13008
|
bleAdvertisingRequiresExternalPower: z.boolean().optional(),
|
|
13020
13009
|
bleAdvertisingIntervalUnits: z.int().gte(32).lte(16384).optional(),
|
|
13021
|
-
mode: z.
|
|
13010
|
+
mode: z.string().optional(),
|
|
13022
13011
|
poweredReportIntervalSeconds: z.int().gte(30).lte(86400).optional(),
|
|
13023
|
-
|
|
13024
|
-
|
|
13025
|
-
|
|
13026
|
-
|
|
13027
|
-
|
|
13028
|
-
|
|
13012
|
+
standardIdleSeconds: z.int().gte(60).lte(604800).optional(),
|
|
13013
|
+
securityIdleSeconds: z.int().gte(60).lte(604800).optional(),
|
|
13014
|
+
trackingIdleSeconds: z.int().gte(10).lte(86400).optional(),
|
|
13015
|
+
standardMinimumRestSeconds: z.int().gte(0).lte(86400).optional(),
|
|
13016
|
+
securityMinimumRestSeconds: z.int().gte(0).lte(86400).optional(),
|
|
13017
|
+
trackingMinimumRestSeconds: z.int().gte(0).lte(86400).optional(),
|
|
13029
13018
|
psmResidenceSeconds: z.int().gte(0).lte(86400).optional(),
|
|
13030
13019
|
commandListenSeconds: z.int().gte(0).lte(3600).optional(),
|
|
13031
13020
|
gnssSearchTimeoutSeconds: z.int().gte(1).lte(3600).optional(),
|
package/dist/index.d.ts
CHANGED
|
@@ -23,6 +23,6 @@ export declare function createBikeFinderClient(options: ClientOptions): {
|
|
|
23
23
|
};
|
|
24
24
|
export type BikeFinderClient = ReturnType<typeof createBikeFinderClient>;
|
|
25
25
|
export { workflowDefinition } from "./workflow-schema.js";
|
|
26
|
-
export type {
|
|
26
|
+
export type { TrackingMode, WorkflowState } from "./workflow-schema.js";
|
|
27
27
|
export { observationValueSchema, observationDefinitions, settingsValueSchema } from "./device-schema.js";
|
|
28
28
|
export type { ObservationFact, MetricName, DeviceSettings } from "./device-schema.js";
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
export declare const workflowDefinition: {
|
|
2
|
-
readonly version:
|
|
3
|
-
readonly modes: readonly [
|
|
2
|
+
readonly version: 1;
|
|
3
|
+
readonly modes: readonly ["standard", "security", "tracking"];
|
|
4
4
|
readonly states: readonly ["idle", "battery", "connect", "cell", "wifi", "publish", "listen", "gps", "gpsPublish", "rest"];
|
|
5
5
|
readonly outcomes: readonly ["done", "unavailable", "failed", "timeout", "cancelled"];
|
|
6
6
|
readonly acquisition: {
|
|
@@ -194,5 +194,5 @@ export declare const workflowDefinition: {
|
|
|
194
194
|
readonly name: "connect";
|
|
195
195
|
}];
|
|
196
196
|
};
|
|
197
|
-
export type
|
|
198
|
-
export type WorkflowState =
|
|
197
|
+
export type TrackingMode = (typeof workflowDefinition.modes)[number];
|
|
198
|
+
export type WorkflowState = string;
|
package/dist/workflow-schema.js
CHANGED
|
@@ -1,10 +1,10 @@
|
|
|
1
1
|
// Generated from protocol JSON Schemas by tools/generate-device-sdk.mjs. Do not edit.
|
|
2
2
|
export const workflowDefinition = {
|
|
3
|
-
"version":
|
|
3
|
+
"version": 1,
|
|
4
4
|
"modes": [
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
5
|
+
"standard",
|
|
6
|
+
"security",
|
|
7
|
+
"tracking"
|
|
8
8
|
],
|
|
9
9
|
"states": [
|
|
10
10
|
"idle",
|
package/openapi/api.json
CHANGED
|
@@ -43795,12 +43795,10 @@
|
|
|
43795
43795
|
}
|
|
43796
43796
|
},
|
|
43797
43797
|
"mode": {
|
|
43798
|
-
"title": "
|
|
43799
|
-
"maximum": 2,
|
|
43800
|
-
"minimum": 0,
|
|
43798
|
+
"title": "Tracking mode",
|
|
43801
43799
|
"uniqueItems": false,
|
|
43802
|
-
"type": "
|
|
43803
|
-
"description": "
|
|
43800
|
+
"type": "string",
|
|
43801
|
+
"description": "Underlying firmware behavior. Offered tracking modes are cloud-configurable profiles.",
|
|
43804
43802
|
"x-bf": {
|
|
43805
43803
|
"unit": null
|
|
43806
43804
|
}
|
|
@@ -43816,68 +43814,68 @@
|
|
|
43816
43814
|
"unit": "s"
|
|
43817
43815
|
}
|
|
43818
43816
|
},
|
|
43819
|
-
"
|
|
43820
|
-
"title": "
|
|
43817
|
+
"standardIdleSeconds": {
|
|
43818
|
+
"title": "Standard idle duration",
|
|
43821
43819
|
"maximum": 604800,
|
|
43822
43820
|
"minimum": 60,
|
|
43823
43821
|
"uniqueItems": false,
|
|
43824
43822
|
"type": "integer",
|
|
43825
|
-
"description": "Maximum battery idle duration after a
|
|
43823
|
+
"description": "Maximum battery idle duration after a standard cycle.",
|
|
43826
43824
|
"x-bf": {
|
|
43827
43825
|
"unit": "s"
|
|
43828
43826
|
}
|
|
43829
43827
|
},
|
|
43830
|
-
"
|
|
43831
|
-
"title": "
|
|
43828
|
+
"securityIdleSeconds": {
|
|
43829
|
+
"title": "Security idle duration",
|
|
43832
43830
|
"maximum": 604800,
|
|
43833
43831
|
"minimum": 60,
|
|
43834
43832
|
"uniqueItems": false,
|
|
43835
43833
|
"type": "integer",
|
|
43836
|
-
"description": "Maximum battery idle duration after a
|
|
43834
|
+
"description": "Maximum battery idle duration after a security cycle.",
|
|
43837
43835
|
"x-bf": {
|
|
43838
43836
|
"unit": "s"
|
|
43839
43837
|
}
|
|
43840
43838
|
},
|
|
43841
|
-
"
|
|
43842
|
-
"title": "
|
|
43839
|
+
"trackingIdleSeconds": {
|
|
43840
|
+
"title": "Tracking idle duration",
|
|
43843
43841
|
"maximum": 86400,
|
|
43844
43842
|
"minimum": 10,
|
|
43845
43843
|
"uniqueItems": false,
|
|
43846
43844
|
"type": "integer",
|
|
43847
|
-
"description": "Maximum battery idle duration after a
|
|
43845
|
+
"description": "Maximum battery idle duration after a tracking cycle.",
|
|
43848
43846
|
"x-bf": {
|
|
43849
43847
|
"unit": "s"
|
|
43850
43848
|
}
|
|
43851
43849
|
},
|
|
43852
|
-
"
|
|
43853
|
-
"title": "
|
|
43850
|
+
"standardMinimumRestSeconds": {
|
|
43851
|
+
"title": "Standard movement rest",
|
|
43854
43852
|
"maximum": 86400,
|
|
43855
43853
|
"minimum": 0,
|
|
43856
43854
|
"uniqueItems": false,
|
|
43857
43855
|
"type": "integer",
|
|
43858
|
-
"description": "
|
|
43856
|
+
"description": "Minimum rest before movement starts another standard cycle.",
|
|
43859
43857
|
"x-bf": {
|
|
43860
43858
|
"unit": "s"
|
|
43861
43859
|
}
|
|
43862
43860
|
},
|
|
43863
|
-
"
|
|
43864
|
-
"title": "
|
|
43861
|
+
"securityMinimumRestSeconds": {
|
|
43862
|
+
"title": "Security movement rest",
|
|
43865
43863
|
"maximum": 86400,
|
|
43866
43864
|
"minimum": 0,
|
|
43867
43865
|
"uniqueItems": false,
|
|
43868
43866
|
"type": "integer",
|
|
43869
|
-
"description": "
|
|
43867
|
+
"description": "Minimum rest before movement starts another security cycle.",
|
|
43870
43868
|
"x-bf": {
|
|
43871
43869
|
"unit": "s"
|
|
43872
43870
|
}
|
|
43873
43871
|
},
|
|
43874
|
-
"
|
|
43875
|
-
"title": "
|
|
43872
|
+
"trackingMinimumRestSeconds": {
|
|
43873
|
+
"title": "Tracking movement rest",
|
|
43876
43874
|
"maximum": 86400,
|
|
43877
43875
|
"minimum": 0,
|
|
43878
43876
|
"uniqueItems": false,
|
|
43879
43877
|
"type": "integer",
|
|
43880
|
-
"description": "
|
|
43878
|
+
"description": "Minimum rest before movement starts another tracking cycle.",
|
|
43881
43879
|
"x-bf": {
|
|
43882
43880
|
"unit": "s"
|
|
43883
43881
|
}
|
|
@@ -44213,7 +44211,7 @@
|
|
|
44213
44211
|
"x-bf": {
|
|
44214
44212
|
"domain": "settings",
|
|
44215
44213
|
"version": 1,
|
|
44216
|
-
"settingsSchemaVersion":
|
|
44214
|
+
"settingsSchemaVersion": 28
|
|
44217
44215
|
}
|
|
44218
44216
|
},
|
|
44219
44217
|
"DeviceSettingsAutomaticDiagnosticsPower": {
|
|
@@ -44410,10 +44408,8 @@
|
|
|
44410
44408
|
"type": "boolean"
|
|
44411
44409
|
},
|
|
44412
44410
|
"mode": {
|
|
44413
|
-
"maximum": 2,
|
|
44414
|
-
"minimum": 0,
|
|
44415
44411
|
"uniqueItems": false,
|
|
44416
|
-
"type": "
|
|
44412
|
+
"type": "string"
|
|
44417
44413
|
}
|
|
44418
44414
|
},
|
|
44419
44415
|
"additionalProperties": false,
|
|
@@ -44475,25 +44471,11 @@
|
|
|
44475
44471
|
"type": "integer"
|
|
44476
44472
|
},
|
|
44477
44473
|
"mode": {
|
|
44478
|
-
"maximum": 2,
|
|
44479
|
-
"minimum": 0,
|
|
44480
44474
|
"uniqueItems": false,
|
|
44481
|
-
"type": "
|
|
44475
|
+
"type": "string"
|
|
44482
44476
|
},
|
|
44483
44477
|
"state": {
|
|
44484
44478
|
"uniqueItems": false,
|
|
44485
|
-
"enum": [
|
|
44486
|
-
"idle",
|
|
44487
|
-
"battery",
|
|
44488
|
-
"connect",
|
|
44489
|
-
"cell",
|
|
44490
|
-
"wifi",
|
|
44491
|
-
"publish",
|
|
44492
|
-
"listen",
|
|
44493
|
-
"gps",
|
|
44494
|
-
"gpsPublish",
|
|
44495
|
-
"rest"
|
|
44496
|
-
],
|
|
44497
44479
|
"type": "string"
|
|
44498
44480
|
},
|
|
44499
44481
|
"owner": {
|
|
@@ -44656,7 +44638,8 @@
|
|
|
44656
44638
|
}
|
|
44657
44639
|
],
|
|
44658
44640
|
"extensibleEnumFields": [
|
|
44659
|
-
"mode"
|
|
44641
|
+
"mode",
|
|
44642
|
+
"state"
|
|
44660
44643
|
]
|
|
44661
44644
|
}
|
|
44662
44645
|
}
|