@scaleway/sdk-iot 2.6.5 → 2.8.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -0,0 +1,31 @@
1
+ import type { DefaultValues } from '@scaleway/sdk-client';
2
+ import type { Device, Network, Hub, CreateDeviceResponse, CreateNetworkResponse, GetDeviceCertificateResponse, GetDeviceMetricsResponse, GetHubCAResponse, GetHubMetricsResponse, ListDevicesResponse, ListHubsResponse, ListNetworksResponse, ListRoutesResponse, ListTwinDocumentsResponse, RenewDeviceCertificateResponse, Route, SetDeviceCertificateResponse, TwinDocument, CreateDeviceRequest, CreateHubRequest, CreateNetworkRequest, CreateRouteRequest, PatchTwinDocumentRequest, PutTwinDocumentRequest, SetDeviceCertificateRequest, SetHubCARequest, UpdateDeviceRequest, UpdateHubRequest, UpdateRouteRequest } from './types.gen.js';
3
+ export declare const unmarshalDevice: (data: unknown) => Device;
4
+ export declare const unmarshalNetwork: (data: unknown) => Network;
5
+ export declare const unmarshalHub: (data: unknown) => Hub;
6
+ export declare const unmarshalCreateDeviceResponse: (data: unknown) => CreateDeviceResponse;
7
+ export declare const unmarshalCreateNetworkResponse: (data: unknown) => CreateNetworkResponse;
8
+ export declare const unmarshalGetDeviceCertificateResponse: (data: unknown) => GetDeviceCertificateResponse;
9
+ export declare const unmarshalGetDeviceMetricsResponse: (data: unknown) => GetDeviceMetricsResponse;
10
+ export declare const unmarshalGetHubCAResponse: (data: unknown) => GetHubCAResponse;
11
+ export declare const unmarshalGetHubMetricsResponse: (data: unknown) => GetHubMetricsResponse;
12
+ export declare const unmarshalListDevicesResponse: (data: unknown) => ListDevicesResponse;
13
+ export declare const unmarshalListHubsResponse: (data: unknown) => ListHubsResponse;
14
+ export declare const unmarshalListNetworksResponse: (data: unknown) => ListNetworksResponse;
15
+ export declare const unmarshalListRoutesResponse: (data: unknown) => ListRoutesResponse;
16
+ export declare const unmarshalListTwinDocumentsResponse: (data: unknown) => ListTwinDocumentsResponse;
17
+ export declare const unmarshalRenewDeviceCertificateResponse: (data: unknown) => RenewDeviceCertificateResponse;
18
+ export declare const unmarshalRoute: (data: unknown) => Route;
19
+ export declare const unmarshalSetDeviceCertificateResponse: (data: unknown) => SetDeviceCertificateResponse;
20
+ export declare const unmarshalTwinDocument: (data: unknown) => TwinDocument;
21
+ export declare const marshalCreateDeviceRequest: (request: CreateDeviceRequest, defaults: DefaultValues) => Record<string, unknown>;
22
+ export declare const marshalCreateHubRequest: (request: CreateHubRequest, defaults: DefaultValues) => Record<string, unknown>;
23
+ export declare const marshalCreateNetworkRequest: (request: CreateNetworkRequest, defaults: DefaultValues) => Record<string, unknown>;
24
+ export declare const marshalCreateRouteRequest: (request: CreateRouteRequest, defaults: DefaultValues) => Record<string, unknown>;
25
+ export declare const marshalPatchTwinDocumentRequest: (request: PatchTwinDocumentRequest, defaults: DefaultValues) => Record<string, unknown>;
26
+ export declare const marshalPutTwinDocumentRequest: (request: PutTwinDocumentRequest, defaults: DefaultValues) => Record<string, unknown>;
27
+ export declare const marshalSetDeviceCertificateRequest: (request: SetDeviceCertificateRequest, defaults: DefaultValues) => Record<string, unknown>;
28
+ export declare const marshalSetHubCARequest: (request: SetHubCARequest, defaults: DefaultValues) => Record<string, unknown>;
29
+ export declare const marshalUpdateDeviceRequest: (request: UpdateDeviceRequest, defaults: DefaultValues) => Record<string, unknown>;
30
+ export declare const marshalUpdateHubRequest: (request: UpdateHubRequest, defaults: DefaultValues) => Record<string, unknown>;
31
+ export declare const marshalUpdateRouteRequest: (request: UpdateRouteRequest, defaults: DefaultValues) => Record<string, unknown>;
@@ -0,0 +1,377 @@
1
+ import { isJSONObject, resolveOneOf, unmarshalArrayOfObject, unmarshalDate, unmarshalTimeSeries } from "@scaleway/sdk-client";
2
+ import randomName from "@scaleway/random-name";
3
+ //#region src/v1/marshalling.gen.ts
4
+ const unmarshalDeviceMessageFiltersRule = (data) => {
5
+ if (!isJSONObject(data)) throw new TypeError(`Unmarshalling the type 'DeviceMessageFiltersRule' failed as data isn't a dictionary.`);
6
+ return {
7
+ policy: data.policy,
8
+ topics: data.topics
9
+ };
10
+ };
11
+ const unmarshalDeviceMessageFilters = (data) => {
12
+ if (!isJSONObject(data)) throw new TypeError(`Unmarshalling the type 'DeviceMessageFilters' failed as data isn't a dictionary.`);
13
+ return {
14
+ publish: data.publish ? unmarshalDeviceMessageFiltersRule(data.publish) : void 0,
15
+ subscribe: data.subscribe ? unmarshalDeviceMessageFiltersRule(data.subscribe) : void 0
16
+ };
17
+ };
18
+ const unmarshalDevice = (data) => {
19
+ if (!isJSONObject(data)) throw new TypeError(`Unmarshalling the type 'Device' failed as data isn't a dictionary.`);
20
+ return {
21
+ allowInsecure: data.allow_insecure,
22
+ allowMultipleConnections: data.allow_multiple_connections,
23
+ createdAt: unmarshalDate(data.created_at),
24
+ description: data.description,
25
+ hasCustomCertificate: data.has_custom_certificate,
26
+ hubId: data.hub_id,
27
+ id: data.id,
28
+ isConnected: data.is_connected,
29
+ lastActivityAt: unmarshalDate(data.last_activity_at),
30
+ messageFilters: data.message_filters ? unmarshalDeviceMessageFilters(data.message_filters) : void 0,
31
+ name: data.name,
32
+ region: data.region,
33
+ status: data.status,
34
+ updatedAt: unmarshalDate(data.updated_at)
35
+ };
36
+ };
37
+ const unmarshalNetwork = (data) => {
38
+ if (!isJSONObject(data)) throw new TypeError(`Unmarshalling the type 'Network' failed as data isn't a dictionary.`);
39
+ return {
40
+ createdAt: unmarshalDate(data.created_at),
41
+ endpoint: data.endpoint,
42
+ hubId: data.hub_id,
43
+ id: data.id,
44
+ name: data.name,
45
+ region: data.region,
46
+ topicPrefix: data.topic_prefix,
47
+ type: data.type
48
+ };
49
+ };
50
+ const unmarshalHubTwinsGraphiteConfig = (data) => {
51
+ if (!isJSONObject(data)) throw new TypeError(`Unmarshalling the type 'HubTwinsGraphiteConfig' failed as data isn't a dictionary.`);
52
+ return { pushUri: data.push_uri };
53
+ };
54
+ const unmarshalHub = (data) => {
55
+ if (!isJSONObject(data)) throw new TypeError(`Unmarshalling the type 'Hub' failed as data isn't a dictionary.`);
56
+ return {
57
+ connectedDeviceCount: data.connected_device_count,
58
+ createdAt: unmarshalDate(data.created_at),
59
+ deviceCount: data.device_count,
60
+ disableEvents: data.disable_events,
61
+ enableDeviceAutoProvisioning: data.enable_device_auto_provisioning,
62
+ enabled: data.enabled,
63
+ endpoint: data.endpoint,
64
+ eventsTopicPrefix: data.events_topic_prefix,
65
+ hasCustomCa: data.has_custom_ca,
66
+ id: data.id,
67
+ name: data.name,
68
+ organizationId: data.organization_id,
69
+ productPlan: data.product_plan,
70
+ projectId: data.project_id,
71
+ region: data.region,
72
+ status: data.status,
73
+ twinsGraphiteConfig: data.twins_graphite_config ? unmarshalHubTwinsGraphiteConfig(data.twins_graphite_config) : void 0,
74
+ updatedAt: unmarshalDate(data.updated_at)
75
+ };
76
+ };
77
+ const unmarshalCertificate = (data) => {
78
+ if (!isJSONObject(data)) throw new TypeError(`Unmarshalling the type 'Certificate' failed as data isn't a dictionary.`);
79
+ return {
80
+ crt: data.crt,
81
+ key: data.key
82
+ };
83
+ };
84
+ const unmarshalCreateDeviceResponse = (data) => {
85
+ if (!isJSONObject(data)) throw new TypeError(`Unmarshalling the type 'CreateDeviceResponse' failed as data isn't a dictionary.`);
86
+ return {
87
+ certificate: data.certificate ? unmarshalCertificate(data.certificate) : void 0,
88
+ device: data.device ? unmarshalDevice(data.device) : void 0
89
+ };
90
+ };
91
+ const unmarshalCreateNetworkResponse = (data) => {
92
+ if (!isJSONObject(data)) throw new TypeError(`Unmarshalling the type 'CreateNetworkResponse' failed as data isn't a dictionary.`);
93
+ return {
94
+ network: data.network ? unmarshalNetwork(data.network) : void 0,
95
+ secret: data.secret
96
+ };
97
+ };
98
+ const unmarshalGetDeviceCertificateResponse = (data) => {
99
+ if (!isJSONObject(data)) throw new TypeError(`Unmarshalling the type 'GetDeviceCertificateResponse' failed as data isn't a dictionary.`);
100
+ return {
101
+ certificatePem: data.certificate_pem,
102
+ device: data.device ? unmarshalDevice(data.device) : void 0
103
+ };
104
+ };
105
+ const unmarshalGetDeviceMetricsResponse = (data) => {
106
+ if (!isJSONObject(data)) throw new TypeError(`Unmarshalling the type 'GetDeviceMetricsResponse' failed as data isn't a dictionary.`);
107
+ return { metrics: unmarshalArrayOfObject(data.metrics, unmarshalTimeSeries) };
108
+ };
109
+ const unmarshalGetHubCAResponse = (data) => {
110
+ if (!isJSONObject(data)) throw new TypeError(`Unmarshalling the type 'GetHubCAResponse' failed as data isn't a dictionary.`);
111
+ return { caCertPem: data.ca_cert_pem };
112
+ };
113
+ const unmarshalGetHubMetricsResponse = (data) => {
114
+ if (!isJSONObject(data)) throw new TypeError(`Unmarshalling the type 'GetHubMetricsResponse' failed as data isn't a dictionary.`);
115
+ return { metrics: unmarshalArrayOfObject(data.metrics, unmarshalTimeSeries) };
116
+ };
117
+ const unmarshalListDevicesResponse = (data) => {
118
+ if (!isJSONObject(data)) throw new TypeError(`Unmarshalling the type 'ListDevicesResponse' failed as data isn't a dictionary.`);
119
+ return {
120
+ devices: unmarshalArrayOfObject(data.devices, unmarshalDevice),
121
+ totalCount: data.total_count
122
+ };
123
+ };
124
+ const unmarshalListHubsResponse = (data) => {
125
+ if (!isJSONObject(data)) throw new TypeError(`Unmarshalling the type 'ListHubsResponse' failed as data isn't a dictionary.`);
126
+ return {
127
+ hubs: unmarshalArrayOfObject(data.hubs, unmarshalHub),
128
+ totalCount: data.total_count
129
+ };
130
+ };
131
+ const unmarshalListNetworksResponse = (data) => {
132
+ if (!isJSONObject(data)) throw new TypeError(`Unmarshalling the type 'ListNetworksResponse' failed as data isn't a dictionary.`);
133
+ return {
134
+ networks: unmarshalArrayOfObject(data.networks, unmarshalNetwork),
135
+ totalCount: data.total_count
136
+ };
137
+ };
138
+ const unmarshalRouteSummary = (data) => {
139
+ if (!isJSONObject(data)) throw new TypeError(`Unmarshalling the type 'RouteSummary' failed as data isn't a dictionary.`);
140
+ return {
141
+ createdAt: unmarshalDate(data.created_at),
142
+ hubId: data.hub_id,
143
+ id: data.id,
144
+ name: data.name,
145
+ region: data.region,
146
+ topic: data.topic,
147
+ type: data.type,
148
+ updatedAt: unmarshalDate(data.updated_at)
149
+ };
150
+ };
151
+ const unmarshalListRoutesResponse = (data) => {
152
+ if (!isJSONObject(data)) throw new TypeError(`Unmarshalling the type 'ListRoutesResponse' failed as data isn't a dictionary.`);
153
+ return {
154
+ routes: unmarshalArrayOfObject(data.routes, unmarshalRouteSummary),
155
+ totalCount: data.total_count
156
+ };
157
+ };
158
+ const unmarshalListTwinDocumentsResponseDocumentSummary = (data) => {
159
+ if (!isJSONObject(data)) throw new TypeError(`Unmarshalling the type 'ListTwinDocumentsResponseDocumentSummary' failed as data isn't a dictionary.`);
160
+ return { documentName: data.document_name };
161
+ };
162
+ const unmarshalListTwinDocumentsResponse = (data) => {
163
+ if (!isJSONObject(data)) throw new TypeError(`Unmarshalling the type 'ListTwinDocumentsResponse' failed as data isn't a dictionary.`);
164
+ return { documents: unmarshalArrayOfObject(data.documents, unmarshalListTwinDocumentsResponseDocumentSummary) };
165
+ };
166
+ const unmarshalRenewDeviceCertificateResponse = (data) => {
167
+ if (!isJSONObject(data)) throw new TypeError(`Unmarshalling the type 'RenewDeviceCertificateResponse' failed as data isn't a dictionary.`);
168
+ return {
169
+ certificate: data.certificate ? unmarshalCertificate(data.certificate) : void 0,
170
+ device: data.device ? unmarshalDevice(data.device) : void 0
171
+ };
172
+ };
173
+ const unmarshalRouteDatabaseConfig = (data) => {
174
+ if (!isJSONObject(data)) throw new TypeError(`Unmarshalling the type 'RouteDatabaseConfig' failed as data isn't a dictionary.`);
175
+ return {
176
+ dbname: data.dbname,
177
+ engine: data.engine,
178
+ host: data.host,
179
+ password: data.password,
180
+ port: data.port,
181
+ query: data.query,
182
+ username: data.username
183
+ };
184
+ };
185
+ const unmarshalRouteRestConfig = (data) => {
186
+ if (!isJSONObject(data)) throw new TypeError(`Unmarshalling the type 'RouteRestConfig' failed as data isn't a dictionary.`);
187
+ return {
188
+ headers: data.headers,
189
+ uri: data.uri,
190
+ verb: data.verb
191
+ };
192
+ };
193
+ const unmarshalRouteS3Config = (data) => {
194
+ if (!isJSONObject(data)) throw new TypeError(`Unmarshalling the type 'RouteS3Config' failed as data isn't a dictionary.`);
195
+ return {
196
+ bucketName: data.bucket_name,
197
+ bucketRegion: data.bucket_region,
198
+ objectPrefix: data.object_prefix,
199
+ strategy: data.strategy
200
+ };
201
+ };
202
+ const unmarshalRoute = (data) => {
203
+ if (!isJSONObject(data)) throw new TypeError(`Unmarshalling the type 'Route' failed as data isn't a dictionary.`);
204
+ return {
205
+ createdAt: unmarshalDate(data.created_at),
206
+ dbConfig: data.db_config ? unmarshalRouteDatabaseConfig(data.db_config) : void 0,
207
+ hubId: data.hub_id,
208
+ id: data.id,
209
+ name: data.name,
210
+ region: data.region,
211
+ restConfig: data.rest_config ? unmarshalRouteRestConfig(data.rest_config) : void 0,
212
+ s3Config: data.s3_config ? unmarshalRouteS3Config(data.s3_config) : void 0,
213
+ topic: data.topic,
214
+ type: data.type,
215
+ updatedAt: unmarshalDate(data.updated_at)
216
+ };
217
+ };
218
+ const unmarshalSetDeviceCertificateResponse = (data) => {
219
+ if (!isJSONObject(data)) throw new TypeError(`Unmarshalling the type 'SetDeviceCertificateResponse' failed as data isn't a dictionary.`);
220
+ return {
221
+ certificatePem: data.certificate_pem,
222
+ device: data.device ? unmarshalDevice(data.device) : void 0
223
+ };
224
+ };
225
+ const unmarshalTwinDocument = (data) => {
226
+ if (!isJSONObject(data)) throw new TypeError(`Unmarshalling the type 'TwinDocument' failed as data isn't a dictionary.`);
227
+ return {
228
+ data: data.data,
229
+ documentName: data.document_name,
230
+ twinId: data.twin_id,
231
+ version: data.version
232
+ };
233
+ };
234
+ const marshalDeviceMessageFiltersRule = (request, defaults) => ({
235
+ policy: request.policy,
236
+ topics: request.topics
237
+ });
238
+ const marshalDeviceMessageFilters = (request, defaults) => ({
239
+ publish: request.publish !== void 0 ? marshalDeviceMessageFiltersRule(request.publish, defaults) : void 0,
240
+ subscribe: request.subscribe !== void 0 ? marshalDeviceMessageFiltersRule(request.subscribe, defaults) : void 0
241
+ });
242
+ const marshalCreateDeviceRequest = (request, defaults) => ({
243
+ allow_insecure: request.allowInsecure,
244
+ allow_multiple_connections: request.allowMultipleConnections,
245
+ description: request.description,
246
+ hub_id: request.hubId,
247
+ message_filters: request.messageFilters !== void 0 ? marshalDeviceMessageFilters(request.messageFilters, defaults) : void 0,
248
+ name: request.name || randomName("device")
249
+ });
250
+ const marshalHubTwinsGraphiteConfig = (request, defaults) => ({ push_uri: request.pushUri });
251
+ const marshalCreateHubRequest = (request, defaults) => ({
252
+ disable_events: request.disableEvents,
253
+ events_topic_prefix: request.eventsTopicPrefix,
254
+ name: request.name || randomName("hub"),
255
+ product_plan: request.productPlan,
256
+ project_id: request.projectId ?? defaults.defaultProjectId,
257
+ ...resolveOneOf([{
258
+ param: "twins_graphite_config",
259
+ value: request.twinsGraphiteConfig !== void 0 ? marshalHubTwinsGraphiteConfig(request.twinsGraphiteConfig, defaults) : void 0
260
+ }])
261
+ });
262
+ const marshalCreateNetworkRequest = (request, defaults) => ({
263
+ hub_id: request.hubId,
264
+ name: request.name || randomName("network"),
265
+ topic_prefix: request.topicPrefix,
266
+ type: request.type
267
+ });
268
+ const marshalCreateRouteRequestDatabaseConfig = (request, defaults) => ({
269
+ dbname: request.dbname,
270
+ engine: request.engine,
271
+ host: request.host,
272
+ password: request.password,
273
+ port: request.port,
274
+ query: request.query,
275
+ username: request.username
276
+ });
277
+ const marshalCreateRouteRequestRestConfig = (request, defaults) => ({
278
+ headers: request.headers,
279
+ uri: request.uri,
280
+ verb: request.verb
281
+ });
282
+ const marshalCreateRouteRequestS3Config = (request, defaults) => ({
283
+ bucket_name: request.bucketName,
284
+ bucket_region: request.bucketRegion,
285
+ object_prefix: request.objectPrefix,
286
+ strategy: request.strategy
287
+ });
288
+ const marshalCreateRouteRequest = (request, defaults) => ({
289
+ hub_id: request.hubId,
290
+ name: request.name || randomName("route"),
291
+ topic: request.topic,
292
+ ...resolveOneOf([
293
+ {
294
+ param: "s3_config",
295
+ value: request.s3Config !== void 0 ? marshalCreateRouteRequestS3Config(request.s3Config, defaults) : void 0
296
+ },
297
+ {
298
+ param: "db_config",
299
+ value: request.dbConfig !== void 0 ? marshalCreateRouteRequestDatabaseConfig(request.dbConfig, defaults) : void 0
300
+ },
301
+ {
302
+ param: "rest_config",
303
+ value: request.restConfig !== void 0 ? marshalCreateRouteRequestRestConfig(request.restConfig, defaults) : void 0
304
+ }
305
+ ])
306
+ });
307
+ const marshalPatchTwinDocumentRequest = (request, defaults) => ({
308
+ data: request.data,
309
+ version: request.version
310
+ });
311
+ const marshalPutTwinDocumentRequest = (request, defaults) => ({
312
+ data: request.data,
313
+ version: request.version
314
+ });
315
+ const marshalSetDeviceCertificateRequest = (request, defaults) => ({ certificate_pem: request.certificatePem });
316
+ const marshalSetHubCARequest = (request, defaults) => ({
317
+ ca_cert_pem: request.caCertPem,
318
+ challenge_cert_pem: request.challengeCertPem
319
+ });
320
+ const marshalUpdateDeviceRequest = (request, defaults) => ({
321
+ allow_insecure: request.allowInsecure,
322
+ allow_multiple_connections: request.allowMultipleConnections,
323
+ description: request.description,
324
+ hub_id: request.hubId,
325
+ message_filters: request.messageFilters !== void 0 ? marshalDeviceMessageFilters(request.messageFilters, defaults) : void 0
326
+ });
327
+ const marshalUpdateHubRequest = (request, defaults) => ({
328
+ disable_events: request.disableEvents,
329
+ enable_device_auto_provisioning: request.enableDeviceAutoProvisioning,
330
+ events_topic_prefix: request.eventsTopicPrefix,
331
+ name: request.name,
332
+ product_plan: request.productPlan,
333
+ ...resolveOneOf([{
334
+ param: "twins_graphite_config",
335
+ value: request.twinsGraphiteConfig !== void 0 ? marshalHubTwinsGraphiteConfig(request.twinsGraphiteConfig, defaults) : void 0
336
+ }])
337
+ });
338
+ const marshalUpdateRouteRequestDatabaseConfig = (request, defaults) => ({
339
+ dbname: request.dbname,
340
+ engine: request.engine,
341
+ host: request.host,
342
+ password: request.password,
343
+ port: request.port,
344
+ query: request.query,
345
+ username: request.username
346
+ });
347
+ const marshalUpdateRouteRequestRestConfig = (request, defaults) => ({
348
+ headers: request.headers,
349
+ uri: request.uri,
350
+ verb: request.verb
351
+ });
352
+ const marshalUpdateRouteRequestS3Config = (request, defaults) => ({
353
+ bucket_name: request.bucketName,
354
+ bucket_region: request.bucketRegion,
355
+ object_prefix: request.objectPrefix,
356
+ strategy: request.strategy
357
+ });
358
+ const marshalUpdateRouteRequest = (request, defaults) => ({
359
+ name: request.name,
360
+ topic: request.topic,
361
+ ...resolveOneOf([
362
+ {
363
+ param: "s3_config",
364
+ value: request.s3Config !== void 0 ? marshalUpdateRouteRequestS3Config(request.s3Config, defaults) : void 0
365
+ },
366
+ {
367
+ param: "db_config",
368
+ value: request.dbConfig !== void 0 ? marshalUpdateRouteRequestDatabaseConfig(request.dbConfig, defaults) : void 0
369
+ },
370
+ {
371
+ param: "rest_config",
372
+ value: request.restConfig !== void 0 ? marshalUpdateRouteRequestRestConfig(request.restConfig, defaults) : void 0
373
+ }
374
+ ])
375
+ });
376
+ //#endregion
377
+ export { marshalCreateDeviceRequest, marshalCreateHubRequest, marshalCreateNetworkRequest, marshalCreateRouteRequest, marshalPatchTwinDocumentRequest, marshalPutTwinDocumentRequest, marshalSetDeviceCertificateRequest, marshalSetHubCARequest, marshalUpdateDeviceRequest, marshalUpdateHubRequest, marshalUpdateRouteRequest, unmarshalCreateDeviceResponse, unmarshalCreateNetworkResponse, unmarshalDevice, unmarshalGetDeviceCertificateResponse, unmarshalGetDeviceMetricsResponse, unmarshalGetHubCAResponse, unmarshalGetHubMetricsResponse, unmarshalHub, unmarshalListDevicesResponse, unmarshalListHubsResponse, unmarshalListNetworksResponse, unmarshalListRoutesResponse, unmarshalListTwinDocumentsResponse, unmarshalNetwork, unmarshalRenewDeviceCertificateResponse, unmarshalRoute, unmarshalSetDeviceCertificateResponse, unmarshalTwinDocument };
@@ -0,0 +1,145 @@
1
+ export declare const queriesMetadata: {
2
+ readonly namespace: 'iot';
3
+ readonly version: 'v1';
4
+ readonly folderName: 'iotv1';
5
+ readonly services: readonly [{
6
+ readonly apiClass: 'API';
7
+ readonly methods: readonly [{
8
+ readonly methodName: 'listHubs';
9
+ readonly protoName: 'ListHubs';
10
+ readonly paramsType: 'ListHubsRequest';
11
+ readonly returnType: 'ListHubsResponse';
12
+ readonly isList: true;
13
+ readonly paginationType: 'offset';
14
+ readonly pageParamKey: 'page';
15
+ readonly listItemType: 'Hub';
16
+ readonly isPrivate: false;
17
+ readonly description: '"';
18
+ }, {
19
+ readonly methodName: 'getHub';
20
+ readonly protoName: 'GetHub';
21
+ readonly paramsType: 'GetHubRequest';
22
+ readonly returnType: 'Hub';
23
+ readonly isList: false;
24
+ readonly paginationType: 'none';
25
+ readonly isPrivate: false;
26
+ readonly description: '"';
27
+ readonly hasWaiter: true;
28
+ }, {
29
+ readonly methodName: 'getHubMetrics';
30
+ readonly protoName: 'GetHubMetrics';
31
+ readonly paramsType: 'GetHubMetricsRequest';
32
+ readonly returnType: 'GetHubMetricsResponse';
33
+ readonly isList: false;
34
+ readonly paginationType: 'none';
35
+ readonly isPrivate: false;
36
+ readonly description: '"';
37
+ }, {
38
+ readonly methodName: 'getHubCA';
39
+ readonly protoName: 'GetHubCA';
40
+ readonly paramsType: 'GetHubCARequest';
41
+ readonly returnType: 'GetHubCAResponse';
42
+ readonly isList: false;
43
+ readonly paginationType: 'none';
44
+ readonly isPrivate: false;
45
+ readonly description: '"';
46
+ }, {
47
+ readonly methodName: 'listDevices';
48
+ readonly protoName: 'ListDevices';
49
+ readonly paramsType: 'ListDevicesRequest';
50
+ readonly returnType: 'ListDevicesResponse';
51
+ readonly isList: true;
52
+ readonly paginationType: 'offset';
53
+ readonly pageParamKey: 'page';
54
+ readonly listItemType: 'Device';
55
+ readonly isPrivate: false;
56
+ readonly description: '"';
57
+ }, {
58
+ readonly methodName: 'getDevice';
59
+ readonly protoName: 'GetDevice';
60
+ readonly paramsType: 'GetDeviceRequest';
61
+ readonly returnType: 'Device';
62
+ readonly isList: false;
63
+ readonly paginationType: 'none';
64
+ readonly isPrivate: false;
65
+ readonly description: '"';
66
+ }, {
67
+ readonly methodName: 'getDeviceCertificate';
68
+ readonly protoName: 'GetDeviceCertificate';
69
+ readonly paramsType: 'GetDeviceCertificateRequest';
70
+ readonly returnType: 'GetDeviceCertificateResponse';
71
+ readonly isList: false;
72
+ readonly paginationType: 'none';
73
+ readonly isPrivate: false;
74
+ readonly description: '"';
75
+ }, {
76
+ readonly methodName: 'getDeviceMetrics';
77
+ readonly protoName: 'GetDeviceMetrics';
78
+ readonly paramsType: 'GetDeviceMetricsRequest';
79
+ readonly returnType: 'GetDeviceMetricsResponse';
80
+ readonly isList: false;
81
+ readonly paginationType: 'none';
82
+ readonly isPrivate: false;
83
+ readonly description: '"';
84
+ }, {
85
+ readonly methodName: 'listRoutes';
86
+ readonly protoName: 'ListRoutes';
87
+ readonly paramsType: 'ListRoutesRequest';
88
+ readonly returnType: 'ListRoutesResponse';
89
+ readonly isList: true;
90
+ readonly paginationType: 'offset';
91
+ readonly pageParamKey: 'page';
92
+ readonly listItemType: 'RouteSummary';
93
+ readonly isPrivate: false;
94
+ readonly description: '"';
95
+ }, {
96
+ readonly methodName: 'getRoute';
97
+ readonly protoName: 'GetRoute';
98
+ readonly paramsType: 'GetRouteRequest';
99
+ readonly returnType: 'Route';
100
+ readonly isList: false;
101
+ readonly paginationType: 'none';
102
+ readonly isPrivate: false;
103
+ readonly description: '"';
104
+ }, {
105
+ readonly methodName: 'listNetworks';
106
+ readonly protoName: 'ListNetworks';
107
+ readonly paramsType: 'ListNetworksRequest';
108
+ readonly returnType: 'ListNetworksResponse';
109
+ readonly isList: true;
110
+ readonly paginationType: 'offset';
111
+ readonly pageParamKey: 'page';
112
+ readonly listItemType: 'Network';
113
+ readonly isPrivate: false;
114
+ readonly description: '"';
115
+ }, {
116
+ readonly methodName: 'getNetwork';
117
+ readonly protoName: 'GetNetwork';
118
+ readonly paramsType: 'GetNetworkRequest';
119
+ readonly returnType: 'Network';
120
+ readonly isList: false;
121
+ readonly paginationType: 'none';
122
+ readonly isPrivate: false;
123
+ readonly description: '"';
124
+ }, {
125
+ readonly methodName: 'getTwinDocument';
126
+ readonly protoName: 'GetTwinDocument';
127
+ readonly paramsType: 'GetTwinDocumentRequest';
128
+ readonly returnType: 'TwinDocument';
129
+ readonly isList: false;
130
+ readonly paginationType: 'none';
131
+ readonly isPrivate: false;
132
+ readonly description: '"';
133
+ }, {
134
+ readonly methodName: 'listTwinDocuments';
135
+ readonly protoName: 'ListTwinDocuments';
136
+ readonly paramsType: 'ListTwinDocumentsRequest';
137
+ readonly returnType: 'ListTwinDocumentsResponse';
138
+ readonly isList: false;
139
+ readonly paginationType: 'none';
140
+ readonly isPrivate: false;
141
+ readonly description: '"';
142
+ }];
143
+ }];
144
+ };
145
+ export type QueriesMetadata = typeof queriesMetadata;