@edgeiq/edgeiq-api-js 1.4.11 → 1.4.13

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.
Files changed (210) hide show
  1. package/README.md +55 -55
  2. package/dist/__tests__/auth.test.d.ts +1 -1
  3. package/dist/__tests__/auth.test.js +159 -159
  4. package/dist/__tests__/command.test.d.ts +1 -1
  5. package/dist/__tests__/command.test.js +212 -212
  6. package/dist/__tests__/companies.test.d.ts +1 -1
  7. package/dist/__tests__/companies.test.js +196 -196
  8. package/dist/__tests__/deviceErrors.test.d.ts +1 -1
  9. package/dist/__tests__/deviceErrors.test.js +72 -72
  10. package/dist/__tests__/deviceTypes.test.d.ts +1 -1
  11. package/dist/__tests__/deviceTypes.test.js +172 -172
  12. package/dist/__tests__/devices.test.d.ts +1 -1
  13. package/dist/__tests__/devices.test.js +232 -232
  14. package/dist/__tests__/discoveredDevice.test.d.ts +1 -1
  15. package/dist/__tests__/discoveredDevice.test.js +155 -155
  16. package/dist/__tests__/files.test.d.ts +1 -1
  17. package/dist/__tests__/files.test.js +162 -162
  18. package/dist/__tests__/ingestors.test.d.ts +1 -1
  19. package/dist/__tests__/ingestors.test.js +198 -198
  20. package/dist/__tests__/integrations.test.d.ts +1 -1
  21. package/dist/__tests__/integrations.test.js +247 -211
  22. package/dist/__tests__/lwm2m.test.d.ts +1 -1
  23. package/dist/__tests__/lwm2m.test.js +73 -73
  24. package/dist/__tests__/notifications.test.d.ts +1 -1
  25. package/dist/__tests__/notifications.test.js +72 -72
  26. package/dist/__tests__/pollableAttributes.test.d.ts +1 -1
  27. package/dist/__tests__/pollableAttributes.test.js +172 -172
  28. package/dist/__tests__/rules.test.d.ts +1 -1
  29. package/dist/__tests__/rules.test.js +172 -172
  30. package/dist/__tests__/testConstants.d.ts +7 -0
  31. package/dist/__tests__/testConstants.js +14 -0
  32. package/dist/__tests__/translators.test.d.ts +1 -1
  33. package/dist/__tests__/translators.test.js +172 -172
  34. package/dist/__tests__/users.test.d.ts +1 -1
  35. package/dist/__tests__/users.test.js +208 -208
  36. package/dist/auth/index.d.ts +9 -9
  37. package/dist/auth/index.js +183 -183
  38. package/dist/bulkResponses/index.d.ts +8 -8
  39. package/dist/bulkResponses/index.js +124 -124
  40. package/dist/bulkResponses/models.d.ts +45 -45
  41. package/dist/bulkResponses/models.js +2 -2
  42. package/dist/commandExecutions/index.d.ts +8 -8
  43. package/dist/commandExecutions/index.js +220 -220
  44. package/dist/commandExecutions/models.d.ts +26 -26
  45. package/dist/commandExecutions/models.js +2 -2
  46. package/dist/commands/index.d.ts +18 -18
  47. package/dist/commands/index.js +378 -378
  48. package/dist/commands/models.d.ts +40 -40
  49. package/dist/commands/models.js +16 -16
  50. package/dist/companies/index.d.ts +11 -10
  51. package/dist/companies/index.js +270 -246
  52. package/dist/companies/models.d.ts +110 -110
  53. package/dist/companies/models.js +2 -2
  54. package/dist/configurations/index.d.ts +9 -9
  55. package/dist/configurations/index.js +223 -223
  56. package/dist/configurations/models.d.ts +34 -34
  57. package/dist/configurations/models.js +2 -2
  58. package/dist/constants.d.ts +153 -153
  59. package/dist/constants.js +169 -169
  60. package/dist/core/ModelClass.d.ts +13 -13
  61. package/dist/core/ModelClass.js +19 -19
  62. package/dist/core/handleResponseError.d.ts +2 -2
  63. package/dist/core/handleResponseError.js +167 -167
  64. package/dist/core/index.d.ts +19 -19
  65. package/dist/core/index.js +63 -63
  66. package/dist/deviceConfigs/index.d.ts +9 -9
  67. package/dist/deviceConfigs/index.js +224 -224
  68. package/dist/deviceConfigs/models.d.ts +38 -38
  69. package/dist/deviceConfigs/models.js +2 -2
  70. package/dist/deviceErrors/index.d.ts +8 -8
  71. package/dist/deviceErrors/index.js +124 -124
  72. package/dist/deviceErrors/models.d.ts +19 -19
  73. package/dist/deviceErrors/models.js +2 -2
  74. package/dist/deviceLocationObservations/index.d.ts +5 -5
  75. package/dist/deviceLocationObservations/index.js +189 -189
  76. package/dist/deviceLocationObservations/models.d.ts +26 -26
  77. package/dist/deviceLocationObservations/models.js +2 -2
  78. package/dist/deviceTemplates/index.d.ts +9 -9
  79. package/dist/deviceTemplates/index.js +226 -226
  80. package/dist/deviceTemplates/models.d.ts +36 -36
  81. package/dist/deviceTemplates/models.js +2 -2
  82. package/dist/deviceTransferRequests/index.d.ts +10 -10
  83. package/dist/deviceTransferRequests/index.js +247 -247
  84. package/dist/deviceTransferRequests/models.d.ts +26 -26
  85. package/dist/deviceTransferRequests/models.js +2 -2
  86. package/dist/deviceTypes/index.d.ts +20 -20
  87. package/dist/deviceTypes/index.js +464 -464
  88. package/dist/deviceTypes/models.d.ts +112 -110
  89. package/dist/deviceTypes/models.js +2 -2
  90. package/dist/devices/index.d.ts +39 -37
  91. package/dist/devices/index.js +833 -809
  92. package/dist/devices/models.d.ts +130 -130
  93. package/dist/devices/models.js +2 -2
  94. package/dist/discoveredDevices/index.d.ts +15 -15
  95. package/dist/discoveredDevices/index.js +361 -361
  96. package/dist/discoveredDevices/models.d.ts +41 -41
  97. package/dist/discoveredDevices/models.js +2 -2
  98. package/dist/downstreamSystems/index.d.ts +7 -7
  99. package/dist/downstreamSystems/index.js +198 -198
  100. package/dist/downstreamSystems/models.d.ts +17 -17
  101. package/dist/downstreamSystems/models.js +2 -2
  102. package/dist/escrowDevices/index.d.ts +9 -9
  103. package/dist/escrowDevices/index.js +224 -224
  104. package/dist/escrowDevices/models.d.ts +32 -32
  105. package/dist/escrowDevices/models.js +2 -2
  106. package/dist/example/index.d.ts +1 -0
  107. package/dist/example/index.js +5 -0
  108. package/dist/files/index.d.ts +11 -11
  109. package/dist/files/index.js +278 -278
  110. package/dist/files/models.d.ts +20 -20
  111. package/dist/files/models.js +2 -2
  112. package/dist/filtersParser.d.ts +5 -5
  113. package/dist/filtersParser.js +54 -54
  114. package/dist/gatewayCommands/index.d.ts +9 -9
  115. package/dist/gatewayCommands/index.js +224 -224
  116. package/dist/gatewayCommands/models.d.ts +81 -81
  117. package/dist/gatewayCommands/models.js +2 -2
  118. package/dist/helpers.d.ts +3 -3
  119. package/dist/helpers.js +11 -11
  120. package/dist/index.d.ts +74 -74
  121. package/dist/index.js +124 -124
  122. package/dist/ingestors/index.d.ts +9 -9
  123. package/dist/ingestors/index.js +224 -224
  124. package/dist/ingestors/models.d.ts +97 -97
  125. package/dist/ingestors/models.js +2 -2
  126. package/dist/integrations/index.d.ts +11 -10
  127. package/dist/integrations/index.js +364 -340
  128. package/dist/integrations/models.d.ts +77 -76
  129. package/dist/integrations/models.js +2 -2
  130. package/dist/log/models.d.ts +6 -6
  131. package/dist/log/models.js +2 -2
  132. package/dist/lwm2m/index.d.ts +5 -5
  133. package/dist/lwm2m/index.js +84 -84
  134. package/dist/lwm2m/models.d.ts +68 -68
  135. package/dist/lwm2m/models.js +2 -2
  136. package/dist/lwm2mState/index.d.ts +5 -5
  137. package/dist/lwm2mState/index.js +71 -71
  138. package/dist/lwm2mState/models.d.ts +10 -10
  139. package/dist/lwm2mState/models.js +2 -2
  140. package/dist/models/index.d.ts +1896 -1896
  141. package/dist/models/index.js +2 -2
  142. package/dist/models.d.ts +71 -67
  143. package/dist/models.js +2 -2
  144. package/dist/notifications/index.d.ts +8 -8
  145. package/dist/notifications/index.js +124 -124
  146. package/dist/notifications/models.d.ts +19 -19
  147. package/dist/notifications/models.js +2 -2
  148. package/dist/pollableAttributes/index.d.ts +7 -7
  149. package/dist/pollableAttributes/index.js +198 -198
  150. package/dist/pollableAttributes/models.d.ts +49 -49
  151. package/dist/pollableAttributes/models.js +2 -2
  152. package/dist/regions/index.d.ts +5 -5
  153. package/dist/regions/index.js +173 -173
  154. package/dist/regions/models.d.ts +17 -17
  155. package/dist/regions/models.js +2 -2
  156. package/dist/reports/index.d.ts +8 -8
  157. package/dist/reports/index.js +199 -199
  158. package/dist/reports/models.d.ts +25 -25
  159. package/dist/reports/models.js +2 -2
  160. package/dist/rules/index.d.ts +12 -12
  161. package/dist/rules/index.js +272 -272
  162. package/dist/rules/models.d.ts +129 -129
  163. package/dist/rules/models.js +2 -2
  164. package/dist/secrets/index.d.ts +8 -8
  165. package/dist/secrets/index.js +199 -199
  166. package/dist/secrets/models.d.ts +18 -18
  167. package/dist/secrets/models.js +2 -2
  168. package/dist/settings/index.d.ts +7 -7
  169. package/dist/settings/index.js +198 -198
  170. package/dist/settings/models.d.ts +25 -25
  171. package/dist/settings/models.js +2 -2
  172. package/dist/settingsApplicationRecord/index.d.ts +6 -6
  173. package/dist/settingsApplicationRecord/index.js +79 -79
  174. package/dist/settingsApplicationRecord/models.d.ts +28 -28
  175. package/dist/settingsApplicationRecord/models.js +2 -2
  176. package/dist/softwareUpdates/index.d.ts +15 -15
  177. package/dist/softwareUpdates/index.js +385 -385
  178. package/dist/softwareUpdates/models.d.ts +31 -31
  179. package/dist/softwareUpdates/models.js +2 -2
  180. package/dist/stats/index.d.ts +9 -9
  181. package/dist/stats/index.js +140 -140
  182. package/dist/stats/models.d.ts +27 -27
  183. package/dist/stats/models.js +2 -2
  184. package/dist/systemCommandJobs/index.d.ts +5 -5
  185. package/dist/systemCommandJobs/index.js +173 -173
  186. package/dist/systemCommandJobs/models.d.ts +32 -32
  187. package/dist/systemCommandJobs/models.js +2 -2
  188. package/dist/systemCommands/index.d.ts +7 -7
  189. package/dist/systemCommands/index.js +198 -198
  190. package/dist/systemCommands/models.d.ts +32 -32
  191. package/dist/systemCommands/models.js +2 -2
  192. package/dist/testConstants.d.ts +51 -50
  193. package/dist/testConstants.js +343 -332
  194. package/dist/translators/index.d.ts +9 -9
  195. package/dist/translators/index.js +224 -224
  196. package/dist/translators/models.d.ts +21 -21
  197. package/dist/translators/models.js +2 -2
  198. package/dist/userTypes/index.d.ts +7 -7
  199. package/dist/userTypes/index.js +198 -198
  200. package/dist/userTypes/models.d.ts +79 -79
  201. package/dist/userTypes/models.js +2 -2
  202. package/dist/users/index.d.ts +12 -12
  203. package/dist/users/index.js +300 -300
  204. package/dist/users/models.d.ts +42 -42
  205. package/dist/users/models.js +2 -2
  206. package/package.json +56 -56
  207. package/dist/deviceFiles/index.d.ts +0 -9
  208. package/dist/deviceFiles/index.js +0 -278
  209. package/dist/deviceFiles/models.d.ts +0 -17
  210. package/dist/deviceFiles/models.js +0 -2
@@ -1,1896 +1,1896 @@
1
- export declare type AbilityType = string;
2
- export declare type ActionType = string;
3
- export declare type AppConfigType = string;
4
- export declare type BodyType = string;
5
- export declare type BulkRequestType = string;
6
- export declare type BulkResponseStatusType = string;
7
- export declare type DeviceClass = string;
8
- export declare type DeviceEventType = string;
9
- export declare type DeviceErrorType = string;
10
- export declare type DeviceIntegrationActionType = string;
11
- export declare type DType = string;
12
- export declare type GatewayCommandType = string;
13
- export declare type GeometryType = string;
14
- export declare type HandlerType = string;
15
- export declare type HealthProbeType = string;
16
- export declare type HeartbeatStatusType = string;
17
- export declare type IDType = string;
18
- export declare type IngestorType = string;
19
- export declare type IntegrationArchetype = string;
20
- export declare type IntegrationType = string;
21
- export declare type ListenerType = string;
22
- export declare type LocationTransitionDirectionType = string;
23
- export declare type ModelType = string;
24
- export declare type OriginType = string;
25
- export declare type ProvisionStatusType = string;
26
- export declare type RestartPolicyTriggerType = string;
27
- export declare type ReportType = string;
28
- export declare type RuleConditionType = string;
29
- export declare type SenderType = string;
30
- export declare type SystemCommandJobStatusType = string;
31
- export declare type TranslatorType = string;
32
- export declare type UpstreamActionType = string;
33
- export declare type ValueType = string;
34
- export declare type BulkStatus = string;
35
- export declare type DeviceHealthStatus = string;
36
- export declare type DeviceLocationObservationVia = string;
37
- export declare type DeviceTransferRequestStatus = string;
38
- export declare type LogLevel = string;
39
- export declare type RetryInterval = string;
40
- export declare type Status = number;
41
- export interface Lwm2mStateObject {
42
- [index: string]: unknown;
43
- }
44
- export interface DeviceEvent {
45
- id: string;
46
- created_at: string;
47
- device_class: DeviceClass;
48
- company_id: string;
49
- unique_id: string;
50
- raw_client_id: string;
51
- device_event_type: DeviceEventType;
52
- metadata: {
53
- [key: string]: unknown;
54
- };
55
- }
56
- export interface Abilities {
57
- audit: Ability;
58
- application: Ability;
59
- bulk_response: Ability;
60
- bulk_response_status: Ability;
61
- command: Ability;
62
- company: Ability;
63
- deployment: Ability;
64
- device: AbilityAndAction;
65
- device_type: Ability;
66
- device_config: AbilityAndAction;
67
- device_error: Ability;
68
- device_ha_group: Ability;
69
- device_health_status_event: Ability;
70
- device_transfer_request: Ability;
71
- device_template: Ability;
72
- device_location_observation: Ability;
73
- escrow_device: Ability;
74
- downstream_system: Ability;
75
- gateway_command: Ability;
76
- ingestor: Ability;
77
- integration: Ability;
78
- integration_event: Ability;
79
- notification: Ability;
80
- pollable_attribute: Ability;
81
- region: Ability;
82
- report: AbilityAndPayload;
83
- rule: Ability;
84
- secret: Ability;
85
- lwm2m_object_links: Ability;
86
- lwm2m_state: Ability;
87
- software_update: Ability;
88
- system_command: Ability;
89
- system_command_job: Ability;
90
- translator: Ability;
91
- user: AbilityForUser;
92
- user_type: Ability;
93
- workflow_definition: AbilityAndExecute;
94
- workflow_record: Ability;
95
- workflow_job_result: Ability;
96
- workflow_tree: Ability;
97
- workflow_action: Ability;
98
- }
99
- export interface ViewAbilities {
100
- dashboard: boolean;
101
- gateways: boolean;
102
- devices: boolean;
103
- reports: boolean;
104
- errors: boolean;
105
- customers: boolean;
106
- roles: boolean;
107
- companies: boolean;
108
- integrations: boolean;
109
- notifications: boolean;
110
- firmware: boolean;
111
- }
112
- export interface Ability {
113
- create: AbilityType;
114
- update: AbilityType;
115
- read: AbilityType;
116
- delete: AbilityType;
117
- }
118
- export interface Action {
119
- notification: AbilityType;
120
- enable_data_restriction: AbilityType;
121
- disable_data_restriction: AbilityType;
122
- send_config: AbilityType;
123
- deploy_deployment: AbilityType;
124
- request_deployment_status: AbilityType;
125
- data_restore: AbilityType;
126
- update_edge: AbilityType;
127
- update_firmware: AbilityType;
128
- restore_backup: AbilityType;
129
- backup: AbilityType;
130
- log_upload: AbilityType;
131
- reboot: AbilityType;
132
- reset: AbilityType;
133
- data_reset: AbilityType;
134
- heartbeat: AbilityType;
135
- software_update: AbilityType;
136
- status: AbilityType;
137
- provision_marmon_button: AbilityType;
138
- greengrass_initialize: AbilityType;
139
- greengrass_restart: AbilityType;
140
- greengrass_redeploy: AbilityType;
141
- amag_add_modify_card_holder: AbilityType;
142
- amag_delete_card_holder: AbilityType;
143
- activate_cloud_native_device: AbilityType;
144
- deactivate_cloud_native_device: AbilityType;
145
- lwm2m_request: AbilityType;
146
- }
147
- export interface AbilityAndAction {
148
- [index: string]: unknown;
149
- }
150
- export interface AbilityForUser {
151
- act_as: AbilityType;
152
- update_user_type: AbilityType;
153
- }
154
- export interface AbilityAndPayload {
155
- read_payload: AbilityType;
156
- }
157
- export interface AbilityAndExecute {
158
- execute: AbilityType;
159
- }
160
- export interface CRUDActions {
161
- create: boolean;
162
- read: boolean;
163
- update: boolean;
164
- delete: boolean;
165
- }
166
- export interface Actions {
167
- sms_at_command_status_request: boolean;
168
- notification: boolean;
169
- enable_data_restriction: boolean;
170
- disable_data_restriction: boolean;
171
- send_config: boolean;
172
- deploy_deployment: boolean;
173
- request_deployment_status: boolean;
174
- data_restore: boolean;
175
- update_edge: boolean;
176
- update_firmware: boolean;
177
- restore_backup: boolean;
178
- backup: boolean;
179
- log_level: boolean;
180
- log_config: boolean;
181
- log_upload: boolean;
182
- reboot: boolean;
183
- reset: boolean;
184
- data_reset: boolean;
185
- heartbeat: boolean;
186
- status: boolean;
187
- software_update: boolean;
188
- provision_marmon_button: boolean;
189
- greengrass_initialize: boolean;
190
- greengrass_restart: boolean;
191
- greengrass_redeploy: boolean;
192
- amag_add_modify_card_holder: boolean;
193
- amag_delete_card_holder: boolean;
194
- activate_cloud_native_device: boolean;
195
- deactivate_cloud_native_device: boolean;
196
- lwm2m_request: boolean;
197
- log: boolean;
198
- sms: boolean;
199
- email: boolean;
200
- relay: boolean;
201
- http_request: boolean;
202
- mqtt: boolean;
203
- aws_iot: boolean;
204
- bluemix_iot: boolean;
205
- azure_iot: boolean;
206
- tcp: boolean;
207
- prtg: boolean;
208
- tcp_modbus: boolean;
209
- opcua: boolean;
210
- bacnet: boolean;
211
- }
212
- export interface ActionParam {
213
- field: string;
214
- description: string;
215
- type?: string;
216
- allowed_values?: string[];
217
- }
218
- export interface ActionTypeDescription {
219
- type: ActionType;
220
- description: string;
221
- params: ActionParam[];
222
- device_integration: boolean;
223
- edge: boolean;
224
- cloud: boolean;
225
- }
226
- export interface AmagCardHolder {
227
- first_name?: string;
228
- last_name?: string;
229
- card_number?: number;
230
- pin?: string;
231
- employee_reference?: string;
232
- company_id?: number;
233
- customer_code?: number;
234
- access_code_id?: number;
235
- active_date?: string;
236
- expiry_date?: string;
237
- personal_data: string[];
238
- }
239
- export interface Application {
240
- name: string;
241
- description: string;
242
- app_config?: AppConfig;
243
- }
244
- export interface Port {
245
- port_number: number;
246
- protocol: string;
247
- }
248
- export interface AppConfig {
249
- type: AppConfigType;
250
- env: EnvVar[];
251
- readiness_probe?: HealthProbe;
252
- liveness_probe?: HealthProbe;
253
- image?: string;
254
- ports?: Port[];
255
- command?: string[];
256
- args?: string[];
257
- restart_policy?: RestartPolicy;
258
- }
259
- export interface RestartPolicy {
260
- trigger_type: RestartPolicyTriggerType;
261
- backoff_multiplier?: number;
262
- backoff_initial_seconds?: number;
263
- backoff_maximum_seconds?: number;
264
- }
265
- export interface EnvVar {
266
- name: string;
267
- value: string;
268
- }
269
- export interface HealthProbe {
270
- type: HealthProbeType;
271
- period_seconds: number;
272
- delay_seconds: number;
273
- http_health_probe?: HTTPHealthProbe;
274
- command_health_probe?: CommandHealthProbe;
275
- }
276
- export interface HTTPHealthProbe {
277
- path: string;
278
- timeout_seconds: number;
279
- }
280
- export interface CommandHealthProbe {
281
- command: string[];
282
- timeout_seconds: number;
283
- }
284
- export interface Audit {
285
- request_method: string;
286
- request_path: string;
287
- resource_type: string;
288
- resource: string;
289
- requestor_user_id: string;
290
- requestor_user_type_id: string;
291
- act_as_user_id: string;
292
- act_as_user_type_id: string;
293
- response_code: number;
294
- error_message: string;
295
- errors: string[];
296
- }
297
- export interface Base {
298
- _id?: IDType;
299
- origin: OriginType;
300
- created_at: string;
301
- updated_at: string;
302
- company_id: string;
303
- user_id: IDType;
304
- }
305
- export interface BaseStringSQL {
306
- _id?: string;
307
- origin: OriginType;
308
- created_at: string;
309
- updated_at: string;
310
- company_id: string;
311
- user_id: string;
312
- }
313
- export interface BrokerResponse {
314
- result: string;
315
- }
316
- export interface RawBrokerEvent {
317
- id: string;
318
- event_type: string;
319
- client_id: string;
320
- topic: string;
321
- datetime: string;
322
- retain?: boolean;
323
- }
324
- export interface BrokerEvent {
325
- id: string;
326
- event_type: string;
327
- client_id: string;
328
- company_id: string;
329
- device_id: string;
330
- topic: string;
331
- topic_type: string;
332
- is_downstream: boolean;
333
- is_upstream: boolean;
334
- is_gateway_command: boolean;
335
- is_device_authority: boolean;
336
- is_report: boolean;
337
- is_heartbeat: boolean;
338
- retained: boolean;
339
- datetime: string;
340
- }
341
- export interface BulkRequest {
342
- type: BulkRequestType;
343
- unique_ids: string[];
344
- name_prefix: string;
345
- name_template: string;
346
- device?: Device;
347
- device_type?: DeviceType;
348
- escrow_device?: EscrowDevice;
349
- body: string;
350
- ids: string[];
351
- model_type: ModelType;
352
- cascade?: boolean;
353
- csv_rows: string[][];
354
- gateway_command_request?: GatewayCommandRequest;
355
- email_callback: boolean;
356
- email_override: string;
357
- user?: User;
358
- user_type?: UserType;
359
- bulk_response_id: string;
360
- context?: WorkflowContext;
361
- definition_id: string;
362
- generate_child_command_executions?: boolean;
363
- }
364
- export interface BulkSingleResponse {
365
- status?: number;
366
- id?: string;
367
- error?: string;
368
- messages?: string[];
369
- }
370
- export interface BulkResponseUpdate {
371
- status: BulkStatus;
372
- success?: {
373
- [key: string]: BulkSingleResponse;
374
- };
375
- fail?: {
376
- [key: string]: BulkSingleResponse;
377
- };
378
- }
379
- export interface BulkResponse {
380
- type: string;
381
- total: number;
382
- bulk_response_statuses: (BulkResponseStatus | undefined)[];
383
- generate_child_command_executions?: boolean;
384
- }
385
- export interface BulkResponseStatus {
386
- status_code?: number;
387
- status?: BulkResponseStatusType;
388
- error?: string;
389
- messages?: string[];
390
- csv_errors?: CSVError[];
391
- bulk_response_id: string;
392
- device_id: string;
393
- workflow_record_id?: string;
394
- }
395
- export interface BulkResponseID {
396
- bulk_response_id: string;
397
- }
398
- export interface BulkCSVRow {
399
- row: string[];
400
- user?: User;
401
- }
402
- export interface Command {
403
- name?: string;
404
- sender_type?: SenderType;
405
- sender?: {
406
- [key: string]: unknown;
407
- };
408
- long_description?: string;
409
- options?: {
410
- [key: string]: unknown;
411
- };
412
- payload?: {
413
- [key: string]: unknown;
414
- };
415
- translator_id: string;
416
- generate_child_command_executions: boolean;
417
- }
418
- export interface CommandWithDeviceID {
419
- device_id: string;
420
- }
421
- export interface Branding {
422
- logo_url: string;
423
- icon_url: string;
424
- primary_color: string;
425
- logo_background_color: string;
426
- portal_title: string;
427
- }
428
- export interface Aliases {
429
- gateway: string;
430
- device: string;
431
- }
432
- export interface Company {
433
- name: string;
434
- website?: string;
435
- branding?: Branding;
436
- aliases?: Aliases;
437
- view_abilities: ViewAbilities;
438
- portal_configuration: PortalConfiguration;
439
- metadata?: {
440
- [key: string]: unknown;
441
- };
442
- inherited_device_type_ids: string[];
443
- inherited_integration_ids: string[];
444
- inherited_ingestor_ids: string[];
445
- inherited_translator_ids: string[];
446
- inherited_rule_ids: string[];
447
- inherited_pollable_attributes_ids: string[];
448
- inherited_workflow_definition_ids: string[];
449
- device_tags: string[];
450
- }
451
- export interface Config {
452
- id: string;
453
- name: string;
454
- unique_id: string;
455
- device_type?: DeviceTypeWithRelations;
456
- heartbeat_period: number;
457
- sms_password: string;
458
- auto_relay_reports: boolean;
459
- bluemix_auth_token: string;
460
- aws_greengrass_core_thing_arn: string;
461
- aws_keys_and_certificate?: AWSKeysAndCertificate;
462
- device_ha_group?: DeviceHAGroupWithKeyPair;
463
- heartbeat_values: string[];
464
- connections: Connection[];
465
- iptables?: (IPTableAction | undefined)[];
466
- devices: (DeviceWithRules | undefined)[];
467
- device_types: (DeviceTypeWithRelations | undefined)[];
468
- ingestors: (Ingestor | undefined)[];
469
- commanders: (Command | undefined)[];
470
- translators: (Translator | undefined)[];
471
- integrations: (Integration | undefined)[];
472
- integration_ids: string[];
473
- user?: UserWithPasswordAndToken;
474
- rules: (Rule | undefined)[];
475
- log_config?: LogConfig;
476
- metadata: {
477
- [key: string]: string;
478
- };
479
- }
480
- export interface ConfigV2 {
481
- filename: string;
482
- md5: string;
483
- }
484
- export interface DeviceCountsByStatus {
485
- online_device_count: number;
486
- offline_device_count: number;
487
- idle_device_count: number;
488
- never_reported_device_count: number;
489
- low_signal_device_count: number;
490
- }
491
- export interface DeviceCountsBySignal {
492
- excellent: number;
493
- good: number;
494
- moderate: number;
495
- poor: number;
496
- disconnected: number;
497
- }
498
- export interface DashboardStats {
499
- statuses: DeviceCountsByStatus;
500
- by_signal: DeviceCountsBySignal;
501
- no_group: number;
502
- no_attached_devices: number;
503
- cell_usage_total: number;
504
- }
505
- export interface StatusesByLocation {
506
- all_locations: string[];
507
- status_by_location: {
508
- [key: string]: DeviceCountsByStatus;
509
- };
510
- }
511
- export interface Deployment {
512
- name: string;
513
- description: string;
514
- application_statuses?: {
515
- [key: string]: string;
516
- };
517
- application_ids: string[];
518
- applications: (Application | undefined)[];
519
- }
520
- export interface DeploymentApplication {
521
- DeploymentId: string;
522
- ApplicationId: string;
523
- }
524
- export interface dlGeographicPoint {
525
- X: number;
526
- Y: number;
527
- }
528
- export interface DeviceLocationObservation {
529
- device_id: string;
530
- device_unique_id: string;
531
- via: DeviceLocationObservationVia;
532
- generated_at: string;
533
- horizontal_accuracy_meters: number;
534
- latitude: string;
535
- longitude: string;
536
- }
537
- export interface DeviceLocationObservationWithGeoJSON {
538
- geojson?: GeoJsonFeature;
539
- }
540
- export interface DeviceUniqueID {
541
- CompanyID: string;
542
- UniqueID: string;
543
- }
544
- export interface DeviceState {
545
- device_online?: string;
546
- device_offline?: string;
547
- }
548
- export interface Device {
549
- name: string;
550
- unique_id: string;
551
- report_count: number;
552
- auto_relay_reports: boolean;
553
- active: boolean;
554
- lwm2m_bootstrap_psk_secret_id?: string;
555
- lwm2m_bootstrap_psk?: string;
556
- bluemix_auth_token?: string;
557
- aws_keys_and_certificate?: AWSKeysAndCertificate;
558
- aws_keys_and_certificate_secret_id?: string;
559
- aws_greengrass_core_thing_arn?: string;
560
- aws_greengrass_group_id?: string;
561
- edge_version: string;
562
- firmware_version: string;
563
- serial: string;
564
- activated_at?: string;
565
- deactivated_at?: string;
566
- status_at: string;
567
- status_messages?: StatusMessage[];
568
- command_status?: CommandStatus[];
569
- config_status?: ConfigStatus;
570
- platform_tag?: string;
571
- build_tags?: string[];
572
- connections_status?: {
573
- [key: string]: {
574
- [key: string]: string;
575
- };
576
- };
577
- provision_status?: ProvisionStatusType;
578
- health_status: DeviceHealthStatus;
579
- heartbeat_at: string;
580
- heartbeat_values: string[];
581
- heartbeat_period: number;
582
- heartbeat_status: HeartbeatStatusType;
583
- last_heartbeat_status: HeartbeatStatusType;
584
- log_config?: LogConfig;
585
- max_persisted_reports?: number;
586
- location: string;
587
- sms_password?: string;
588
- last_sms_status?: string;
589
- last_sms_sent_at?: string;
590
- cell_number?: string;
591
- cell_signal: number;
592
- cell_usage?: CellUsageInfo;
593
- cell_status?: string;
594
- parent_device_id?: string;
595
- device_type_id?: string;
596
- device_config_id: string;
597
- last_report_id?: string;
598
- last_notification_id?: string;
599
- last_location_observation_id?: string;
600
- device_integration_id?: string;
601
- cloud_native_integration_id?: string;
602
- sms_integration_id?: string;
603
- ingestor_ids: string[];
604
- command_ids: string[];
605
- attached_device_ids: string[];
606
- device_ha_group_id: string;
607
- deployment_id: string;
608
- tags: string[];
609
- metadata: {
610
- [key: string]: string;
611
- };
612
- }
613
- export interface DeviceWithLastKnownLocation {
614
- last_known_geographic_location?: GeoJsonFeature;
615
- }
616
- export interface DeviceRule {
617
- DeviceId: string;
618
- RuleId: string;
619
- }
620
- export interface DeviceIngestor {
621
- DeviceId: string;
622
- IngestorId: string;
623
- }
624
- export interface DeviceCommand {
625
- DeviceId: string;
626
- CommandId: string;
627
- }
628
- export interface DeviceWithRules {
629
- rules: (Rule | undefined)[];
630
- }
631
- export interface LogConfig {
632
- local_level: LogLevel;
633
- forward_level: LogLevel;
634
- forward_frequency_limit: number;
635
- }
636
- export interface ConfigStatus {
637
- received: boolean;
638
- valid: boolean;
639
- configured: boolean;
640
- greengrass_installed: boolean;
641
- }
642
- export interface StatusMessage {
643
- message: string;
644
- status_type: string;
645
- timestamp: string;
646
- }
647
- export interface CommandStatus {
648
- command: string;
649
- message_id: string;
650
- timestamp: string;
651
- }
652
- export interface CellUsageInfo {
653
- last: number;
654
- total: number;
655
- year: number;
656
- month: number;
657
- week: number;
658
- day: number;
659
- }
660
- export interface AWSKeysAndCertificate {
661
- certificate_arn?: string;
662
- certificate_id?: string;
663
- certificate_pem?: string;
664
- key_pair?: AWSKeyPair;
665
- }
666
- export interface AWSKeyPair {
667
- private_key: string;
668
- public_key: string;
669
- }
670
- export interface DeviceConfig {
671
- name: string;
672
- connections: Connection[];
673
- iptables: (IPTableAction | undefined)[];
674
- device_type_id: string;
675
- last_notification_id?: string;
676
- }
677
- export interface IPTableAction {
678
- action?: string;
679
- chain?: string;
680
- table?: string;
681
- protocol?: string;
682
- in_interface?: string;
683
- out_interface?: string;
684
- source_port?: string;
685
- destination_port?: string;
686
- source?: string;
687
- destination?: string;
688
- jump?: string;
689
- }
690
- export interface Connection {
691
- type: string;
692
- name: string;
693
- config: {
694
- [key: string]: unknown;
695
- };
696
- }
697
- export interface ConnectionConfig {
698
- [index: string]: unknown;
699
- }
700
- export interface NetworkConfig {
701
- net_enable?: number;
702
- net_ip_assign?: string;
703
- net_mode?: string;
704
- net_type?: string;
705
- net_ip?: string;
706
- net_mask?: string;
707
- net_gateway?: string;
708
- net_broadcast?: string;
709
- net_nat?: number;
710
- net_mtu?: number;
711
- net_metric?: number;
712
- net_dns_1?: string;
713
- net_dns_2?: string;
714
- }
715
- export interface DHCPConfig {
716
- dhcp_relay?: number;
717
- dhcp_enable?: number;
718
- dhcp_start?: string;
719
- dhcp_end?: string;
720
- dhcp_lease?: number;
721
- dhcp_dns1?: string;
722
- dhcp_dns2?: string;
723
- }
724
- export interface WifiConfig {
725
- wifi_enable?: number;
726
- wifi_mode?: string;
727
- wifi_ssid?: string;
728
- wifi_auth?: string;
729
- wifi_crypt?: string;
730
- wifi_psk?: string;
731
- wifi_channel?: number;
732
- wifi_hidden?: number;
733
- }
734
- export interface CellularConfig {
735
- cell_enable?: number;
736
- cell_auto_apn?: number;
737
- cell_apn?: string;
738
- cell_user?: string;
739
- cell_pass?: string;
740
- cell_auth?: string;
741
- cell_reconn_delay?: number;
742
- cell_reconn_retries?: number;
743
- cell_metric?: number;
744
- cell_mtu?: number;
745
- }
746
- export interface FirewallRule {
747
- rule_enable?: number;
748
- rule_name?: string;
749
- rule_options: {
750
- [key: string]: unknown;
751
- };
752
- }
753
- export interface FirewallConfig {
754
- firewall_enable?: number;
755
- firewall_rules?: FirewallRule[];
756
- }
757
- export interface DeviceError {
758
- type: DeviceErrorType;
759
- level: number;
760
- error: string;
761
- device_id: string;
762
- rule_action_count: number;
763
- }
764
- export interface DeviceHAGroup {
765
- name: string;
766
- ports: number[];
767
- controller_device: HADevice;
768
- node_devices: HADevice[];
769
- }
770
- export interface KeyPair {
771
- public_key: string;
772
- private_key: string;
773
- }
774
- export interface HADevice {
775
- device_id: string;
776
- device_unique_id?: string;
777
- interface: string;
778
- ip?: string;
779
- aws_keys_and_certificate?: AWSKeysAndCertificate;
780
- }
781
- export interface DeviceHAGroupWithKeyPair {
782
- key_pair?: KeyPair;
783
- }
784
- export interface DeviceHealthStatusEvent {
785
- device_id: string;
786
- rule_id?: string;
787
- status: DeviceHealthStatus;
788
- reason: string;
789
- }
790
- export interface DeviceTemplate {
791
- name: string;
792
- description: string;
793
- name_template: string;
794
- device_company_id: string;
795
- heartbeat_values: string[];
796
- heartbeat_period: number;
797
- log_config?: LogConfig;
798
- location: string;
799
- device_type_id: string;
800
- device_config_id: string;
801
- device_integration_id?: string;
802
- cloud_native_integration_id?: string;
803
- deployment_id: string;
804
- tags: string[];
805
- metadata: {
806
- [key: string]: string;
807
- };
808
- }
809
- export interface DeviceTransferRequest {
810
- transferred_at?: string;
811
- from_company_id: string;
812
- to_company_id: string;
813
- status: DeviceTransferRequestStatus;
814
- errors?: {
815
- [key: string]: string;
816
- };
817
- device_type_id: string;
818
- device_template_id: string;
819
- escrow_device_ids: string[];
820
- }
821
- export interface DeviceType {
822
- name: string;
823
- image: string;
824
- model: string;
825
- manufacturer: string;
826
- long_description: string;
827
- type?: DType;
828
- capabilities?: Capabilities;
829
- heartbeat_values?: string[];
830
- origin_id: string;
831
- ingestor_ids: string[];
832
- command_ids: string[];
833
- software_update_ids: string[];
834
- metadata: {
835
- [key: string]: string;
836
- };
837
- }
838
- export interface DeviceTypeRule {
839
- DeviceTypeId: string;
840
- RuleId: string;
841
- }
842
- export interface DeviceTypeIngestor {
843
- DeviceTypeId: string;
844
- IngestorId: string;
845
- }
846
- export interface DeviceTypeCommand {
847
- DeviceTypeId: string;
848
- CommandId: string;
849
- }
850
- export interface DeviceTypePollableAttributes {
851
- DeviceTypeId: string;
852
- PollableAttributesID: string;
853
- }
854
- export interface DeviceTypeWithRelations {
855
- rules: (Rule | undefined)[];
856
- pollable_attributes: (PollableAttributes | undefined)[];
857
- }
858
- export interface Capabilities {
859
- network_connections: NetworkConnection[];
860
- peripherals: Peripheral[];
861
- iptables: boolean;
862
- firmware: Firmware;
863
- actions?: Actions;
864
- sms_at_commands?: SMSATCommands;
865
- }
866
- export interface SMSATCommands {
867
- status_commands: string[];
868
- send_config_commands: string[];
869
- }
870
- export interface NetworkConnection {
871
- type: string;
872
- interface?: string;
873
- name: string;
874
- }
875
- export interface Peripheral {
876
- type: string;
877
- device: string;
878
- }
879
- export interface Firmware {
880
- upgrade: boolean;
881
- backup: boolean;
882
- }
883
- export interface DownstreamSystem {
884
- name: string;
885
- description: string;
886
- system_commands: (SystemCommand | undefined)[];
887
- }
888
- export interface EdgeBuilderRequest {
889
- company_id: string;
890
- manufacturer: string;
891
- model: string;
892
- environment: string;
893
- version: string;
894
- features: string[];
895
- }
896
- export interface EdgeBuilderResponse {
897
- installer_url: string;
898
- install_script: string;
899
- }
900
- export interface InsufficientPermissionsError {
901
- [index: string]: unknown;
902
- }
903
- export interface NotFoundError {
904
- [index: string]: unknown;
905
- }
906
- export interface EscrowDeviceEnquiry {
907
- _id?: string;
908
- created_at: string;
909
- updated_at: string;
910
- name: string;
911
- company_name: string;
912
- phone_number: string;
913
- email_address: string;
914
- escrow_token: string;
915
- }
916
- export interface EscrowDevice {
917
- transfer_initiated_at?: string;
918
- transfer_completed_at?: string;
919
- unique_id: string;
920
- token: string;
921
- lwm2m: boolean;
922
- lwm2m_bootstrap_psk_secret_id?: string;
923
- lwm2m_bootstrap_psk?: string;
924
- }
925
- export interface URLGatewayCommandPayload {
926
- url: string;
927
- }
928
- export interface VersionGatewayCommandPayload {
929
- version: string;
930
- }
931
- export interface EnableGatewayCommandPayload {
932
- enable: boolean;
933
- }
934
- export interface WhenGatewayCommandPayload {
935
- when: string;
936
- }
937
- export interface GatewayCommand {
938
- command_type: GatewayCommandType;
939
- payload: {
940
- [key: string]: unknown;
941
- };
942
- schedule?: CommandSchedule;
943
- timeout?: number;
944
- statuses: {
945
- [key: string]: GatewayCommandStatus;
946
- };
947
- device_config_id: string;
948
- device_id: string;
949
- device_unique_id: string;
950
- device_type_id: string;
951
- software_update_id?: string;
952
- attached_device_ids: string[];
953
- attached_device_unique_ids: string[];
954
- }
955
- export interface GatewayCommandStatus {
956
- status: string;
957
- status_message?: string;
958
- }
959
- export interface CommandSchedule {
960
- start_datetime: string;
961
- end_datetime: string;
962
- retry_interval?: RetryInterval;
963
- }
964
- export interface Lwm2mRequest {
965
- type: string;
966
- endpoint: string;
967
- data: unknown;
968
- }
969
- export interface GatewayCommandRequest {
970
- command_type: GatewayCommandType;
971
- schedule?: CommandSchedule;
972
- timeout: number;
973
- url?: string;
974
- version?: string;
975
- software_update_id?: string;
976
- when?: string;
977
- level?: string;
978
- enable?: boolean;
979
- card_holder?: AmagCardHolder;
980
- attached_device_ids?: string[];
981
- _: string[];
982
- }
983
- export interface GreengrassFunction {
984
- name?: string;
985
- id: string;
986
- arn: string;
987
- latest_version?: string;
988
- latest_version_arn?: string;
989
- functions?: GreengrassLambdaFunction[];
990
- }
991
- export interface GreengrassLambdaFunction {
992
- id: string;
993
- arn: string;
994
- pinned: boolean;
995
- executable: string;
996
- environment: {
997
- [key: string]: string | undefined;
998
- };
999
- exec_args: string;
1000
- memory_size: number;
1001
- timeout: number;
1002
- }
1003
- export interface GreengrassSubscription {
1004
- name?: string;
1005
- id: string;
1006
- arn: string;
1007
- latest_version?: string;
1008
- latest_version_arn?: string;
1009
- subscriptions?: GreengrassSubscriptionDefinition[];
1010
- }
1011
- export interface GreengrassSubscriptionDefinition {
1012
- id: string;
1013
- source: string;
1014
- subject: string;
1015
- target: string;
1016
- }
1017
- export interface GreengrassConnectivityInfo {
1018
- message: string;
1019
- hosts: GreengrassConnectivityInfoDefinition[];
1020
- }
1021
- export interface GreengrassConnectivityInfoDefinition {
1022
- host_address: string;
1023
- port_number: number;
1024
- }
1025
- export interface HookResult {
1026
- result: unknown;
1027
- modifiers?: HookModifiers;
1028
- topics?: HookTopic[];
1029
- }
1030
- export interface HookModifiers {
1031
- max_message_size?: number;
1032
- max_inflight_messages?: number;
1033
- retry_interval?: number;
1034
- topic?: string;
1035
- qos?: number;
1036
- payload?: string;
1037
- retain?: boolean;
1038
- }
1039
- export interface HookTopic {
1040
- topic: string;
1041
- qos?: number;
1042
- }
1043
- export interface HookError {
1044
- error: string;
1045
- }
1046
- export interface AuthOnRegisterEvent {
1047
- peer_addr: string;
1048
- peer_port: number;
1049
- username: string;
1050
- password: string;
1051
- mountpoint: string;
1052
- client_id: string;
1053
- clean_session: boolean;
1054
- }
1055
- export interface AuthOnPublishEvent {
1056
- username: string;
1057
- client_id: string;
1058
- mountpoint: string;
1059
- qos: number;
1060
- topic: string;
1061
- payload: string;
1062
- retain: boolean;
1063
- }
1064
- export interface AuthOnSubscribeEvent {
1065
- username: string;
1066
- client_id: string;
1067
- mountpoint: string;
1068
- topics: HookTopic[];
1069
- }
1070
- export interface Ingestor {
1071
- name: string;
1072
- type: IngestorType;
1073
- target_map?: {
1074
- [key: string]: string;
1075
- };
1076
- target_template?: string;
1077
- listener_type?: ListenerType;
1078
- listener?: {
1079
- [key: string]: unknown;
1080
- };
1081
- handler_type?: HandlerType;
1082
- handler?: {
1083
- [key: string]: unknown;
1084
- };
1085
- translator?: {
1086
- [key: string]: unknown;
1087
- };
1088
- translator_id: string;
1089
- }
1090
- export interface IngestorShadow {
1091
- created_at: string;
1092
- updated_at: string;
1093
- ingestor_id: string;
1094
- company_id: string;
1095
- listener_type: ListenerType;
1096
- listener: {
1097
- [key: string]: unknown;
1098
- };
1099
- translator_id: string;
1100
- high_water_mark: {
1101
- [key: string]: unknown;
1102
- };
1103
- run_count: number;
1104
- last_completed_at: string;
1105
- min_timeout: number;
1106
- }
1107
- export interface EdgeInstanceRequest {
1108
- company_id: string;
1109
- unique_id: string;
1110
- }
1111
- export interface EdgeInstanceResponse {
1112
- [index: string]: unknown;
1113
- }
1114
- export interface EdgeInstanceListRequest {
1115
- company_id: string;
1116
- }
1117
- export interface EdgeInstanceListResponse {
1118
- edge_instances: EdgeInstance[];
1119
- }
1120
- export interface EdgeInstance {
1121
- name: string;
1122
- labels: {
1123
- [key: string]: string;
1124
- };
1125
- }
1126
- export interface Integration {
1127
- name: string;
1128
- archetype: IntegrationArchetype;
1129
- type: IntegrationType;
1130
- init_status?: string;
1131
- long_description: string;
1132
- inmarsat_client_id?: string;
1133
- inmarsat_secret?: string;
1134
- inmarsat_username?: string;
1135
- inmarsat_password?: string;
1136
- inmarsat_customer_id?: string;
1137
- inmarsat_scap_id?: string;
1138
- inmarsat_industry_code?: string;
1139
- inmarsat_mailbox_id?: string;
1140
- orbcomm_username?: string;
1141
- orbcomm_password?: string;
1142
- orbcomm_solution_provider_id?: string;
1143
- orbcomm_gateway_account_id?: string;
1144
- gs_username?: string;
1145
- gs_password?: string;
1146
- gs_customer_id?: string;
1147
- gs_rate_plan_id?: string;
1148
- gs_address_id?: string;
1149
- region?: string;
1150
- external_id?: string;
1151
- role_arn?: string;
1152
- device_gateway_url?: string;
1153
- greengrass_core_install_url?: string;
1154
- iot_hub_hostname?: string;
1155
- shared_access_key?: string;
1156
- access_policy_name?: string;
1157
- sas_token?: string;
1158
- org_id?: string;
1159
- api_key?: string;
1160
- auth_token?: string;
1161
- sid?: string;
1162
- token?: string;
1163
- from?: string;
1164
- callback_to_machineshop?: boolean;
1165
- server?: string;
1166
- username?: string;
1167
- password?: string;
1168
- identification_token?: string;
1169
- }
1170
- export interface IntegrationTypeDescription {
1171
- type: IntegrationType;
1172
- readable_type: string;
1173
- device_integration_type: boolean;
1174
- cloud_integration_type: boolean;
1175
- associated_action_type?: ActionType;
1176
- fields: string[];
1177
- }
1178
- export interface LambdaFunction {
1179
- arn: string;
1180
- name: string;
1181
- description: string;
1182
- }
1183
- export interface LambdaFunctionVersion {
1184
- arn: string;
1185
- name: string;
1186
- description: string;
1187
- version: string;
1188
- revision_id: string;
1189
- role: string;
1190
- environment: {
1191
- [key: string]: string | undefined;
1192
- };
1193
- timeout: number;
1194
- memory_size: number;
1195
- }
1196
- export interface LocationTransitionEvaluator {
1197
- region_id: string;
1198
- direction: LocationTransitionDirectionType;
1199
- num_observations_to_consider: number;
1200
- required_num_breaching_observations: number;
1201
- confidence_threshold: number;
1202
- allow_breach_on_initial_observation: boolean;
1203
- }
1204
- export interface LocationRelation {
1205
- region_id: string;
1206
- device_location_observation?: DeviceLocationObservationWithGeoJSON;
1207
- confidence_in: number;
1208
- geojson?: GeoJsonFeatureCollection;
1209
- }
1210
- export interface LocationTransition {
1211
- device_name: string;
1212
- device_id: string;
1213
- company_id: string;
1214
- device_unique_id: string;
1215
- region_name: string;
1216
- region_id: string;
1217
- location_relations: LocationRelation[];
1218
- geojson: GeoJsonFeatureCollection;
1219
- }
1220
- export interface Lwm2mObjectLinks {
1221
- _id: string;
1222
- company_id: string;
1223
- created_at: string;
1224
- device_id: string;
1225
- links: Lwm2mObjectLink[];
1226
- }
1227
- export interface Lwm2mObjectLink {
1228
- url: string;
1229
- description?: string;
1230
- attributes?: Lwm2mAttributes;
1231
- }
1232
- export interface Lwm2mAttributes {
1233
- rt?: string;
1234
- ver?: string;
1235
- }
1236
- export interface Lwm2mState {
1237
- _id: string;
1238
- company_id: string;
1239
- created_at: string;
1240
- device_id: string;
1241
- state: Lwm2mStateObject;
1242
- }
1243
- export interface Migration {
1244
- Version: string;
1245
- Migrated: string;
1246
- }
1247
- export interface MQTTGatewayCommand {
1248
- id?: string;
1249
- command: GatewayCommandType;
1250
- schedule?: CommandSchedule;
1251
- payload: {
1252
- [key: string]: unknown;
1253
- };
1254
- attached_device_unique_ids: string[];
1255
- }
1256
- export interface SoftwareUpdateCommandPayload {
1257
- name: string;
1258
- files: (FileLocation | undefined)[];
1259
- script: string;
1260
- reboot: boolean;
1261
- }
1262
- export interface Notification {
1263
- message: string;
1264
- device_id: string;
1265
- rule_id: string;
1266
- device_config_id?: string;
1267
- }
1268
- export interface Params {
1269
- Inflate: boolean;
1270
- PageMeta: boolean;
1271
- Page: number;
1272
- PerPage: number;
1273
- NextToken: string;
1274
- OrderBy: string;
1275
- UI: boolean;
1276
- Locations: string[];
1277
- LowSignalValue: number;
1278
- Filters: Filter[];
1279
- ModelType: ModelType;
1280
- Cascade: boolean;
1281
- ActAs: string;
1282
- EmailCallback: boolean;
1283
- EmailOverride: string;
1284
- }
1285
- export interface Filter {
1286
- Operator: string;
1287
- Token: string;
1288
- Value: unknown;
1289
- Values: unknown[];
1290
- }
1291
- export interface PollableAttributes {
1292
- type: string;
1293
- name: string;
1294
- interval: number;
1295
- defaults: {
1296
- [key: string]: unknown;
1297
- };
1298
- attributes: Attribute[];
1299
- }
1300
- export interface Attribute {
1301
- name: string;
1302
- value: string;
1303
- data_type: string;
1304
- }
1305
- export interface PollingStatus {
1306
- Ingestor?: Ingestor;
1307
- HighWaterMark: {
1308
- [key: string]: unknown;
1309
- };
1310
- RunCount: number;
1311
- CompletedAt: string;
1312
- MinTimeout: number;
1313
- }
1314
- export interface PollingJob {
1315
- Ingestor?: Ingestor;
1316
- HighWaterMark: {
1317
- [key: string]: unknown;
1318
- };
1319
- RunCount: number;
1320
- CreatedAt: string;
1321
- MinTimeout: number;
1322
- }
1323
- export interface IngestorState {
1324
- State: string;
1325
- IngestorID: string;
1326
- }
1327
- export interface PortalNavigationVisibility {
1328
- action_hub_hidden: boolean;
1329
- onboarding_hidden: boolean;
1330
- overview_hidden: boolean;
1331
- messages_hidden: boolean;
1332
- alerts_hidden: boolean;
1333
- lifecycle_hidden: boolean;
1334
- devices_hidden: boolean;
1335
- rules_hidden: boolean;
1336
- software_hidden: boolean;
1337
- integrations_hidden: boolean;
1338
- users_hidden: boolean;
1339
- roles_hidden: boolean;
1340
- companies_hidden: boolean;
1341
- configs_hidden: boolean;
1342
- ingest_hidden: boolean;
1343
- transfers_hidden: boolean;
1344
- ha_groups_hidden: boolean;
1345
- reports_hidden: boolean;
1346
- secrets_hidden: boolean;
1347
- pollable_attributes_hidden: boolean;
1348
- }
1349
- export interface ReportsOptions {
1350
- time_filter_options: TimeFilterOption[];
1351
- }
1352
- export interface TimeFilterOption {
1353
- display: string;
1354
- value: string;
1355
- }
1356
- export interface WidgetVisibility {
1357
- software_updates_hidden: boolean;
1358
- data_usage_hidden: boolean;
1359
- }
1360
- export interface PortalConfiguration {
1361
- navigation: PortalNavigationVisibility;
1362
- reports_options: ReportsOptions;
1363
- widgets: WidgetVisibility;
1364
- }
1365
- export interface SimpleMessage {
1366
- Verb: string;
1367
- Object: string;
1368
- }
1369
- export interface QueueMessage {
1370
- CompanyID: string;
1371
- ID: string;
1372
- ParentID: string;
1373
- Bytes: string;
1374
- }
1375
- export interface Lwm2mQueueMessage {
1376
- Client: string;
1377
- Data: {
1378
- [key: string]: unknown;
1379
- };
1380
- Links: Lwm2mObjectLink[];
1381
- }
1382
- export interface Lwm2mDeviceSyncEventQueueMessage {
1383
- action: string;
1384
- unique_id: string;
1385
- company_id?: string;
1386
- secret?: string;
1387
- }
1388
- export interface Lwm2mRequestQueueMessage {
1389
- client: string;
1390
- type: string;
1391
- endpoint: string;
1392
- data: string;
1393
- }
1394
- export interface TranslateQueueMessage {
1395
- IngestorID: string;
1396
- DeviceUniqueID: string;
1397
- Metadata: {
1398
- [key: string]: unknown;
1399
- };
1400
- Message: string;
1401
- }
1402
- export interface SystemCommandJobQueueMessage {
1403
- DownstreamSystem?: DownstreamSystem;
1404
- SystemCommand?: SystemCommand;
1405
- SystemCommandJob?: SystemCommandJob;
1406
- }
1407
- export interface DeviceTransferJobQueueMessage {
1408
- DeviceTransferRequest?: DeviceTransferRequest;
1409
- RequestingUser?: User;
1410
- }
1411
- export interface DeviceIntegrationActionQueueMessageData {
1412
- CallbackID: string;
1413
- Action: DeviceIntegrationActionType;
1414
- Integration?: Integration;
1415
- ParentDevice?: Device;
1416
- Device?: Device;
1417
- DeviceType?: DeviceType;
1418
- Report?: Report;
1419
- Topic: string;
1420
- Message: string;
1421
- LambdaFunctionName: string;
1422
- GreengrassFunction?: GreengrassFunction;
1423
- GreengrassFunctionARN: string;
1424
- GreengrassFunctionID: string;
1425
- GreengrassSubscription?: GreengrassSubscription;
1426
- GreengrassSubscriptionARN: string;
1427
- GreengrassSubscriptionID: string;
1428
- GreengrassGroupIDs: string[];
1429
- GreengrassConnectivityInfo?: GreengrassConnectivityInfo;
1430
- DeviceUniqueIDs: string[];
1431
- BulkResponseID: string;
1432
- Params?: Params;
1433
- }
1434
- export interface Region {
1435
- _id: string;
1436
- company_id: string;
1437
- name: string;
1438
- created_at: string;
1439
- updated_at?: string;
1440
- geojson: GeoJsonFeature;
1441
- metadata: {
1442
- [key: string]: unknown;
1443
- };
1444
- }
1445
- export interface Report {
1446
- _id?: string;
1447
- device_name: string;
1448
- created_at: string;
1449
- device_datetime: string;
1450
- payload: {
1451
- [key: string]: unknown;
1452
- };
1453
- raw_data?: string;
1454
- seq: number;
1455
- heartbeat: boolean;
1456
- type: ReportType;
1457
- company_id: string;
1458
- user_id: string;
1459
- device_id: string;
1460
- }
1461
- export interface ReportBSON {
1462
- ID: string;
1463
- DeviceDateTime?: string;
1464
- Payload: {
1465
- [key: string]: unknown;
1466
- };
1467
- RawData?: string;
1468
- Seq?: number;
1469
- DeviceID: string;
1470
- }
1471
- export interface HeartbeatPayloadBSON {
1472
- Status?: string;
1473
- EdgeVersion?: string;
1474
- CellSignal?: string;
1475
- CellUsage?: string;
1476
- SimCard?: string;
1477
- Connections: {
1478
- [key: string]: string;
1479
- };
1480
- WifiClients: string[];
1481
- CPUUsage?: string;
1482
- RAMUsage?: string;
1483
- DiskSize?: string;
1484
- DiskFree?: string;
1485
- DiskUsage?: string;
1486
- Seq?: string;
1487
- IPs: string[];
1488
- Custom: {
1489
- [key: string]: string;
1490
- };
1491
- LastEndpointReportAt: {
1492
- [key: string]: string;
1493
- };
1494
- }
1495
- export interface HeartbeatPayloadJSON {
1496
- status?: string;
1497
- edge_version?: string;
1498
- cell_signal?: string;
1499
- cell_usage?: string;
1500
- sim_card?: string;
1501
- connections: {
1502
- [key: string]: string;
1503
- };
1504
- wifi_clients: string[];
1505
- cpu_usage?: string;
1506
- ram_usage?: string;
1507
- disk_size?: string;
1508
- disk_free?: string;
1509
- disk_usage?: string;
1510
- seq?: string;
1511
- ips: string[];
1512
- custom: {
1513
- [key: string]: string;
1514
- };
1515
- last_endpoint_report_at: {
1516
- [key: string]: string;
1517
- };
1518
- }
1519
- export interface ErrorResponse {
1520
- error: string;
1521
- messages?: string[];
1522
- }
1523
- export interface PagedResponse {
1524
- page: number;
1525
- per_page: number;
1526
- total: number;
1527
- next_token?: string;
1528
- resources: unknown;
1529
- }
1530
- export interface CSVResponse {
1531
- success_count: number;
1532
- fail_count: number;
1533
- errors: CSVError[];
1534
- }
1535
- export interface CSVError {
1536
- row: number;
1537
- messages: string[];
1538
- }
1539
- export interface Rule {
1540
- active: boolean;
1541
- last_run_status: Status;
1542
- description: string;
1543
- plain_english: string;
1544
- then_actions: (RuleAction | undefined)[];
1545
- else_actions: (RuleAction | undefined)[];
1546
- rule_condition?: RuleCondition;
1547
- pass_count: number;
1548
- fail_count: number;
1549
- cloud_rule: boolean;
1550
- scheduled_only?: boolean;
1551
- schedule?: string;
1552
- scheduler_job_id?: string;
1553
- }
1554
- export interface RuleWithRelations {
1555
- device_type_id: string;
1556
- device_id: string;
1557
- }
1558
- export interface RuleContext {
1559
- Rule?: Rule;
1560
- Report?: Report;
1561
- Device?: Device;
1562
- DeviceType?: DeviceType;
1563
- DeviceError?: DeviceError;
1564
- DeviceConfig?: DeviceConfig;
1565
- Integration?: Integration;
1566
- LocationTransition?: LocationTransition;
1567
- }
1568
- export interface PRTGChannel {
1569
- name?: string;
1570
- value?: string;
1571
- type?: string;
1572
- default?: number;
1573
- enum?: {
1574
- [key: string]: number;
1575
- };
1576
- }
1577
- export interface RuleAction {
1578
- type: ActionType;
1579
- send_to?: string;
1580
- body_template?: string;
1581
- action_frequency: unknown;
1582
- retries: number;
1583
- retry_timeout: number;
1584
- clear: boolean;
1585
- last_run: string;
1586
- integration_id?: string;
1587
- url?: string;
1588
- topic?: string;
1589
- username?: string;
1590
- password?: string;
1591
- client_id?: string;
1592
- will_topic?: string;
1593
- keep_alive?: boolean;
1594
- method?: string;
1595
- headers?: {
1596
- [key: string]: string;
1597
- };
1598
- from?: string;
1599
- subject?: string;
1600
- body_type?: BodyType;
1601
- metadata_key?: string;
1602
- health_status?: DeviceHealthStatus;
1603
- latitude_template?: string;
1604
- longitude_template?: string;
1605
- radius_template?: string;
1606
- generated_at_template?: string;
1607
- generated_at_format?: string;
1608
- location_via?: string;
1609
- channels?: PRTGChannel[];
1610
- credentials?: Credentials;
1611
- definition_id?: string;
1612
- }
1613
- export interface Credentials {
1614
- type: string;
1615
- data: {
1616
- [key: string]: CredentialData;
1617
- };
1618
- }
1619
- export interface CredentialData {
1620
- type?: string;
1621
- value: string;
1622
- secret_id: string;
1623
- }
1624
- export interface RuleCondition {
1625
- type: RuleConditionType;
1626
- property?: string;
1627
- value?: unknown;
1628
- value_type?: ValueType;
1629
- rule_conditions?: (RuleCondition | undefined)[];
1630
- error_type?: DeviceErrorType;
1631
- location_transition_evaluator?: LocationTransitionEvaluator;
1632
- }
1633
- export interface RuleConditionWithRuleID {
1634
- RuleID?: string;
1635
- rule_condition_ids?: string[];
1636
- type: string;
1637
- LegacyType?: string;
1638
- property?: string;
1639
- value?: unknown;
1640
- value_type?: ValueType;
1641
- }
1642
- export interface inboundSecret {
1643
- company_id: string;
1644
- name: string;
1645
- expires_at?: string;
1646
- contents: string;
1647
- }
1648
- export interface Secret {
1649
- _id: string;
1650
- company_id: string;
1651
- name: string;
1652
- created_at: string;
1653
- created_by: string;
1654
- expires_at?: string;
1655
- }
1656
- export interface SecretModel {
1657
- secret_id: string;
1658
- model_id: string;
1659
- model: string;
1660
- }
1661
- export interface PopulatedSecret {
1662
- [index: string]: unknown;
1663
- }
1664
- export interface InvalidWarehouseError {
1665
- SecretID: string;
1666
- SecretWarehouseID: string;
1667
- WarehouseID: string;
1668
- }
1669
- export interface NilWarehouseError {
1670
- [index: string]: unknown;
1671
- }
1672
- export interface FileLocation {
1673
- name: string;
1674
- link: string;
1675
- }
1676
- export interface SoftwareUpdate {
1677
- name: string;
1678
- files: (FileLocation | undefined)[];
1679
- script: string;
1680
- reboot: boolean;
1681
- device_type_id: string;
1682
- }
1683
- export interface StatsDeviceCountByHeartbeatStatus {
1684
- as_expected: number;
1685
- inconsistent: number;
1686
- not_responsive: number;
1687
- never_reported: number;
1688
- other?: {
1689
- [key: string]: number;
1690
- };
1691
- }
1692
- export interface StatsDeviceCountByTypeObject {
1693
- name: string;
1694
- count: number;
1695
- }
1696
- export interface SystemCommand {
1697
- name: string;
1698
- description: string;
1699
- type: string;
1700
- method: string;
1701
- protocol: string;
1702
- host: string;
1703
- port?: number;
1704
- path_template: string;
1705
- body_template: string;
1706
- header_template: string;
1707
- verify_server_certificate: boolean;
1708
- response_mime_type: string;
1709
- output_variable_templates: {
1710
- [key: string]: string;
1711
- };
1712
- downstream_system_id: string;
1713
- }
1714
- export interface SystemCommandJob {
1715
- status: SystemCommandJobStatusType;
1716
- template_variables: {
1717
- [key: string]: unknown;
1718
- };
1719
- executed_at?: string;
1720
- request_url: string;
1721
- request_body: string;
1722
- request_headers: string;
1723
- response_status_code: number;
1724
- response_body: string;
1725
- response_headers: string;
1726
- output_variables: {
1727
- [key: string]: string;
1728
- };
1729
- downstream_system_id: string;
1730
- system_command_id: string;
1731
- }
1732
- export interface Translator {
1733
- name: string;
1734
- type: TranslatorType;
1735
- script?: string;
1736
- options?: {
1737
- [key: string]: unknown;
1738
- };
1739
- }
1740
- export interface UpstreamAction {
1741
- device_id: string;
1742
- name: string;
1743
- type: UpstreamActionType;
1744
- action: Uint32Array;
1745
- }
1746
- export interface User {
1747
- email: string;
1748
- password: string;
1749
- password_confirmation: string;
1750
- domain: string;
1751
- first_name: string;
1752
- last_name: string;
1753
- phone_number: string;
1754
- logo_url: string;
1755
- metadata?: {
1756
- [key: string]: unknown;
1757
- };
1758
- user_type_id: string;
1759
- company_ids: string[];
1760
- }
1761
- export interface UserForMarshal {
1762
- api_token?: string;
1763
- session_token?: string;
1764
- session_expires_at?: string;
1765
- }
1766
- export interface UserWithPasswordAndToken {
1767
- email: string;
1768
- encrypted_password: string;
1769
- encrypted_authentication_token: string;
1770
- first_name: string;
1771
- last_name: string;
1772
- phone_number: string;
1773
- logo_url: string;
1774
- }
1775
- export interface Authenticate {
1776
- email: string;
1777
- password: string;
1778
- domain: string;
1779
- token_expiry?: string;
1780
- }
1781
- export interface PasswordReset {
1782
- password: string;
1783
- password_confirmation: string;
1784
- }
1785
- export interface PasswordResetRequest {
1786
- email: string;
1787
- url: string;
1788
- from_address?: string;
1789
- subject?: string;
1790
- greeting?: string;
1791
- }
1792
- export interface UserType {
1793
- name: string;
1794
- description: string;
1795
- abilities: Abilities;
1796
- }
1797
- export interface WorkflowContext {
1798
- service_data: {
1799
- [key: string]: WorkflowContextServiceData;
1800
- };
1801
- user_data: {
1802
- [key: string]: string;
1803
- };
1804
- }
1805
- export interface WorkflowContextServiceData {
1806
- resource: string;
1807
- id: string;
1808
- }
1809
- export interface WorkflowContextRestData {
1810
- object: unknown;
1811
- }
1812
- export interface WorkflowDefinition {
1813
- id: string;
1814
- company_id: string;
1815
- name: string;
1816
- default_context?: WorkflowContext;
1817
- base_context?: WorkflowContext;
1818
- created_at: string;
1819
- updated_at: string;
1820
- }
1821
- export interface WorkflowAction {
1822
- id: string;
1823
- company_id: string;
1824
- name: string;
1825
- max_retries: number;
1826
- type: string;
1827
- properties: {
1828
- [key: string]: unknown;
1829
- };
1830
- created_at: string;
1831
- updated_at: string;
1832
- }
1833
- export interface WorkflowTree {
1834
- id: string;
1835
- definition_id: string;
1836
- parent_id?: string;
1837
- child_id: string;
1838
- created_at: string;
1839
- }
1840
- export interface WorkflowRecord {
1841
- id: string;
1842
- company_id: string;
1843
- definition_id: string;
1844
- created_at: string;
1845
- completed_at?: string;
1846
- }
1847
- export interface WorkflowJobResult {
1848
- id: string;
1849
- company_id: string;
1850
- parent_id?: string;
1851
- workflow_record_id: string;
1852
- action_id: string;
1853
- success: boolean;
1854
- returned_data: {
1855
- [key: string]: unknown;
1856
- };
1857
- context_data: {
1858
- [key: string]: unknown;
1859
- };
1860
- retries: number;
1861
- created_at: string;
1862
- }
1863
- export interface GeoJsonFeatureCollection {
1864
- type: string;
1865
- bbox?: number[];
1866
- features: (GeoJsonFeature | undefined)[];
1867
- crs?: {
1868
- [key: string]: unknown;
1869
- };
1870
- }
1871
- export interface GeoJsonFeature {
1872
- id?: unknown;
1873
- type: string;
1874
- bbox?: number[];
1875
- geometry?: GeoJsonGeometry;
1876
- properties: {
1877
- [key: string]: unknown;
1878
- };
1879
- crs?: {
1880
- [key: string]: unknown;
1881
- };
1882
- }
1883
- export interface GeoJsonGeometry {
1884
- type: GeometryType;
1885
- bbox?: number[];
1886
- Point: number[];
1887
- MultiPoint: number[][];
1888
- LineString: number[][];
1889
- MultiLineString: number[][][];
1890
- Polygon: number[][][];
1891
- MultiPolygon: number[][][][];
1892
- Geometries: (GeoJsonGeometry | undefined)[];
1893
- crs?: {
1894
- [key: string]: unknown;
1895
- };
1896
- }
1
+ export declare type AbilityType = string;
2
+ export declare type ActionType = string;
3
+ export declare type AppConfigType = string;
4
+ export declare type BodyType = string;
5
+ export declare type BulkRequestType = string;
6
+ export declare type BulkResponseStatusType = string;
7
+ export declare type DeviceClass = string;
8
+ export declare type DeviceEventType = string;
9
+ export declare type DeviceErrorType = string;
10
+ export declare type DeviceIntegrationActionType = string;
11
+ export declare type DType = string;
12
+ export declare type GatewayCommandType = string;
13
+ export declare type GeometryType = string;
14
+ export declare type HandlerType = string;
15
+ export declare type HealthProbeType = string;
16
+ export declare type HeartbeatStatusType = string;
17
+ export declare type IDType = string;
18
+ export declare type IngestorType = string;
19
+ export declare type IntegrationArchetype = string;
20
+ export declare type IntegrationType = string;
21
+ export declare type ListenerType = string;
22
+ export declare type LocationTransitionDirectionType = string;
23
+ export declare type ModelType = string;
24
+ export declare type OriginType = string;
25
+ export declare type ProvisionStatusType = string;
26
+ export declare type RestartPolicyTriggerType = string;
27
+ export declare type ReportType = string;
28
+ export declare type RuleConditionType = string;
29
+ export declare type SenderType = string;
30
+ export declare type SystemCommandJobStatusType = string;
31
+ export declare type TranslatorType = string;
32
+ export declare type UpstreamActionType = string;
33
+ export declare type ValueType = string;
34
+ export declare type BulkStatus = string;
35
+ export declare type DeviceHealthStatus = string;
36
+ export declare type DeviceLocationObservationVia = string;
37
+ export declare type DeviceTransferRequestStatus = string;
38
+ export declare type LogLevel = string;
39
+ export declare type RetryInterval = string;
40
+ export declare type Status = number;
41
+ export interface Lwm2mStateObject {
42
+ [index: string]: unknown;
43
+ }
44
+ export interface DeviceEvent {
45
+ id: string;
46
+ created_at: string;
47
+ device_class: DeviceClass;
48
+ company_id: string;
49
+ unique_id: string;
50
+ raw_client_id: string;
51
+ device_event_type: DeviceEventType;
52
+ metadata: {
53
+ [key: string]: unknown;
54
+ };
55
+ }
56
+ export interface Abilities {
57
+ audit: Ability;
58
+ application: Ability;
59
+ bulk_response: Ability;
60
+ bulk_response_status: Ability;
61
+ command: Ability;
62
+ company: Ability;
63
+ deployment: Ability;
64
+ device: AbilityAndAction;
65
+ device_type: Ability;
66
+ device_config: AbilityAndAction;
67
+ device_error: Ability;
68
+ device_ha_group: Ability;
69
+ device_health_status_event: Ability;
70
+ device_transfer_request: Ability;
71
+ device_template: Ability;
72
+ device_location_observation: Ability;
73
+ escrow_device: Ability;
74
+ downstream_system: Ability;
75
+ gateway_command: Ability;
76
+ ingestor: Ability;
77
+ integration: Ability;
78
+ integration_event: Ability;
79
+ notification: Ability;
80
+ pollable_attribute: Ability;
81
+ region: Ability;
82
+ report: AbilityAndPayload;
83
+ rule: Ability;
84
+ secret: Ability;
85
+ lwm2m_object_links: Ability;
86
+ lwm2m_state: Ability;
87
+ software_update: Ability;
88
+ system_command: Ability;
89
+ system_command_job: Ability;
90
+ translator: Ability;
91
+ user: AbilityForUser;
92
+ user_type: Ability;
93
+ workflow_definition: AbilityAndExecute;
94
+ workflow_record: Ability;
95
+ workflow_job_result: Ability;
96
+ workflow_tree: Ability;
97
+ workflow_action: Ability;
98
+ }
99
+ export interface ViewAbilities {
100
+ dashboard: boolean;
101
+ gateways: boolean;
102
+ devices: boolean;
103
+ reports: boolean;
104
+ errors: boolean;
105
+ customers: boolean;
106
+ roles: boolean;
107
+ companies: boolean;
108
+ integrations: boolean;
109
+ notifications: boolean;
110
+ firmware: boolean;
111
+ }
112
+ export interface Ability {
113
+ create: AbilityType;
114
+ update: AbilityType;
115
+ read: AbilityType;
116
+ delete: AbilityType;
117
+ }
118
+ export interface Action {
119
+ notification: AbilityType;
120
+ enable_data_restriction: AbilityType;
121
+ disable_data_restriction: AbilityType;
122
+ send_config: AbilityType;
123
+ deploy_deployment: AbilityType;
124
+ request_deployment_status: AbilityType;
125
+ data_restore: AbilityType;
126
+ update_edge: AbilityType;
127
+ update_firmware: AbilityType;
128
+ restore_backup: AbilityType;
129
+ backup: AbilityType;
130
+ log_upload: AbilityType;
131
+ reboot: AbilityType;
132
+ reset: AbilityType;
133
+ data_reset: AbilityType;
134
+ heartbeat: AbilityType;
135
+ software_update: AbilityType;
136
+ status: AbilityType;
137
+ provision_marmon_button: AbilityType;
138
+ greengrass_initialize: AbilityType;
139
+ greengrass_restart: AbilityType;
140
+ greengrass_redeploy: AbilityType;
141
+ amag_add_modify_card_holder: AbilityType;
142
+ amag_delete_card_holder: AbilityType;
143
+ activate_cloud_native_device: AbilityType;
144
+ deactivate_cloud_native_device: AbilityType;
145
+ lwm2m_request: AbilityType;
146
+ }
147
+ export interface AbilityAndAction {
148
+ [index: string]: unknown;
149
+ }
150
+ export interface AbilityForUser {
151
+ act_as: AbilityType;
152
+ update_user_type: AbilityType;
153
+ }
154
+ export interface AbilityAndPayload {
155
+ read_payload: AbilityType;
156
+ }
157
+ export interface AbilityAndExecute {
158
+ execute: AbilityType;
159
+ }
160
+ export interface CRUDActions {
161
+ create: boolean;
162
+ read: boolean;
163
+ update: boolean;
164
+ delete: boolean;
165
+ }
166
+ export interface Actions {
167
+ sms_at_command_status_request: boolean;
168
+ notification: boolean;
169
+ enable_data_restriction: boolean;
170
+ disable_data_restriction: boolean;
171
+ send_config: boolean;
172
+ deploy_deployment: boolean;
173
+ request_deployment_status: boolean;
174
+ data_restore: boolean;
175
+ update_edge: boolean;
176
+ update_firmware: boolean;
177
+ restore_backup: boolean;
178
+ backup: boolean;
179
+ log_level: boolean;
180
+ log_config: boolean;
181
+ log_upload: boolean;
182
+ reboot: boolean;
183
+ reset: boolean;
184
+ data_reset: boolean;
185
+ heartbeat: boolean;
186
+ status: boolean;
187
+ software_update: boolean;
188
+ provision_marmon_button: boolean;
189
+ greengrass_initialize: boolean;
190
+ greengrass_restart: boolean;
191
+ greengrass_redeploy: boolean;
192
+ amag_add_modify_card_holder: boolean;
193
+ amag_delete_card_holder: boolean;
194
+ activate_cloud_native_device: boolean;
195
+ deactivate_cloud_native_device: boolean;
196
+ lwm2m_request: boolean;
197
+ log: boolean;
198
+ sms: boolean;
199
+ email: boolean;
200
+ relay: boolean;
201
+ http_request: boolean;
202
+ mqtt: boolean;
203
+ aws_iot: boolean;
204
+ bluemix_iot: boolean;
205
+ azure_iot: boolean;
206
+ tcp: boolean;
207
+ prtg: boolean;
208
+ tcp_modbus: boolean;
209
+ opcua: boolean;
210
+ bacnet: boolean;
211
+ }
212
+ export interface ActionParam {
213
+ field: string;
214
+ description: string;
215
+ type?: string;
216
+ allowed_values?: string[];
217
+ }
218
+ export interface ActionTypeDescription {
219
+ type: ActionType;
220
+ description: string;
221
+ params: ActionParam[];
222
+ device_integration: boolean;
223
+ edge: boolean;
224
+ cloud: boolean;
225
+ }
226
+ export interface AmagCardHolder {
227
+ first_name?: string;
228
+ last_name?: string;
229
+ card_number?: number;
230
+ pin?: string;
231
+ employee_reference?: string;
232
+ company_id?: number;
233
+ customer_code?: number;
234
+ access_code_id?: number;
235
+ active_date?: string;
236
+ expiry_date?: string;
237
+ personal_data: string[];
238
+ }
239
+ export interface Application {
240
+ name: string;
241
+ description: string;
242
+ app_config?: AppConfig;
243
+ }
244
+ export interface Port {
245
+ port_number: number;
246
+ protocol: string;
247
+ }
248
+ export interface AppConfig {
249
+ type: AppConfigType;
250
+ env: EnvVar[];
251
+ readiness_probe?: HealthProbe;
252
+ liveness_probe?: HealthProbe;
253
+ image?: string;
254
+ ports?: Port[];
255
+ command?: string[];
256
+ args?: string[];
257
+ restart_policy?: RestartPolicy;
258
+ }
259
+ export interface RestartPolicy {
260
+ trigger_type: RestartPolicyTriggerType;
261
+ backoff_multiplier?: number;
262
+ backoff_initial_seconds?: number;
263
+ backoff_maximum_seconds?: number;
264
+ }
265
+ export interface EnvVar {
266
+ name: string;
267
+ value: string;
268
+ }
269
+ export interface HealthProbe {
270
+ type: HealthProbeType;
271
+ period_seconds: number;
272
+ delay_seconds: number;
273
+ http_health_probe?: HTTPHealthProbe;
274
+ command_health_probe?: CommandHealthProbe;
275
+ }
276
+ export interface HTTPHealthProbe {
277
+ path: string;
278
+ timeout_seconds: number;
279
+ }
280
+ export interface CommandHealthProbe {
281
+ command: string[];
282
+ timeout_seconds: number;
283
+ }
284
+ export interface Audit {
285
+ request_method: string;
286
+ request_path: string;
287
+ resource_type: string;
288
+ resource: string;
289
+ requestor_user_id: string;
290
+ requestor_user_type_id: string;
291
+ act_as_user_id: string;
292
+ act_as_user_type_id: string;
293
+ response_code: number;
294
+ error_message: string;
295
+ errors: string[];
296
+ }
297
+ export interface Base {
298
+ _id?: IDType;
299
+ origin: OriginType;
300
+ created_at: string;
301
+ updated_at: string;
302
+ company_id: string;
303
+ user_id: IDType;
304
+ }
305
+ export interface BaseStringSQL {
306
+ _id?: string;
307
+ origin: OriginType;
308
+ created_at: string;
309
+ updated_at: string;
310
+ company_id: string;
311
+ user_id: string;
312
+ }
313
+ export interface BrokerResponse {
314
+ result: string;
315
+ }
316
+ export interface RawBrokerEvent {
317
+ id: string;
318
+ event_type: string;
319
+ client_id: string;
320
+ topic: string;
321
+ datetime: string;
322
+ retain?: boolean;
323
+ }
324
+ export interface BrokerEvent {
325
+ id: string;
326
+ event_type: string;
327
+ client_id: string;
328
+ company_id: string;
329
+ device_id: string;
330
+ topic: string;
331
+ topic_type: string;
332
+ is_downstream: boolean;
333
+ is_upstream: boolean;
334
+ is_gateway_command: boolean;
335
+ is_device_authority: boolean;
336
+ is_report: boolean;
337
+ is_heartbeat: boolean;
338
+ retained: boolean;
339
+ datetime: string;
340
+ }
341
+ export interface BulkRequest {
342
+ type: BulkRequestType;
343
+ unique_ids: string[];
344
+ name_prefix: string;
345
+ name_template: string;
346
+ device?: Device;
347
+ device_type?: DeviceType;
348
+ escrow_device?: EscrowDevice;
349
+ body: string;
350
+ ids: string[];
351
+ model_type: ModelType;
352
+ cascade?: boolean;
353
+ csv_rows: string[][];
354
+ gateway_command_request?: GatewayCommandRequest;
355
+ email_callback: boolean;
356
+ email_override: string;
357
+ user?: User;
358
+ user_type?: UserType;
359
+ bulk_response_id: string;
360
+ context?: WorkflowContext;
361
+ definition_id: string;
362
+ generate_child_command_executions?: boolean;
363
+ }
364
+ export interface BulkSingleResponse {
365
+ status?: number;
366
+ id?: string;
367
+ error?: string;
368
+ messages?: string[];
369
+ }
370
+ export interface BulkResponseUpdate {
371
+ status: BulkStatus;
372
+ success?: {
373
+ [key: string]: BulkSingleResponse;
374
+ };
375
+ fail?: {
376
+ [key: string]: BulkSingleResponse;
377
+ };
378
+ }
379
+ export interface BulkResponse {
380
+ type: string;
381
+ total: number;
382
+ bulk_response_statuses: (BulkResponseStatus | undefined)[];
383
+ generate_child_command_executions?: boolean;
384
+ }
385
+ export interface BulkResponseStatus {
386
+ status_code?: number;
387
+ status?: BulkResponseStatusType;
388
+ error?: string;
389
+ messages?: string[];
390
+ csv_errors?: CSVError[];
391
+ bulk_response_id: string;
392
+ device_id: string;
393
+ workflow_record_id?: string;
394
+ }
395
+ export interface BulkResponseID {
396
+ bulk_response_id: string;
397
+ }
398
+ export interface BulkCSVRow {
399
+ row: string[];
400
+ user?: User;
401
+ }
402
+ export interface Command {
403
+ name?: string;
404
+ sender_type?: SenderType;
405
+ sender?: {
406
+ [key: string]: unknown;
407
+ };
408
+ long_description?: string;
409
+ options?: {
410
+ [key: string]: unknown;
411
+ };
412
+ payload?: {
413
+ [key: string]: unknown;
414
+ };
415
+ translator_id: string;
416
+ generate_child_command_executions: boolean;
417
+ }
418
+ export interface CommandWithDeviceID {
419
+ device_id: string;
420
+ }
421
+ export interface Branding {
422
+ logo_url: string;
423
+ icon_url: string;
424
+ primary_color: string;
425
+ logo_background_color: string;
426
+ portal_title: string;
427
+ }
428
+ export interface Aliases {
429
+ gateway: string;
430
+ device: string;
431
+ }
432
+ export interface Company {
433
+ name: string;
434
+ website?: string;
435
+ branding?: Branding;
436
+ aliases?: Aliases;
437
+ view_abilities: ViewAbilities;
438
+ portal_configuration: PortalConfiguration;
439
+ metadata?: {
440
+ [key: string]: unknown;
441
+ };
442
+ inherited_device_type_ids: string[];
443
+ inherited_integration_ids: string[];
444
+ inherited_ingestor_ids: string[];
445
+ inherited_translator_ids: string[];
446
+ inherited_rule_ids: string[];
447
+ inherited_pollable_attributes_ids: string[];
448
+ inherited_workflow_definition_ids: string[];
449
+ device_tags: string[];
450
+ }
451
+ export interface Config {
452
+ id: string;
453
+ name: string;
454
+ unique_id: string;
455
+ device_type?: DeviceTypeWithRelations;
456
+ heartbeat_period: number;
457
+ sms_password: string;
458
+ auto_relay_reports: boolean;
459
+ bluemix_auth_token: string;
460
+ aws_greengrass_core_thing_arn: string;
461
+ aws_keys_and_certificate?: AWSKeysAndCertificate;
462
+ device_ha_group?: DeviceHAGroupWithKeyPair;
463
+ heartbeat_values: string[];
464
+ connections: Connection[];
465
+ iptables?: (IPTableAction | undefined)[];
466
+ devices: (DeviceWithRules | undefined)[];
467
+ device_types: (DeviceTypeWithRelations | undefined)[];
468
+ ingestors: (Ingestor | undefined)[];
469
+ commanders: (Command | undefined)[];
470
+ translators: (Translator | undefined)[];
471
+ integrations: (Integration | undefined)[];
472
+ integration_ids: string[];
473
+ user?: UserWithPasswordAndToken;
474
+ rules: (Rule | undefined)[];
475
+ log_config?: LogConfig;
476
+ metadata: {
477
+ [key: string]: string;
478
+ };
479
+ }
480
+ export interface ConfigV2 {
481
+ filename: string;
482
+ md5: string;
483
+ }
484
+ export interface DeviceCountsByStatus {
485
+ online_device_count: number;
486
+ offline_device_count: number;
487
+ idle_device_count: number;
488
+ never_reported_device_count: number;
489
+ low_signal_device_count: number;
490
+ }
491
+ export interface DeviceCountsBySignal {
492
+ excellent: number;
493
+ good: number;
494
+ moderate: number;
495
+ poor: number;
496
+ disconnected: number;
497
+ }
498
+ export interface DashboardStats {
499
+ statuses: DeviceCountsByStatus;
500
+ by_signal: DeviceCountsBySignal;
501
+ no_group: number;
502
+ no_attached_devices: number;
503
+ cell_usage_total: number;
504
+ }
505
+ export interface StatusesByLocation {
506
+ all_locations: string[];
507
+ status_by_location: {
508
+ [key: string]: DeviceCountsByStatus;
509
+ };
510
+ }
511
+ export interface Deployment {
512
+ name: string;
513
+ description: string;
514
+ application_statuses?: {
515
+ [key: string]: string;
516
+ };
517
+ application_ids: string[];
518
+ applications: (Application | undefined)[];
519
+ }
520
+ export interface DeploymentApplication {
521
+ DeploymentId: string;
522
+ ApplicationId: string;
523
+ }
524
+ export interface dlGeographicPoint {
525
+ X: number;
526
+ Y: number;
527
+ }
528
+ export interface DeviceLocationObservation {
529
+ device_id: string;
530
+ device_unique_id: string;
531
+ via: DeviceLocationObservationVia;
532
+ generated_at: string;
533
+ horizontal_accuracy_meters: number;
534
+ latitude: string;
535
+ longitude: string;
536
+ }
537
+ export interface DeviceLocationObservationWithGeoJSON {
538
+ geojson?: GeoJsonFeature;
539
+ }
540
+ export interface DeviceUniqueID {
541
+ CompanyID: string;
542
+ UniqueID: string;
543
+ }
544
+ export interface DeviceState {
545
+ device_online?: string;
546
+ device_offline?: string;
547
+ }
548
+ export interface Device {
549
+ name: string;
550
+ unique_id: string;
551
+ report_count: number;
552
+ auto_relay_reports: boolean;
553
+ active: boolean;
554
+ lwm2m_bootstrap_psk_secret_id?: string;
555
+ lwm2m_bootstrap_psk?: string;
556
+ bluemix_auth_token?: string;
557
+ aws_keys_and_certificate?: AWSKeysAndCertificate;
558
+ aws_keys_and_certificate_secret_id?: string;
559
+ aws_greengrass_core_thing_arn?: string;
560
+ aws_greengrass_group_id?: string;
561
+ edge_version: string;
562
+ firmware_version: string;
563
+ serial: string;
564
+ activated_at?: string;
565
+ deactivated_at?: string;
566
+ status_at: string;
567
+ status_messages?: StatusMessage[];
568
+ command_status?: CommandStatus[];
569
+ config_status?: ConfigStatus;
570
+ platform_tag?: string;
571
+ build_tags?: string[];
572
+ connections_status?: {
573
+ [key: string]: {
574
+ [key: string]: string;
575
+ };
576
+ };
577
+ provision_status?: ProvisionStatusType;
578
+ health_status: DeviceHealthStatus;
579
+ heartbeat_at: string;
580
+ heartbeat_values: string[];
581
+ heartbeat_period: number;
582
+ heartbeat_status: HeartbeatStatusType;
583
+ last_heartbeat_status: HeartbeatStatusType;
584
+ log_config?: LogConfig;
585
+ max_persisted_reports?: number;
586
+ location: string;
587
+ sms_password?: string;
588
+ last_sms_status?: string;
589
+ last_sms_sent_at?: string;
590
+ cell_number?: string;
591
+ cell_signal: number;
592
+ cell_usage?: CellUsageInfo;
593
+ cell_status?: string;
594
+ parent_device_id?: string;
595
+ device_type_id?: string;
596
+ device_config_id: string;
597
+ last_report_id?: string;
598
+ last_notification_id?: string;
599
+ last_location_observation_id?: string;
600
+ device_integration_id?: string;
601
+ cloud_native_integration_id?: string;
602
+ sms_integration_id?: string;
603
+ ingestor_ids: string[];
604
+ command_ids: string[];
605
+ attached_device_ids: string[];
606
+ device_ha_group_id: string;
607
+ deployment_id: string;
608
+ tags: string[];
609
+ metadata: {
610
+ [key: string]: string;
611
+ };
612
+ }
613
+ export interface DeviceWithLastKnownLocation {
614
+ last_known_geographic_location?: GeoJsonFeature;
615
+ }
616
+ export interface DeviceRule {
617
+ DeviceId: string;
618
+ RuleId: string;
619
+ }
620
+ export interface DeviceIngestor {
621
+ DeviceId: string;
622
+ IngestorId: string;
623
+ }
624
+ export interface DeviceCommand {
625
+ DeviceId: string;
626
+ CommandId: string;
627
+ }
628
+ export interface DeviceWithRules {
629
+ rules: (Rule | undefined)[];
630
+ }
631
+ export interface LogConfig {
632
+ local_level: LogLevel;
633
+ forward_level: LogLevel;
634
+ forward_frequency_limit: number;
635
+ }
636
+ export interface ConfigStatus {
637
+ received: boolean;
638
+ valid: boolean;
639
+ configured: boolean;
640
+ greengrass_installed: boolean;
641
+ }
642
+ export interface StatusMessage {
643
+ message: string;
644
+ status_type: string;
645
+ timestamp: string;
646
+ }
647
+ export interface CommandStatus {
648
+ command: string;
649
+ message_id: string;
650
+ timestamp: string;
651
+ }
652
+ export interface CellUsageInfo {
653
+ last: number;
654
+ total: number;
655
+ year: number;
656
+ month: number;
657
+ week: number;
658
+ day: number;
659
+ }
660
+ export interface AWSKeysAndCertificate {
661
+ certificate_arn?: string;
662
+ certificate_id?: string;
663
+ certificate_pem?: string;
664
+ key_pair?: AWSKeyPair;
665
+ }
666
+ export interface AWSKeyPair {
667
+ private_key: string;
668
+ public_key: string;
669
+ }
670
+ export interface DeviceConfig {
671
+ name: string;
672
+ connections: Connection[];
673
+ iptables: (IPTableAction | undefined)[];
674
+ device_type_id: string;
675
+ last_notification_id?: string;
676
+ }
677
+ export interface IPTableAction {
678
+ action?: string;
679
+ chain?: string;
680
+ table?: string;
681
+ protocol?: string;
682
+ in_interface?: string;
683
+ out_interface?: string;
684
+ source_port?: string;
685
+ destination_port?: string;
686
+ source?: string;
687
+ destination?: string;
688
+ jump?: string;
689
+ }
690
+ export interface Connection {
691
+ type: string;
692
+ name: string;
693
+ config: {
694
+ [key: string]: unknown;
695
+ };
696
+ }
697
+ export interface ConnectionConfig {
698
+ [index: string]: unknown;
699
+ }
700
+ export interface NetworkConfig {
701
+ net_enable?: number;
702
+ net_ip_assign?: string;
703
+ net_mode?: string;
704
+ net_type?: string;
705
+ net_ip?: string;
706
+ net_mask?: string;
707
+ net_gateway?: string;
708
+ net_broadcast?: string;
709
+ net_nat?: number;
710
+ net_mtu?: number;
711
+ net_metric?: number;
712
+ net_dns_1?: string;
713
+ net_dns_2?: string;
714
+ }
715
+ export interface DHCPConfig {
716
+ dhcp_relay?: number;
717
+ dhcp_enable?: number;
718
+ dhcp_start?: string;
719
+ dhcp_end?: string;
720
+ dhcp_lease?: number;
721
+ dhcp_dns1?: string;
722
+ dhcp_dns2?: string;
723
+ }
724
+ export interface WifiConfig {
725
+ wifi_enable?: number;
726
+ wifi_mode?: string;
727
+ wifi_ssid?: string;
728
+ wifi_auth?: string;
729
+ wifi_crypt?: string;
730
+ wifi_psk?: string;
731
+ wifi_channel?: number;
732
+ wifi_hidden?: number;
733
+ }
734
+ export interface CellularConfig {
735
+ cell_enable?: number;
736
+ cell_auto_apn?: number;
737
+ cell_apn?: string;
738
+ cell_user?: string;
739
+ cell_pass?: string;
740
+ cell_auth?: string;
741
+ cell_reconn_delay?: number;
742
+ cell_reconn_retries?: number;
743
+ cell_metric?: number;
744
+ cell_mtu?: number;
745
+ }
746
+ export interface FirewallRule {
747
+ rule_enable?: number;
748
+ rule_name?: string;
749
+ rule_options: {
750
+ [key: string]: unknown;
751
+ };
752
+ }
753
+ export interface FirewallConfig {
754
+ firewall_enable?: number;
755
+ firewall_rules?: FirewallRule[];
756
+ }
757
+ export interface DeviceError {
758
+ type: DeviceErrorType;
759
+ level: number;
760
+ error: string;
761
+ device_id: string;
762
+ rule_action_count: number;
763
+ }
764
+ export interface DeviceHAGroup {
765
+ name: string;
766
+ ports: number[];
767
+ controller_device: HADevice;
768
+ node_devices: HADevice[];
769
+ }
770
+ export interface KeyPair {
771
+ public_key: string;
772
+ private_key: string;
773
+ }
774
+ export interface HADevice {
775
+ device_id: string;
776
+ device_unique_id?: string;
777
+ interface: string;
778
+ ip?: string;
779
+ aws_keys_and_certificate?: AWSKeysAndCertificate;
780
+ }
781
+ export interface DeviceHAGroupWithKeyPair {
782
+ key_pair?: KeyPair;
783
+ }
784
+ export interface DeviceHealthStatusEvent {
785
+ device_id: string;
786
+ rule_id?: string;
787
+ status: DeviceHealthStatus;
788
+ reason: string;
789
+ }
790
+ export interface DeviceTemplate {
791
+ name: string;
792
+ description: string;
793
+ name_template: string;
794
+ device_company_id: string;
795
+ heartbeat_values: string[];
796
+ heartbeat_period: number;
797
+ log_config?: LogConfig;
798
+ location: string;
799
+ device_type_id: string;
800
+ device_config_id: string;
801
+ device_integration_id?: string;
802
+ cloud_native_integration_id?: string;
803
+ deployment_id: string;
804
+ tags: string[];
805
+ metadata: {
806
+ [key: string]: string;
807
+ };
808
+ }
809
+ export interface DeviceTransferRequest {
810
+ transferred_at?: string;
811
+ from_company_id: string;
812
+ to_company_id: string;
813
+ status: DeviceTransferRequestStatus;
814
+ errors?: {
815
+ [key: string]: string;
816
+ };
817
+ device_type_id: string;
818
+ device_template_id: string;
819
+ escrow_device_ids: string[];
820
+ }
821
+ export interface DeviceType {
822
+ name: string;
823
+ image: string;
824
+ model: string;
825
+ manufacturer: string;
826
+ long_description: string;
827
+ type?: DType;
828
+ capabilities?: Capabilities;
829
+ heartbeat_values?: string[];
830
+ origin_id: string;
831
+ ingestor_ids: string[];
832
+ command_ids: string[];
833
+ software_update_ids: string[];
834
+ metadata: {
835
+ [key: string]: string;
836
+ };
837
+ }
838
+ export interface DeviceTypeRule {
839
+ DeviceTypeId: string;
840
+ RuleId: string;
841
+ }
842
+ export interface DeviceTypeIngestor {
843
+ DeviceTypeId: string;
844
+ IngestorId: string;
845
+ }
846
+ export interface DeviceTypeCommand {
847
+ DeviceTypeId: string;
848
+ CommandId: string;
849
+ }
850
+ export interface DeviceTypePollableAttributes {
851
+ DeviceTypeId: string;
852
+ PollableAttributesID: string;
853
+ }
854
+ export interface DeviceTypeWithRelations {
855
+ rules: (Rule | undefined)[];
856
+ pollable_attributes: (PollableAttributes | undefined)[];
857
+ }
858
+ export interface Capabilities {
859
+ network_connections: NetworkConnection[];
860
+ peripherals: Peripheral[];
861
+ iptables: boolean;
862
+ firmware: Firmware;
863
+ actions?: Actions;
864
+ sms_at_commands?: SMSATCommands;
865
+ }
866
+ export interface SMSATCommands {
867
+ status_commands: string[];
868
+ send_config_commands: string[];
869
+ }
870
+ export interface NetworkConnection {
871
+ type: string;
872
+ interface?: string;
873
+ name: string;
874
+ }
875
+ export interface Peripheral {
876
+ type: string;
877
+ device: string;
878
+ }
879
+ export interface Firmware {
880
+ upgrade: boolean;
881
+ backup: boolean;
882
+ }
883
+ export interface DownstreamSystem {
884
+ name: string;
885
+ description: string;
886
+ system_commands: (SystemCommand | undefined)[];
887
+ }
888
+ export interface EdgeBuilderRequest {
889
+ company_id: string;
890
+ manufacturer: string;
891
+ model: string;
892
+ environment: string;
893
+ version: string;
894
+ features: string[];
895
+ }
896
+ export interface EdgeBuilderResponse {
897
+ installer_url: string;
898
+ install_script: string;
899
+ }
900
+ export interface InsufficientPermissionsError {
901
+ [index: string]: unknown;
902
+ }
903
+ export interface NotFoundError {
904
+ [index: string]: unknown;
905
+ }
906
+ export interface EscrowDeviceEnquiry {
907
+ _id?: string;
908
+ created_at: string;
909
+ updated_at: string;
910
+ name: string;
911
+ company_name: string;
912
+ phone_number: string;
913
+ email_address: string;
914
+ escrow_token: string;
915
+ }
916
+ export interface EscrowDevice {
917
+ transfer_initiated_at?: string;
918
+ transfer_completed_at?: string;
919
+ unique_id: string;
920
+ token: string;
921
+ lwm2m: boolean;
922
+ lwm2m_bootstrap_psk_secret_id?: string;
923
+ lwm2m_bootstrap_psk?: string;
924
+ }
925
+ export interface URLGatewayCommandPayload {
926
+ url: string;
927
+ }
928
+ export interface VersionGatewayCommandPayload {
929
+ version: string;
930
+ }
931
+ export interface EnableGatewayCommandPayload {
932
+ enable: boolean;
933
+ }
934
+ export interface WhenGatewayCommandPayload {
935
+ when: string;
936
+ }
937
+ export interface GatewayCommand {
938
+ command_type: GatewayCommandType;
939
+ payload: {
940
+ [key: string]: unknown;
941
+ };
942
+ schedule?: CommandSchedule;
943
+ timeout?: number;
944
+ statuses: {
945
+ [key: string]: GatewayCommandStatus;
946
+ };
947
+ device_config_id: string;
948
+ device_id: string;
949
+ device_unique_id: string;
950
+ device_type_id: string;
951
+ software_update_id?: string;
952
+ attached_device_ids: string[];
953
+ attached_device_unique_ids: string[];
954
+ }
955
+ export interface GatewayCommandStatus {
956
+ status: string;
957
+ status_message?: string;
958
+ }
959
+ export interface CommandSchedule {
960
+ start_datetime: string;
961
+ end_datetime: string;
962
+ retry_interval?: RetryInterval;
963
+ }
964
+ export interface Lwm2mRequest {
965
+ type: string;
966
+ endpoint: string;
967
+ data: unknown;
968
+ }
969
+ export interface GatewayCommandRequest {
970
+ command_type: GatewayCommandType;
971
+ schedule?: CommandSchedule;
972
+ timeout: number;
973
+ url?: string;
974
+ version?: string;
975
+ software_update_id?: string;
976
+ when?: string;
977
+ level?: string;
978
+ enable?: boolean;
979
+ card_holder?: AmagCardHolder;
980
+ attached_device_ids?: string[];
981
+ _: string[];
982
+ }
983
+ export interface GreengrassFunction {
984
+ name?: string;
985
+ id: string;
986
+ arn: string;
987
+ latest_version?: string;
988
+ latest_version_arn?: string;
989
+ functions?: GreengrassLambdaFunction[];
990
+ }
991
+ export interface GreengrassLambdaFunction {
992
+ id: string;
993
+ arn: string;
994
+ pinned: boolean;
995
+ executable: string;
996
+ environment: {
997
+ [key: string]: string | undefined;
998
+ };
999
+ exec_args: string;
1000
+ memory_size: number;
1001
+ timeout: number;
1002
+ }
1003
+ export interface GreengrassSubscription {
1004
+ name?: string;
1005
+ id: string;
1006
+ arn: string;
1007
+ latest_version?: string;
1008
+ latest_version_arn?: string;
1009
+ subscriptions?: GreengrassSubscriptionDefinition[];
1010
+ }
1011
+ export interface GreengrassSubscriptionDefinition {
1012
+ id: string;
1013
+ source: string;
1014
+ subject: string;
1015
+ target: string;
1016
+ }
1017
+ export interface GreengrassConnectivityInfo {
1018
+ message: string;
1019
+ hosts: GreengrassConnectivityInfoDefinition[];
1020
+ }
1021
+ export interface GreengrassConnectivityInfoDefinition {
1022
+ host_address: string;
1023
+ port_number: number;
1024
+ }
1025
+ export interface HookResult {
1026
+ result: unknown;
1027
+ modifiers?: HookModifiers;
1028
+ topics?: HookTopic[];
1029
+ }
1030
+ export interface HookModifiers {
1031
+ max_message_size?: number;
1032
+ max_inflight_messages?: number;
1033
+ retry_interval?: number;
1034
+ topic?: string;
1035
+ qos?: number;
1036
+ payload?: string;
1037
+ retain?: boolean;
1038
+ }
1039
+ export interface HookTopic {
1040
+ topic: string;
1041
+ qos?: number;
1042
+ }
1043
+ export interface HookError {
1044
+ error: string;
1045
+ }
1046
+ export interface AuthOnRegisterEvent {
1047
+ peer_addr: string;
1048
+ peer_port: number;
1049
+ username: string;
1050
+ password: string;
1051
+ mountpoint: string;
1052
+ client_id: string;
1053
+ clean_session: boolean;
1054
+ }
1055
+ export interface AuthOnPublishEvent {
1056
+ username: string;
1057
+ client_id: string;
1058
+ mountpoint: string;
1059
+ qos: number;
1060
+ topic: string;
1061
+ payload: string;
1062
+ retain: boolean;
1063
+ }
1064
+ export interface AuthOnSubscribeEvent {
1065
+ username: string;
1066
+ client_id: string;
1067
+ mountpoint: string;
1068
+ topics: HookTopic[];
1069
+ }
1070
+ export interface Ingestor {
1071
+ name: string;
1072
+ type: IngestorType;
1073
+ target_map?: {
1074
+ [key: string]: string;
1075
+ };
1076
+ target_template?: string;
1077
+ listener_type?: ListenerType;
1078
+ listener?: {
1079
+ [key: string]: unknown;
1080
+ };
1081
+ handler_type?: HandlerType;
1082
+ handler?: {
1083
+ [key: string]: unknown;
1084
+ };
1085
+ translator?: {
1086
+ [key: string]: unknown;
1087
+ };
1088
+ translator_id: string;
1089
+ }
1090
+ export interface IngestorShadow {
1091
+ created_at: string;
1092
+ updated_at: string;
1093
+ ingestor_id: string;
1094
+ company_id: string;
1095
+ listener_type: ListenerType;
1096
+ listener: {
1097
+ [key: string]: unknown;
1098
+ };
1099
+ translator_id: string;
1100
+ high_water_mark: {
1101
+ [key: string]: unknown;
1102
+ };
1103
+ run_count: number;
1104
+ last_completed_at: string;
1105
+ min_timeout: number;
1106
+ }
1107
+ export interface EdgeInstanceRequest {
1108
+ company_id: string;
1109
+ unique_id: string;
1110
+ }
1111
+ export interface EdgeInstanceResponse {
1112
+ [index: string]: unknown;
1113
+ }
1114
+ export interface EdgeInstanceListRequest {
1115
+ company_id: string;
1116
+ }
1117
+ export interface EdgeInstanceListResponse {
1118
+ edge_instances: EdgeInstance[];
1119
+ }
1120
+ export interface EdgeInstance {
1121
+ name: string;
1122
+ labels: {
1123
+ [key: string]: string;
1124
+ };
1125
+ }
1126
+ export interface Integration {
1127
+ name: string;
1128
+ archetype: IntegrationArchetype;
1129
+ type: IntegrationType;
1130
+ init_status?: string;
1131
+ long_description: string;
1132
+ inmarsat_client_id?: string;
1133
+ inmarsat_secret?: string;
1134
+ inmarsat_username?: string;
1135
+ inmarsat_password?: string;
1136
+ inmarsat_customer_id?: string;
1137
+ inmarsat_scap_id?: string;
1138
+ inmarsat_industry_code?: string;
1139
+ inmarsat_mailbox_id?: string;
1140
+ orbcomm_username?: string;
1141
+ orbcomm_password?: string;
1142
+ orbcomm_solution_provider_id?: string;
1143
+ orbcomm_gateway_account_id?: string;
1144
+ gs_username?: string;
1145
+ gs_password?: string;
1146
+ gs_customer_id?: string;
1147
+ gs_rate_plan_id?: string;
1148
+ gs_address_id?: string;
1149
+ region?: string;
1150
+ external_id?: string;
1151
+ role_arn?: string;
1152
+ device_gateway_url?: string;
1153
+ greengrass_core_install_url?: string;
1154
+ iot_hub_hostname?: string;
1155
+ shared_access_key?: string;
1156
+ access_policy_name?: string;
1157
+ sas_token?: string;
1158
+ org_id?: string;
1159
+ api_key?: string;
1160
+ auth_token?: string;
1161
+ sid?: string;
1162
+ token?: string;
1163
+ from?: string;
1164
+ callback_to_machineshop?: boolean;
1165
+ server?: string;
1166
+ username?: string;
1167
+ password?: string;
1168
+ identification_token?: string;
1169
+ }
1170
+ export interface IntegrationTypeDescription {
1171
+ type: IntegrationType;
1172
+ readable_type: string;
1173
+ device_integration_type: boolean;
1174
+ cloud_integration_type: boolean;
1175
+ associated_action_type?: ActionType;
1176
+ fields: string[];
1177
+ }
1178
+ export interface LambdaFunction {
1179
+ arn: string;
1180
+ name: string;
1181
+ description: string;
1182
+ }
1183
+ export interface LambdaFunctionVersion {
1184
+ arn: string;
1185
+ name: string;
1186
+ description: string;
1187
+ version: string;
1188
+ revision_id: string;
1189
+ role: string;
1190
+ environment: {
1191
+ [key: string]: string | undefined;
1192
+ };
1193
+ timeout: number;
1194
+ memory_size: number;
1195
+ }
1196
+ export interface LocationTransitionEvaluator {
1197
+ region_id: string;
1198
+ direction: LocationTransitionDirectionType;
1199
+ num_observations_to_consider: number;
1200
+ required_num_breaching_observations: number;
1201
+ confidence_threshold: number;
1202
+ allow_breach_on_initial_observation: boolean;
1203
+ }
1204
+ export interface LocationRelation {
1205
+ region_id: string;
1206
+ device_location_observation?: DeviceLocationObservationWithGeoJSON;
1207
+ confidence_in: number;
1208
+ geojson?: GeoJsonFeatureCollection;
1209
+ }
1210
+ export interface LocationTransition {
1211
+ device_name: string;
1212
+ device_id: string;
1213
+ company_id: string;
1214
+ device_unique_id: string;
1215
+ region_name: string;
1216
+ region_id: string;
1217
+ location_relations: LocationRelation[];
1218
+ geojson: GeoJsonFeatureCollection;
1219
+ }
1220
+ export interface Lwm2mObjectLinks {
1221
+ _id: string;
1222
+ company_id: string;
1223
+ created_at: string;
1224
+ device_id: string;
1225
+ links: Lwm2mObjectLink[];
1226
+ }
1227
+ export interface Lwm2mObjectLink {
1228
+ url: string;
1229
+ description?: string;
1230
+ attributes?: Lwm2mAttributes;
1231
+ }
1232
+ export interface Lwm2mAttributes {
1233
+ rt?: string;
1234
+ ver?: string;
1235
+ }
1236
+ export interface Lwm2mState {
1237
+ _id: string;
1238
+ company_id: string;
1239
+ created_at: string;
1240
+ device_id: string;
1241
+ state: Lwm2mStateObject;
1242
+ }
1243
+ export interface Migration {
1244
+ Version: string;
1245
+ Migrated: string;
1246
+ }
1247
+ export interface MQTTGatewayCommand {
1248
+ id?: string;
1249
+ command: GatewayCommandType;
1250
+ schedule?: CommandSchedule;
1251
+ payload: {
1252
+ [key: string]: unknown;
1253
+ };
1254
+ attached_device_unique_ids: string[];
1255
+ }
1256
+ export interface SoftwareUpdateCommandPayload {
1257
+ name: string;
1258
+ files: (FileLocation | undefined)[];
1259
+ script: string;
1260
+ reboot: boolean;
1261
+ }
1262
+ export interface Notification {
1263
+ message: string;
1264
+ device_id: string;
1265
+ rule_id: string;
1266
+ device_config_id?: string;
1267
+ }
1268
+ export interface Params {
1269
+ Inflate: boolean;
1270
+ PageMeta: boolean;
1271
+ Page: number;
1272
+ PerPage: number;
1273
+ NextToken: string;
1274
+ OrderBy: string;
1275
+ UI: boolean;
1276
+ Locations: string[];
1277
+ LowSignalValue: number;
1278
+ Filters: Filter[];
1279
+ ModelType: ModelType;
1280
+ Cascade: boolean;
1281
+ ActAs: string;
1282
+ EmailCallback: boolean;
1283
+ EmailOverride: string;
1284
+ }
1285
+ export interface Filter {
1286
+ Operator: string;
1287
+ Token: string;
1288
+ Value: unknown;
1289
+ Values: unknown[];
1290
+ }
1291
+ export interface PollableAttributes {
1292
+ type: string;
1293
+ name: string;
1294
+ interval: number;
1295
+ defaults: {
1296
+ [key: string]: unknown;
1297
+ };
1298
+ attributes: Attribute[];
1299
+ }
1300
+ export interface Attribute {
1301
+ name: string;
1302
+ value: string;
1303
+ data_type: string;
1304
+ }
1305
+ export interface PollingStatus {
1306
+ Ingestor?: Ingestor;
1307
+ HighWaterMark: {
1308
+ [key: string]: unknown;
1309
+ };
1310
+ RunCount: number;
1311
+ CompletedAt: string;
1312
+ MinTimeout: number;
1313
+ }
1314
+ export interface PollingJob {
1315
+ Ingestor?: Ingestor;
1316
+ HighWaterMark: {
1317
+ [key: string]: unknown;
1318
+ };
1319
+ RunCount: number;
1320
+ CreatedAt: string;
1321
+ MinTimeout: number;
1322
+ }
1323
+ export interface IngestorState {
1324
+ State: string;
1325
+ IngestorID: string;
1326
+ }
1327
+ export interface PortalNavigationVisibility {
1328
+ action_hub_hidden: boolean;
1329
+ onboarding_hidden: boolean;
1330
+ overview_hidden: boolean;
1331
+ messages_hidden: boolean;
1332
+ alerts_hidden: boolean;
1333
+ lifecycle_hidden: boolean;
1334
+ devices_hidden: boolean;
1335
+ rules_hidden: boolean;
1336
+ software_hidden: boolean;
1337
+ integrations_hidden: boolean;
1338
+ users_hidden: boolean;
1339
+ roles_hidden: boolean;
1340
+ companies_hidden: boolean;
1341
+ configs_hidden: boolean;
1342
+ ingest_hidden: boolean;
1343
+ transfers_hidden: boolean;
1344
+ ha_groups_hidden: boolean;
1345
+ reports_hidden: boolean;
1346
+ secrets_hidden: boolean;
1347
+ pollable_attributes_hidden: boolean;
1348
+ }
1349
+ export interface ReportsOptions {
1350
+ time_filter_options: TimeFilterOption[];
1351
+ }
1352
+ export interface TimeFilterOption {
1353
+ display: string;
1354
+ value: string;
1355
+ }
1356
+ export interface WidgetVisibility {
1357
+ software_updates_hidden: boolean;
1358
+ data_usage_hidden: boolean;
1359
+ }
1360
+ export interface PortalConfiguration {
1361
+ navigation: PortalNavigationVisibility;
1362
+ reports_options: ReportsOptions;
1363
+ widgets: WidgetVisibility;
1364
+ }
1365
+ export interface SimpleMessage {
1366
+ Verb: string;
1367
+ Object: string;
1368
+ }
1369
+ export interface QueueMessage {
1370
+ CompanyID: string;
1371
+ ID: string;
1372
+ ParentID: string;
1373
+ Bytes: string;
1374
+ }
1375
+ export interface Lwm2mQueueMessage {
1376
+ Client: string;
1377
+ Data: {
1378
+ [key: string]: unknown;
1379
+ };
1380
+ Links: Lwm2mObjectLink[];
1381
+ }
1382
+ export interface Lwm2mDeviceSyncEventQueueMessage {
1383
+ action: string;
1384
+ unique_id: string;
1385
+ company_id?: string;
1386
+ secret?: string;
1387
+ }
1388
+ export interface Lwm2mRequestQueueMessage {
1389
+ client: string;
1390
+ type: string;
1391
+ endpoint: string;
1392
+ data: string;
1393
+ }
1394
+ export interface TranslateQueueMessage {
1395
+ IngestorID: string;
1396
+ DeviceUniqueID: string;
1397
+ Metadata: {
1398
+ [key: string]: unknown;
1399
+ };
1400
+ Message: string;
1401
+ }
1402
+ export interface SystemCommandJobQueueMessage {
1403
+ DownstreamSystem?: DownstreamSystem;
1404
+ SystemCommand?: SystemCommand;
1405
+ SystemCommandJob?: SystemCommandJob;
1406
+ }
1407
+ export interface DeviceTransferJobQueueMessage {
1408
+ DeviceTransferRequest?: DeviceTransferRequest;
1409
+ RequestingUser?: User;
1410
+ }
1411
+ export interface DeviceIntegrationActionQueueMessageData {
1412
+ CallbackID: string;
1413
+ Action: DeviceIntegrationActionType;
1414
+ Integration?: Integration;
1415
+ ParentDevice?: Device;
1416
+ Device?: Device;
1417
+ DeviceType?: DeviceType;
1418
+ Report?: Report;
1419
+ Topic: string;
1420
+ Message: string;
1421
+ LambdaFunctionName: string;
1422
+ GreengrassFunction?: GreengrassFunction;
1423
+ GreengrassFunctionARN: string;
1424
+ GreengrassFunctionID: string;
1425
+ GreengrassSubscription?: GreengrassSubscription;
1426
+ GreengrassSubscriptionARN: string;
1427
+ GreengrassSubscriptionID: string;
1428
+ GreengrassGroupIDs: string[];
1429
+ GreengrassConnectivityInfo?: GreengrassConnectivityInfo;
1430
+ DeviceUniqueIDs: string[];
1431
+ BulkResponseID: string;
1432
+ Params?: Params;
1433
+ }
1434
+ export interface Region {
1435
+ _id: string;
1436
+ company_id: string;
1437
+ name: string;
1438
+ created_at: string;
1439
+ updated_at?: string;
1440
+ geojson: GeoJsonFeature;
1441
+ metadata: {
1442
+ [key: string]: unknown;
1443
+ };
1444
+ }
1445
+ export interface Report {
1446
+ _id?: string;
1447
+ device_name: string;
1448
+ created_at: string;
1449
+ device_datetime: string;
1450
+ payload: {
1451
+ [key: string]: unknown;
1452
+ };
1453
+ raw_data?: string;
1454
+ seq: number;
1455
+ heartbeat: boolean;
1456
+ type: ReportType;
1457
+ company_id: string;
1458
+ user_id: string;
1459
+ device_id: string;
1460
+ }
1461
+ export interface ReportBSON {
1462
+ ID: string;
1463
+ DeviceDateTime?: string;
1464
+ Payload: {
1465
+ [key: string]: unknown;
1466
+ };
1467
+ RawData?: string;
1468
+ Seq?: number;
1469
+ DeviceID: string;
1470
+ }
1471
+ export interface HeartbeatPayloadBSON {
1472
+ Status?: string;
1473
+ EdgeVersion?: string;
1474
+ CellSignal?: string;
1475
+ CellUsage?: string;
1476
+ SimCard?: string;
1477
+ Connections: {
1478
+ [key: string]: string;
1479
+ };
1480
+ WifiClients: string[];
1481
+ CPUUsage?: string;
1482
+ RAMUsage?: string;
1483
+ DiskSize?: string;
1484
+ DiskFree?: string;
1485
+ DiskUsage?: string;
1486
+ Seq?: string;
1487
+ IPs: string[];
1488
+ Custom: {
1489
+ [key: string]: string;
1490
+ };
1491
+ LastEndpointReportAt: {
1492
+ [key: string]: string;
1493
+ };
1494
+ }
1495
+ export interface HeartbeatPayloadJSON {
1496
+ status?: string;
1497
+ edge_version?: string;
1498
+ cell_signal?: string;
1499
+ cell_usage?: string;
1500
+ sim_card?: string;
1501
+ connections: {
1502
+ [key: string]: string;
1503
+ };
1504
+ wifi_clients: string[];
1505
+ cpu_usage?: string;
1506
+ ram_usage?: string;
1507
+ disk_size?: string;
1508
+ disk_free?: string;
1509
+ disk_usage?: string;
1510
+ seq?: string;
1511
+ ips: string[];
1512
+ custom: {
1513
+ [key: string]: string;
1514
+ };
1515
+ last_endpoint_report_at: {
1516
+ [key: string]: string;
1517
+ };
1518
+ }
1519
+ export interface ErrorResponse {
1520
+ error: string;
1521
+ messages?: string[];
1522
+ }
1523
+ export interface PagedResponse {
1524
+ page: number;
1525
+ per_page: number;
1526
+ total: number;
1527
+ next_token?: string;
1528
+ resources: unknown;
1529
+ }
1530
+ export interface CSVResponse {
1531
+ success_count: number;
1532
+ fail_count: number;
1533
+ errors: CSVError[];
1534
+ }
1535
+ export interface CSVError {
1536
+ row: number;
1537
+ messages: string[];
1538
+ }
1539
+ export interface Rule {
1540
+ active: boolean;
1541
+ last_run_status: Status;
1542
+ description: string;
1543
+ plain_english: string;
1544
+ then_actions: (RuleAction | undefined)[];
1545
+ else_actions: (RuleAction | undefined)[];
1546
+ rule_condition?: RuleCondition;
1547
+ pass_count: number;
1548
+ fail_count: number;
1549
+ cloud_rule: boolean;
1550
+ scheduled_only?: boolean;
1551
+ schedule?: string;
1552
+ scheduler_job_id?: string;
1553
+ }
1554
+ export interface RuleWithRelations {
1555
+ device_type_id: string;
1556
+ device_id: string;
1557
+ }
1558
+ export interface RuleContext {
1559
+ Rule?: Rule;
1560
+ Report?: Report;
1561
+ Device?: Device;
1562
+ DeviceType?: DeviceType;
1563
+ DeviceError?: DeviceError;
1564
+ DeviceConfig?: DeviceConfig;
1565
+ Integration?: Integration;
1566
+ LocationTransition?: LocationTransition;
1567
+ }
1568
+ export interface PRTGChannel {
1569
+ name?: string;
1570
+ value?: string;
1571
+ type?: string;
1572
+ default?: number;
1573
+ enum?: {
1574
+ [key: string]: number;
1575
+ };
1576
+ }
1577
+ export interface RuleAction {
1578
+ type: ActionType;
1579
+ send_to?: string;
1580
+ body_template?: string;
1581
+ action_frequency: unknown;
1582
+ retries: number;
1583
+ retry_timeout: number;
1584
+ clear: boolean;
1585
+ last_run: string;
1586
+ integration_id?: string;
1587
+ url?: string;
1588
+ topic?: string;
1589
+ username?: string;
1590
+ password?: string;
1591
+ client_id?: string;
1592
+ will_topic?: string;
1593
+ keep_alive?: boolean;
1594
+ method?: string;
1595
+ headers?: {
1596
+ [key: string]: string;
1597
+ };
1598
+ from?: string;
1599
+ subject?: string;
1600
+ body_type?: BodyType;
1601
+ metadata_key?: string;
1602
+ health_status?: DeviceHealthStatus;
1603
+ latitude_template?: string;
1604
+ longitude_template?: string;
1605
+ radius_template?: string;
1606
+ generated_at_template?: string;
1607
+ generated_at_format?: string;
1608
+ location_via?: string;
1609
+ channels?: PRTGChannel[];
1610
+ credentials?: Credentials;
1611
+ definition_id?: string;
1612
+ }
1613
+ export interface Credentials {
1614
+ type: string;
1615
+ data: {
1616
+ [key: string]: CredentialData;
1617
+ };
1618
+ }
1619
+ export interface CredentialData {
1620
+ type?: string;
1621
+ value: string;
1622
+ secret_id: string;
1623
+ }
1624
+ export interface RuleCondition {
1625
+ type: RuleConditionType;
1626
+ property?: string;
1627
+ value?: unknown;
1628
+ value_type?: ValueType;
1629
+ rule_conditions?: (RuleCondition | undefined)[];
1630
+ error_type?: DeviceErrorType;
1631
+ location_transition_evaluator?: LocationTransitionEvaluator;
1632
+ }
1633
+ export interface RuleConditionWithRuleID {
1634
+ RuleID?: string;
1635
+ rule_condition_ids?: string[];
1636
+ type: string;
1637
+ LegacyType?: string;
1638
+ property?: string;
1639
+ value?: unknown;
1640
+ value_type?: ValueType;
1641
+ }
1642
+ export interface inboundSecret {
1643
+ company_id: string;
1644
+ name: string;
1645
+ expires_at?: string;
1646
+ contents: string;
1647
+ }
1648
+ export interface Secret {
1649
+ _id: string;
1650
+ company_id: string;
1651
+ name: string;
1652
+ created_at: string;
1653
+ created_by: string;
1654
+ expires_at?: string;
1655
+ }
1656
+ export interface SecretModel {
1657
+ secret_id: string;
1658
+ model_id: string;
1659
+ model: string;
1660
+ }
1661
+ export interface PopulatedSecret {
1662
+ [index: string]: unknown;
1663
+ }
1664
+ export interface InvalidWarehouseError {
1665
+ SecretID: string;
1666
+ SecretWarehouseID: string;
1667
+ WarehouseID: string;
1668
+ }
1669
+ export interface NilWarehouseError {
1670
+ [index: string]: unknown;
1671
+ }
1672
+ export interface FileLocation {
1673
+ name: string;
1674
+ link: string;
1675
+ }
1676
+ export interface SoftwareUpdate {
1677
+ name: string;
1678
+ files: (FileLocation | undefined)[];
1679
+ script: string;
1680
+ reboot: boolean;
1681
+ device_type_id: string;
1682
+ }
1683
+ export interface StatsDeviceCountByHeartbeatStatus {
1684
+ as_expected: number;
1685
+ inconsistent: number;
1686
+ not_responsive: number;
1687
+ never_reported: number;
1688
+ other?: {
1689
+ [key: string]: number;
1690
+ };
1691
+ }
1692
+ export interface StatsDeviceCountByTypeObject {
1693
+ name: string;
1694
+ count: number;
1695
+ }
1696
+ export interface SystemCommand {
1697
+ name: string;
1698
+ description: string;
1699
+ type: string;
1700
+ method: string;
1701
+ protocol: string;
1702
+ host: string;
1703
+ port?: number;
1704
+ path_template: string;
1705
+ body_template: string;
1706
+ header_template: string;
1707
+ verify_server_certificate: boolean;
1708
+ response_mime_type: string;
1709
+ output_variable_templates: {
1710
+ [key: string]: string;
1711
+ };
1712
+ downstream_system_id: string;
1713
+ }
1714
+ export interface SystemCommandJob {
1715
+ status: SystemCommandJobStatusType;
1716
+ template_variables: {
1717
+ [key: string]: unknown;
1718
+ };
1719
+ executed_at?: string;
1720
+ request_url: string;
1721
+ request_body: string;
1722
+ request_headers: string;
1723
+ response_status_code: number;
1724
+ response_body: string;
1725
+ response_headers: string;
1726
+ output_variables: {
1727
+ [key: string]: string;
1728
+ };
1729
+ downstream_system_id: string;
1730
+ system_command_id: string;
1731
+ }
1732
+ export interface Translator {
1733
+ name: string;
1734
+ type: TranslatorType;
1735
+ script?: string;
1736
+ options?: {
1737
+ [key: string]: unknown;
1738
+ };
1739
+ }
1740
+ export interface UpstreamAction {
1741
+ device_id: string;
1742
+ name: string;
1743
+ type: UpstreamActionType;
1744
+ action: Uint32Array;
1745
+ }
1746
+ export interface User {
1747
+ email: string;
1748
+ password: string;
1749
+ password_confirmation: string;
1750
+ domain: string;
1751
+ first_name: string;
1752
+ last_name: string;
1753
+ phone_number: string;
1754
+ logo_url: string;
1755
+ metadata?: {
1756
+ [key: string]: unknown;
1757
+ };
1758
+ user_type_id: string;
1759
+ company_ids: string[];
1760
+ }
1761
+ export interface UserForMarshal {
1762
+ api_token?: string;
1763
+ session_token?: string;
1764
+ session_expires_at?: string;
1765
+ }
1766
+ export interface UserWithPasswordAndToken {
1767
+ email: string;
1768
+ encrypted_password: string;
1769
+ encrypted_authentication_token: string;
1770
+ first_name: string;
1771
+ last_name: string;
1772
+ phone_number: string;
1773
+ logo_url: string;
1774
+ }
1775
+ export interface Authenticate {
1776
+ email: string;
1777
+ password: string;
1778
+ domain: string;
1779
+ token_expiry?: string;
1780
+ }
1781
+ export interface PasswordReset {
1782
+ password: string;
1783
+ password_confirmation: string;
1784
+ }
1785
+ export interface PasswordResetRequest {
1786
+ email: string;
1787
+ url: string;
1788
+ from_address?: string;
1789
+ subject?: string;
1790
+ greeting?: string;
1791
+ }
1792
+ export interface UserType {
1793
+ name: string;
1794
+ description: string;
1795
+ abilities: Abilities;
1796
+ }
1797
+ export interface WorkflowContext {
1798
+ service_data: {
1799
+ [key: string]: WorkflowContextServiceData;
1800
+ };
1801
+ user_data: {
1802
+ [key: string]: string;
1803
+ };
1804
+ }
1805
+ export interface WorkflowContextServiceData {
1806
+ resource: string;
1807
+ id: string;
1808
+ }
1809
+ export interface WorkflowContextRestData {
1810
+ object: unknown;
1811
+ }
1812
+ export interface WorkflowDefinition {
1813
+ id: string;
1814
+ company_id: string;
1815
+ name: string;
1816
+ default_context?: WorkflowContext;
1817
+ base_context?: WorkflowContext;
1818
+ created_at: string;
1819
+ updated_at: string;
1820
+ }
1821
+ export interface WorkflowAction {
1822
+ id: string;
1823
+ company_id: string;
1824
+ name: string;
1825
+ max_retries: number;
1826
+ type: string;
1827
+ properties: {
1828
+ [key: string]: unknown;
1829
+ };
1830
+ created_at: string;
1831
+ updated_at: string;
1832
+ }
1833
+ export interface WorkflowTree {
1834
+ id: string;
1835
+ definition_id: string;
1836
+ parent_id?: string;
1837
+ child_id: string;
1838
+ created_at: string;
1839
+ }
1840
+ export interface WorkflowRecord {
1841
+ id: string;
1842
+ company_id: string;
1843
+ definition_id: string;
1844
+ created_at: string;
1845
+ completed_at?: string;
1846
+ }
1847
+ export interface WorkflowJobResult {
1848
+ id: string;
1849
+ company_id: string;
1850
+ parent_id?: string;
1851
+ workflow_record_id: string;
1852
+ action_id: string;
1853
+ success: boolean;
1854
+ returned_data: {
1855
+ [key: string]: unknown;
1856
+ };
1857
+ context_data: {
1858
+ [key: string]: unknown;
1859
+ };
1860
+ retries: number;
1861
+ created_at: string;
1862
+ }
1863
+ export interface GeoJsonFeatureCollection {
1864
+ type: string;
1865
+ bbox?: number[];
1866
+ features: (GeoJsonFeature | undefined)[];
1867
+ crs?: {
1868
+ [key: string]: unknown;
1869
+ };
1870
+ }
1871
+ export interface GeoJsonFeature {
1872
+ id?: unknown;
1873
+ type: string;
1874
+ bbox?: number[];
1875
+ geometry?: GeoJsonGeometry;
1876
+ properties: {
1877
+ [key: string]: unknown;
1878
+ };
1879
+ crs?: {
1880
+ [key: string]: unknown;
1881
+ };
1882
+ }
1883
+ export interface GeoJsonGeometry {
1884
+ type: GeometryType;
1885
+ bbox?: number[];
1886
+ Point: number[];
1887
+ MultiPoint: number[][];
1888
+ LineString: number[][];
1889
+ MultiLineString: number[][][];
1890
+ Polygon: number[][][];
1891
+ MultiPolygon: number[][][][];
1892
+ Geometries: (GeoJsonGeometry | undefined)[];
1893
+ crs?: {
1894
+ [key: string]: unknown;
1895
+ };
1896
+ }