From 79cb9c0701305904be9af4c725d8a65edf0c0ebd Mon Sep 17 00:00:00 2001 From: ArduinoBot Date: Mon, 1 Jul 2024 15:10:54 +0000 Subject: [PATCH] Regenerate client from commit 3110ee5 of spec repo --- .apigentools-info | 4 +- .openapi-generator/FILES | 15 ++ package.json | 2 +- src/ApiClient.js | 2 +- src/api/DashboardsV2Api.js | 2 +- src/api/DevicesV2Api.js | 2 +- src/api/DevicesV2CertsApi.js | 2 +- src/api/DevicesV2OtaApi.js | 2 +- src/api/DevicesV2PassApi.js | 2 +- src/api/DevicesV2TagsApi.js | 2 +- src/api/LoraDevicesV1Api.js | 2 +- src/api/LoraFreqPlanV1Api.js | 2 +- src/api/PropertiesV2Api.js | 2 +- src/api/SeriesV2Api.js | 51 +++- src/api/ThingsV2Api.js | 2 +- src/api/ThingsV2TagsApi.js | 2 +- src/index.js | 37 ++- src/model/ArduinoCompressedv2.js | 2 +- src/model/ArduinoDashboardowner.js | 2 +- src/model/ArduinoDashboardshare.js | 2 +- src/model/ArduinoDashboardv2.js | 2 +- src/model/ArduinoDashboardv2template.js | 15 +- src/model/ArduinoDevicev2.js | 16 +- src/model/ArduinoDevicev2Cert.js | 2 +- src/model/ArduinoDevicev2EventProperties.js | 2 +- src/model/ArduinoDevicev2Otaupload.js | 2 +- src/model/ArduinoDevicev2Pass.js | 2 +- src/model/ArduinoDevicev2SimpleProperties.js | 2 +- src/model/ArduinoDevicev2StatusEvent.js | 2 +- src/model/ArduinoDevicev2StatusEvents.js | 2 +- src/model/ArduinoDevicev2Webhook.js | 2 +- src/model/ArduinoDevicev2properties.js | 2 +- src/model/ArduinoDevicev2propertyvalue.js | 2 +- .../ArduinoDevicev2propertyvalueValue.js | 2 +- ...inoDevicev2propertyvalueValueStatistics.js | 2 +- src/model/ArduinoDevicev2propertyvalues.js | 2 +- ...oDevicev2propertyvaluesLastEvaluatedKey.js | 2 +- src/model/ArduinoDevicev2templatedevice.js | 102 ++++++++ src/model/ArduinoLinkedvariable.js | 2 +- src/model/ArduinoLoradevicev1.js | 2 +- src/model/ArduinoLorafreqplansv1.js | 2 +- src/model/ArduinoLorafreqplanv1.js | 2 +- src/model/ArduinoProperty.js | 2 +- src/model/ArduinoSeriesBatch.js | 2 +- src/model/ArduinoSeriesBatchSampled.js | 115 +++++++++ src/model/ArduinoSeriesRawBatch.js | 2 +- src/model/ArduinoSeriesRawBatchLastvalue.js | 2 +- .../ArduinoSeriesRawLastValueResponse.js | 2 +- src/model/ArduinoSeriesRawResponse.js | 2 +- src/model/ArduinoSeriesResponse.js | 2 +- src/model/ArduinoSeriesSampledResponse.js | 220 ++++++++++++++++++ src/model/ArduinoTags.js | 2 +- src/model/ArduinoTemplateproperty.js | 15 +- src/model/ArduinoTemplatevariable.js | 2 +- src/model/ArduinoThing.js | 42 +++- src/model/ArduinoThingtemplate.js | 69 ++++-- src/model/ArduinoTimeseriesmedia.js | 2 +- src/model/ArduinoTimezone.js | 2 +- src/model/ArduinoVariableslinks.js | 2 +- src/model/ArduinoWidgetv2.js | 21 +- src/model/ArduinoWidgetv2template.js | 2 +- src/model/BatchLastValueRequestsMediaV1.js | 2 +- .../BatchQueryRawLastValueRequestMediaV1.js | 2 +- src/model/BatchQueryRawRequestMediaV1.js | 2 +- src/model/BatchQueryRawRequestsMediaV1.js | 2 +- .../BatchQueryRawResponseSeriesMediaV1.js | 2 +- src/model/BatchQueryRequestMediaV1.js | 2 +- src/model/BatchQueryRequestsMediaV1.js | 2 +- src/model/BatchQuerySampledRequestMediaV1.js | 133 +++++++++++ src/model/BatchQuerySampledRequestsMediaV1.js | 114 +++++++++ src/model/CheckDevicesV2PassPayload.js | 2 +- src/model/Clone.js | 2 +- src/model/CreateDevicesV2CertsPayload.js | 2 +- src/model/CreateDevicesV2Payload.js | 16 +- src/model/CreateLoraDevicesV1Payload.js | 2 +- src/model/Dashboardshare.js | 2 +- src/model/Dashboardv2.js | 2 +- src/model/Devicev2.js | 16 +- src/model/Devicev2Cert.js | 2 +- src/model/Devicev2Otabinaryurl.js | 2 +- src/model/Devicev2Otaurlpyalod.js | 2 +- src/model/Devicev2Pass.js | 2 +- src/model/Error.js | 2 +- src/model/HistoricDataRequest.js | 2 +- src/model/Override.js | 2 +- src/model/PropertiesValue.js | 2 +- src/model/PropertiesValues.js | 2 +- src/model/Property.js | 2 +- src/model/PropertyValue.js | 2 +- src/model/Sharerequest.js | 2 +- src/model/Tag.js | 2 +- src/model/ThingClone.js | 2 +- src/model/ThingCreate.js | 42 +++- src/model/ThingSketch.js | 2 +- src/model/ThingUpdate.js | 42 +++- src/model/TimeseriesDataPoint.js | 2 +- src/model/UpdateSketch.js | 2 +- src/model/Widget.js | 2 +- src/model/Widgetlink.js | 2 +- 99 files changed, 1117 insertions(+), 128 deletions(-) create mode 100644 src/model/ArduinoDevicev2templatedevice.js create mode 100644 src/model/ArduinoSeriesBatchSampled.js create mode 100644 src/model/ArduinoSeriesSampledResponse.js create mode 100644 src/model/BatchQuerySampledRequestMediaV1.js create mode 100644 src/model/BatchQuerySampledRequestsMediaV1.js diff --git a/.apigentools-info b/.apigentools-info index efc770b..3f21027 100644 --- a/.apigentools-info +++ b/.apigentools-info @@ -4,8 +4,8 @@ "spec_versions": { "v2": { "apigentools_version": "1.1.0", - "regenerated": "2024-04-16 08:17:19.461374", - "spec_repo_commit": "28842c9" + "regenerated": "2024-07-01 15:09:13.083076", + "spec_repo_commit": "3110ee5" } } } \ No newline at end of file diff --git a/.openapi-generator/FILES b/.openapi-generator/FILES index 104b62b..fcb7ba1 100644 --- a/.openapi-generator/FILES +++ b/.openapi-generator/FILES @@ -22,17 +22,20 @@ docs/ArduinoDevicev2propertyvalueValue.md docs/ArduinoDevicev2propertyvalueValueStatistics.md docs/ArduinoDevicev2propertyvalues.md docs/ArduinoDevicev2propertyvaluesLastEvaluatedKey.md +docs/ArduinoDevicev2templatedevice.md docs/ArduinoLinkedvariable.md docs/ArduinoLoradevicev1.md docs/ArduinoLorafreqplansv1.md docs/ArduinoLorafreqplanv1.md docs/ArduinoProperty.md docs/ArduinoSeriesBatch.md +docs/ArduinoSeriesBatchSampled.md docs/ArduinoSeriesRawBatch.md docs/ArduinoSeriesRawBatchLastvalue.md docs/ArduinoSeriesRawLastValueResponse.md docs/ArduinoSeriesRawResponse.md docs/ArduinoSeriesResponse.md +docs/ArduinoSeriesSampledResponse.md docs/ArduinoTags.md docs/ArduinoTemplateproperty.md docs/ArduinoTemplatevariable.md @@ -50,6 +53,8 @@ docs/BatchQueryRawRequestsMediaV1.md docs/BatchQueryRawResponseSeriesMediaV1.md docs/BatchQueryRequestMediaV1.md docs/BatchQueryRequestsMediaV1.md +docs/BatchQuerySampledRequestMediaV1.md +docs/BatchQuerySampledRequestsMediaV1.md docs/CheckDevicesV2PassPayload.md docs/Clone.md docs/CreateDevicesV2CertsPayload.md @@ -128,17 +133,20 @@ src/model/ArduinoDevicev2propertyvalueValue.js src/model/ArduinoDevicev2propertyvalueValueStatistics.js src/model/ArduinoDevicev2propertyvalues.js src/model/ArduinoDevicev2propertyvaluesLastEvaluatedKey.js +src/model/ArduinoDevicev2templatedevice.js src/model/ArduinoLinkedvariable.js src/model/ArduinoLoradevicev1.js src/model/ArduinoLorafreqplansv1.js src/model/ArduinoLorafreqplanv1.js src/model/ArduinoProperty.js src/model/ArduinoSeriesBatch.js +src/model/ArduinoSeriesBatchSampled.js src/model/ArduinoSeriesRawBatch.js src/model/ArduinoSeriesRawBatchLastvalue.js src/model/ArduinoSeriesRawLastValueResponse.js src/model/ArduinoSeriesRawResponse.js src/model/ArduinoSeriesResponse.js +src/model/ArduinoSeriesSampledResponse.js src/model/ArduinoTags.js src/model/ArduinoTemplateproperty.js src/model/ArduinoTemplatevariable.js @@ -156,6 +164,8 @@ src/model/BatchQueryRawRequestsMediaV1.js src/model/BatchQueryRawResponseSeriesMediaV1.js src/model/BatchQueryRequestMediaV1.js src/model/BatchQueryRequestsMediaV1.js +src/model/BatchQuerySampledRequestMediaV1.js +src/model/BatchQuerySampledRequestsMediaV1.js src/model/CheckDevicesV2PassPayload.js src/model/Clone.js src/model/CreateDevicesV2CertsPayload.js @@ -217,17 +227,20 @@ test/model/ArduinoDevicev2propertyvalueValue.spec.js test/model/ArduinoDevicev2propertyvalueValueStatistics.spec.js test/model/ArduinoDevicev2propertyvalues.spec.js test/model/ArduinoDevicev2propertyvaluesLastEvaluatedKey.spec.js +test/model/ArduinoDevicev2templatedevice.spec.js test/model/ArduinoLinkedvariable.spec.js test/model/ArduinoLoradevicev1.spec.js test/model/ArduinoLorafreqplansv1.spec.js test/model/ArduinoLorafreqplanv1.spec.js test/model/ArduinoProperty.spec.js test/model/ArduinoSeriesBatch.spec.js +test/model/ArduinoSeriesBatchSampled.spec.js test/model/ArduinoSeriesRawBatch.spec.js test/model/ArduinoSeriesRawBatchLastvalue.spec.js test/model/ArduinoSeriesRawLastValueResponse.spec.js test/model/ArduinoSeriesRawResponse.spec.js test/model/ArduinoSeriesResponse.spec.js +test/model/ArduinoSeriesSampledResponse.spec.js test/model/ArduinoTags.spec.js test/model/ArduinoTemplateproperty.spec.js test/model/ArduinoTemplatevariable.spec.js @@ -245,6 +258,8 @@ test/model/BatchQueryRawRequestsMediaV1.spec.js test/model/BatchQueryRawResponseSeriesMediaV1.spec.js test/model/BatchQueryRequestMediaV1.spec.js test/model/BatchQueryRequestsMediaV1.spec.js +test/model/BatchQuerySampledRequestMediaV1.spec.js +test/model/BatchQuerySampledRequestsMediaV1.spec.js test/model/CheckDevicesV2PassPayload.spec.js test/model/Clone.spec.js test/model/CreateDevicesV2CertsPayload.spec.js diff --git a/package.json b/package.json index bd4fef6..492ad97 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "@arduino/arduino-iot-client", - "version": "2.0.2", + "version": "2.0.3", "description": " Provides a set of endpoints to manage Arduino IoT Cloud **Devices**, **Things**, **Properties** and **Timeseries**. This API can be called just with any HTTP Client, or using one of these clients: * [Javascript NPM package](https://www.npmjs.com/package/@arduino/arduino-iot-client) * [Python PYPI Package](https://pypi.org/project/arduino-iot-client/) * [Golang Module](https://github.com/arduino/iot-client-go)", "license": "GPLv3", "main": "dist/index.js", diff --git a/src/ApiClient.js b/src/ApiClient.js index 16c99e8..8164058 100644 --- a/src/ApiClient.js +++ b/src/ApiClient.js @@ -17,7 +17,7 @@ import querystring from "querystring"; /** * @module ApiClient -* @version 2.0.2 +* @version 2.0.3 */ /** diff --git a/src/api/DashboardsV2Api.js b/src/api/DashboardsV2Api.js index 72f5d8c..a52169a 100644 --- a/src/api/DashboardsV2Api.js +++ b/src/api/DashboardsV2Api.js @@ -27,7 +27,7 @@ import Widgetlink from '../model/Widgetlink'; /** * DashboardsV2 service. * @module api/DashboardsV2Api -* @version 2.0.2 +* @version 2.0.3 */ export default class DashboardsV2Api { diff --git a/src/api/DevicesV2Api.js b/src/api/DevicesV2Api.js index 25214ba..8564929 100644 --- a/src/api/DevicesV2Api.js +++ b/src/api/DevicesV2Api.js @@ -26,7 +26,7 @@ import PropertiesValues from '../model/PropertiesValues'; /** * DevicesV2 service. * @module api/DevicesV2Api -* @version 2.0.2 +* @version 2.0.3 */ export default class DevicesV2Api { diff --git a/src/api/DevicesV2CertsApi.js b/src/api/DevicesV2CertsApi.js index d7f1bd7..a94186c 100644 --- a/src/api/DevicesV2CertsApi.js +++ b/src/api/DevicesV2CertsApi.js @@ -21,7 +21,7 @@ import Error from '../model/Error'; /** * DevicesV2Certs service. * @module api/DevicesV2CertsApi -* @version 2.0.2 +* @version 2.0.3 */ export default class DevicesV2CertsApi { diff --git a/src/api/DevicesV2OtaApi.js b/src/api/DevicesV2OtaApi.js index 9a7f42e..4fd91e1 100644 --- a/src/api/DevicesV2OtaApi.js +++ b/src/api/DevicesV2OtaApi.js @@ -21,7 +21,7 @@ import Error from '../model/Error'; /** * DevicesV2Ota service. * @module api/DevicesV2OtaApi -* @version 2.0.2 +* @version 2.0.3 */ export default class DevicesV2OtaApi { diff --git a/src/api/DevicesV2PassApi.js b/src/api/DevicesV2PassApi.js index 96c42c1..c332f47 100644 --- a/src/api/DevicesV2PassApi.js +++ b/src/api/DevicesV2PassApi.js @@ -21,7 +21,7 @@ import Error from '../model/Error'; /** * DevicesV2Pass service. * @module api/DevicesV2PassApi -* @version 2.0.2 +* @version 2.0.3 */ export default class DevicesV2PassApi { diff --git a/src/api/DevicesV2TagsApi.js b/src/api/DevicesV2TagsApi.js index 1f43a26..f0128ae 100644 --- a/src/api/DevicesV2TagsApi.js +++ b/src/api/DevicesV2TagsApi.js @@ -20,7 +20,7 @@ import Tag from '../model/Tag'; /** * DevicesV2Tags service. * @module api/DevicesV2TagsApi -* @version 2.0.2 +* @version 2.0.3 */ export default class DevicesV2TagsApi { diff --git a/src/api/LoraDevicesV1Api.js b/src/api/LoraDevicesV1Api.js index ee914b6..3f3aa3d 100644 --- a/src/api/LoraDevicesV1Api.js +++ b/src/api/LoraDevicesV1Api.js @@ -19,7 +19,7 @@ import CreateLoraDevicesV1Payload from '../model/CreateLoraDevicesV1Payload'; /** * LoraDevicesV1 service. * @module api/LoraDevicesV1Api -* @version 2.0.2 +* @version 2.0.3 */ export default class LoraDevicesV1Api { diff --git a/src/api/LoraFreqPlanV1Api.js b/src/api/LoraFreqPlanV1Api.js index a206539..6425891 100644 --- a/src/api/LoraFreqPlanV1Api.js +++ b/src/api/LoraFreqPlanV1Api.js @@ -19,7 +19,7 @@ import Error from '../model/Error'; /** * LoraFreqPlanV1 service. * @module api/LoraFreqPlanV1Api -* @version 2.0.2 +* @version 2.0.3 */ export default class LoraFreqPlanV1Api { diff --git a/src/api/PropertiesV2Api.js b/src/api/PropertiesV2Api.js index c6f4774..9327b82 100644 --- a/src/api/PropertiesV2Api.js +++ b/src/api/PropertiesV2Api.js @@ -22,7 +22,7 @@ import PropertyValue from '../model/PropertyValue'; /** * PropertiesV2 service. * @module api/PropertiesV2Api -* @version 2.0.2 +* @version 2.0.3 */ export default class PropertiesV2Api { diff --git a/src/api/SeriesV2Api.js b/src/api/SeriesV2Api.js index 83c0c23..ccda160 100644 --- a/src/api/SeriesV2Api.js +++ b/src/api/SeriesV2Api.js @@ -14,18 +14,20 @@ import ApiClient from "../ApiClient"; import ArduinoSeriesBatch from '../model/ArduinoSeriesBatch'; +import ArduinoSeriesBatchSampled from '../model/ArduinoSeriesBatchSampled'; import ArduinoSeriesRawBatch from '../model/ArduinoSeriesRawBatch'; import ArduinoSeriesRawBatchLastvalue from '../model/ArduinoSeriesRawBatchLastvalue'; import BatchLastValueRequestsMediaV1 from '../model/BatchLastValueRequestsMediaV1'; import BatchQueryRawRequestsMediaV1 from '../model/BatchQueryRawRequestsMediaV1'; import BatchQueryRequestsMediaV1 from '../model/BatchQueryRequestsMediaV1'; +import BatchQuerySampledRequestsMediaV1 from '../model/BatchQuerySampledRequestsMediaV1'; import Error from '../model/Error'; import HistoricDataRequest from '../model/HistoricDataRequest'; /** * SeriesV2 service. * @module api/SeriesV2Api -* @version 2.0.2 +* @version 2.0.3 */ export default class SeriesV2Api { @@ -183,6 +185,53 @@ export default class SeriesV2Api { } + /** + * batch_query_sampling series_v2 + * Returns a batch of time-series sampled samples. To be used for types that does not support mathematic aggregation. Types supported: strings, complex types. + * @param {module:model/BatchQuerySampledRequestsMediaV1} batchQuerySampledRequestsMediaV1 + * @return {Promise} a {@link https://www.promisejs.org/|Promise}, with an object containing data of type {@link module:model/ArduinoSeriesBatchSampled} and HTTP response + */ + seriesV2BatchQuerySamplingWithHttpInfo(batchQuerySampledRequestsMediaV1) { + let postBody = batchQuerySampledRequestsMediaV1; + // verify the required parameter 'batchQuerySampledRequestsMediaV1' is set + if (batchQuerySampledRequestsMediaV1 === undefined || batchQuerySampledRequestsMediaV1 === null) { + throw new Error("Missing the required parameter 'batchQuerySampledRequestsMediaV1' when calling seriesV2BatchQuerySampling"); + } + + let pathParams = { + }; + let queryParams = { + }; + let headerParams = { + }; + let formParams = { + }; + + let authNames = ['oauth2']; + let contentTypes = ['application/json', 'application/x-www-form-urlencoded']; + let accepts = ['application/vnd.arduino.series.batch.sampled+json', 'application/vnd.goa.error+json']; + let returnType = ArduinoSeriesBatchSampled; + return this.apiClient.callApi( + '/v2/series/batch_query_sampling', 'POST', + pathParams, queryParams, headerParams, formParams, postBody, + authNames, contentTypes, accepts, returnType, null + ); + } + + /** + * batch_query_sampling series_v2 + * Returns a batch of time-series sampled samples. To be used for types that does not support mathematic aggregation. Types supported: strings, complex types. + * @param {module:model/BatchQuerySampledRequestsMediaV1} batchQuerySampledRequestsMediaV1 + * @return {Promise} a {@link https://www.promisejs.org/|Promise}, with data of type {@link module:model/ArduinoSeriesBatchSampled} + */ + seriesV2BatchQuerySampling(batchQuerySampledRequestsMediaV1) { + return this.seriesV2BatchQuerySamplingWithHttpInfo(batchQuerySampledRequestsMediaV1) + .then(function(response_and_data) { + return response_and_data.data; + }); + } + + /** * historic_data series_v2 * Request sending of historical data of properties by email diff --git a/src/api/ThingsV2Api.js b/src/api/ThingsV2Api.js index 8436a25..444d941 100644 --- a/src/api/ThingsV2Api.js +++ b/src/api/ThingsV2Api.js @@ -25,7 +25,7 @@ import UpdateSketch from '../model/UpdateSketch'; /** * ThingsV2 service. * @module api/ThingsV2Api -* @version 2.0.2 +* @version 2.0.3 */ export default class ThingsV2Api { diff --git a/src/api/ThingsV2TagsApi.js b/src/api/ThingsV2TagsApi.js index 8806245..e397e41 100644 --- a/src/api/ThingsV2TagsApi.js +++ b/src/api/ThingsV2TagsApi.js @@ -20,7 +20,7 @@ import Tag from '../model/Tag'; /** * ThingsV2Tags service. * @module api/ThingsV2TagsApi -* @version 2.0.2 +* @version 2.0.3 */ export default class ThingsV2TagsApi { diff --git a/src/index.js b/src/index.js index 6bd548f..12004ca 100644 --- a/src/index.js +++ b/src/index.js @@ -33,17 +33,20 @@ import ArduinoDevicev2propertyvalueValue from './model/ArduinoDevicev2propertyva import ArduinoDevicev2propertyvalueValueStatistics from './model/ArduinoDevicev2propertyvalueValueStatistics'; import ArduinoDevicev2propertyvalues from './model/ArduinoDevicev2propertyvalues'; import ArduinoDevicev2propertyvaluesLastEvaluatedKey from './model/ArduinoDevicev2propertyvaluesLastEvaluatedKey'; +import ArduinoDevicev2templatedevice from './model/ArduinoDevicev2templatedevice'; import ArduinoLinkedvariable from './model/ArduinoLinkedvariable'; import ArduinoLoradevicev1 from './model/ArduinoLoradevicev1'; import ArduinoLorafreqplansv1 from './model/ArduinoLorafreqplansv1'; import ArduinoLorafreqplanv1 from './model/ArduinoLorafreqplanv1'; import ArduinoProperty from './model/ArduinoProperty'; import ArduinoSeriesBatch from './model/ArduinoSeriesBatch'; +import ArduinoSeriesBatchSampled from './model/ArduinoSeriesBatchSampled'; import ArduinoSeriesRawBatch from './model/ArduinoSeriesRawBatch'; import ArduinoSeriesRawBatchLastvalue from './model/ArduinoSeriesRawBatchLastvalue'; import ArduinoSeriesRawLastValueResponse from './model/ArduinoSeriesRawLastValueResponse'; import ArduinoSeriesRawResponse from './model/ArduinoSeriesRawResponse'; import ArduinoSeriesResponse from './model/ArduinoSeriesResponse'; +import ArduinoSeriesSampledResponse from './model/ArduinoSeriesSampledResponse'; import ArduinoTags from './model/ArduinoTags'; import ArduinoTemplateproperty from './model/ArduinoTemplateproperty'; import ArduinoTemplatevariable from './model/ArduinoTemplatevariable'; @@ -61,6 +64,8 @@ import BatchQueryRawRequestsMediaV1 from './model/BatchQueryRawRequestsMediaV1'; import BatchQueryRawResponseSeriesMediaV1 from './model/BatchQueryRawResponseSeriesMediaV1'; import BatchQueryRequestMediaV1 from './model/BatchQueryRequestMediaV1'; import BatchQueryRequestsMediaV1 from './model/BatchQueryRequestsMediaV1'; +import BatchQuerySampledRequestMediaV1 from './model/BatchQuerySampledRequestMediaV1'; +import BatchQuerySampledRequestsMediaV1 from './model/BatchQuerySampledRequestsMediaV1'; import CheckDevicesV2PassPayload from './model/CheckDevicesV2PassPayload'; import Clone from './model/Clone'; import CreateDevicesV2CertsPayload from './model/CreateDevicesV2CertsPayload'; @@ -133,7 +138,7 @@ import ThingsV2TagsApi from './api/ThingsV2TagsApi'; * *

* @module index -* @version 2.0.2 +* @version 2.0.3 */ export { /** @@ -262,6 +267,12 @@ export { */ ArduinoDevicev2propertyvaluesLastEvaluatedKey, + /** + * The ArduinoDevicev2templatedevice model constructor. + * @property {module:model/ArduinoDevicev2templatedevice} + */ + ArduinoDevicev2templatedevice, + /** * The ArduinoLinkedvariable model constructor. * @property {module:model/ArduinoLinkedvariable} @@ -298,6 +309,12 @@ export { */ ArduinoSeriesBatch, + /** + * The ArduinoSeriesBatchSampled model constructor. + * @property {module:model/ArduinoSeriesBatchSampled} + */ + ArduinoSeriesBatchSampled, + /** * The ArduinoSeriesRawBatch model constructor. * @property {module:model/ArduinoSeriesRawBatch} @@ -328,6 +345,12 @@ export { */ ArduinoSeriesResponse, + /** + * The ArduinoSeriesSampledResponse model constructor. + * @property {module:model/ArduinoSeriesSampledResponse} + */ + ArduinoSeriesSampledResponse, + /** * The ArduinoTags model constructor. * @property {module:model/ArduinoTags} @@ -430,6 +453,18 @@ export { */ BatchQueryRequestsMediaV1, + /** + * The BatchQuerySampledRequestMediaV1 model constructor. + * @property {module:model/BatchQuerySampledRequestMediaV1} + */ + BatchQuerySampledRequestMediaV1, + + /** + * The BatchQuerySampledRequestsMediaV1 model constructor. + * @property {module:model/BatchQuerySampledRequestsMediaV1} + */ + BatchQuerySampledRequestsMediaV1, + /** * The CheckDevicesV2PassPayload model constructor. * @property {module:model/CheckDevicesV2PassPayload} diff --git a/src/model/ArduinoCompressedv2.js b/src/model/ArduinoCompressedv2.js index c55b7e4..0851da6 100644 --- a/src/model/ArduinoCompressedv2.js +++ b/src/model/ArduinoCompressedv2.js @@ -16,7 +16,7 @@ import ApiClient from '../ApiClient'; /** * The ArduinoCompressedv2 model module. * @module model/ArduinoCompressedv2 - * @version 2.0.2 + * @version 2.0.3 */ class ArduinoCompressedv2 { /** diff --git a/src/model/ArduinoDashboardowner.js b/src/model/ArduinoDashboardowner.js index 4cccf26..2bf6386 100644 --- a/src/model/ArduinoDashboardowner.js +++ b/src/model/ArduinoDashboardowner.js @@ -16,7 +16,7 @@ import ApiClient from '../ApiClient'; /** * The ArduinoDashboardowner model module. * @module model/ArduinoDashboardowner - * @version 2.0.2 + * @version 2.0.3 */ class ArduinoDashboardowner { /** diff --git a/src/model/ArduinoDashboardshare.js b/src/model/ArduinoDashboardshare.js index c5c0081..a1aebc9 100644 --- a/src/model/ArduinoDashboardshare.js +++ b/src/model/ArduinoDashboardshare.js @@ -16,7 +16,7 @@ import ApiClient from '../ApiClient'; /** * The ArduinoDashboardshare model module. * @module model/ArduinoDashboardshare - * @version 2.0.2 + * @version 2.0.3 */ class ArduinoDashboardshare { /** diff --git a/src/model/ArduinoDashboardv2.js b/src/model/ArduinoDashboardv2.js index 5d2a9be..e1c02da 100644 --- a/src/model/ArduinoDashboardv2.js +++ b/src/model/ArduinoDashboardv2.js @@ -19,7 +19,7 @@ import ArduinoWidgetv2 from './ArduinoWidgetv2'; /** * The ArduinoDashboardv2 model module. * @module model/ArduinoDashboardv2 - * @version 2.0.2 + * @version 2.0.3 */ class ArduinoDashboardv2 { /** diff --git a/src/model/ArduinoDashboardv2template.js b/src/model/ArduinoDashboardv2template.js index e195dcc..7c3f41e 100644 --- a/src/model/ArduinoDashboardv2template.js +++ b/src/model/ArduinoDashboardv2template.js @@ -17,7 +17,7 @@ import ArduinoWidgetv2template from './ArduinoWidgetv2template'; /** * The ArduinoDashboardv2template model module. * @module model/ArduinoDashboardv2template - * @version 2.0.2 + * @version 2.0.3 */ class ArduinoDashboardv2template { /** @@ -51,6 +51,9 @@ class ArduinoDashboardv2template { if (data) { obj = obj || new ArduinoDashboardv2template(); + if (data.hasOwnProperty('id')) { + obj['id'] = ApiClient.convertToType(data['id'], 'String'); + } if (data.hasOwnProperty('name')) { obj['name'] = ApiClient.convertToType(data['name'], 'String'); } @@ -74,6 +77,10 @@ class ArduinoDashboardv2template { } } // ensure the json data is a string + if (data['id'] && !(typeof data['id'] === 'string' || data['id'] instanceof String)) { + throw new Error("Expected the field `id` to be a primitive type in the JSON string but got " + data['id']); + } + // ensure the json data is a string if (data['name'] && !(typeof data['name'] === 'string' || data['name'] instanceof String)) { throw new Error("Expected the field `name` to be a primitive type in the JSON string but got " + data['name']); } @@ -96,6 +103,12 @@ class ArduinoDashboardv2template { ArduinoDashboardv2template.RequiredProperties = ["name"]; +/** + * The friendly ID of the dashboard + * @member {String} id + */ +ArduinoDashboardv2template.prototype['id'] = undefined; + /** * The friendly name of the dashboard * @member {String} name diff --git a/src/model/ArduinoDevicev2.js b/src/model/ArduinoDevicev2.js index e524a31..a6b863e 100644 --- a/src/model/ArduinoDevicev2.js +++ b/src/model/ArduinoDevicev2.js @@ -19,7 +19,7 @@ import ArduinoThing from './ArduinoThing'; /** * The ArduinoDevicev2 model module. * @module model/ArduinoDevicev2 - * @version 2.0.2 + * @version 2.0.3 */ class ArduinoDevicev2 { /** @@ -430,7 +430,19 @@ ArduinoDevicev2['ConnectionTypeEnum'] = { * value: "lora" * @const */ - "lora": "lora" + "lora": "lora", + + /** + * value: "catm1" + * @const + */ + "catm1": "catm1", + + /** + * value: "cellular" + * @const + */ + "cellular": "cellular" }; diff --git a/src/model/ArduinoDevicev2Cert.js b/src/model/ArduinoDevicev2Cert.js index 0f4316f..191033e 100644 --- a/src/model/ArduinoDevicev2Cert.js +++ b/src/model/ArduinoDevicev2Cert.js @@ -17,7 +17,7 @@ import ArduinoCompressedv2 from './ArduinoCompressedv2'; /** * The ArduinoDevicev2Cert model module. * @module model/ArduinoDevicev2Cert - * @version 2.0.2 + * @version 2.0.3 */ class ArduinoDevicev2Cert { /** diff --git a/src/model/ArduinoDevicev2EventProperties.js b/src/model/ArduinoDevicev2EventProperties.js index e4dd151..f525b7f 100644 --- a/src/model/ArduinoDevicev2EventProperties.js +++ b/src/model/ArduinoDevicev2EventProperties.js @@ -17,7 +17,7 @@ import ArduinoDevicev2SimpleProperties from './ArduinoDevicev2SimpleProperties'; /** * The ArduinoDevicev2EventProperties model module. * @module model/ArduinoDevicev2EventProperties - * @version 2.0.2 + * @version 2.0.3 */ class ArduinoDevicev2EventProperties { /** diff --git a/src/model/ArduinoDevicev2Otaupload.js b/src/model/ArduinoDevicev2Otaupload.js index d088e56..e8fd995 100644 --- a/src/model/ArduinoDevicev2Otaupload.js +++ b/src/model/ArduinoDevicev2Otaupload.js @@ -16,7 +16,7 @@ import ApiClient from '../ApiClient'; /** * The ArduinoDevicev2Otaupload model module. * @module model/ArduinoDevicev2Otaupload - * @version 2.0.2 + * @version 2.0.3 */ class ArduinoDevicev2Otaupload { /** diff --git a/src/model/ArduinoDevicev2Pass.js b/src/model/ArduinoDevicev2Pass.js index 64d6ef6..d1d4ffa 100644 --- a/src/model/ArduinoDevicev2Pass.js +++ b/src/model/ArduinoDevicev2Pass.js @@ -16,7 +16,7 @@ import ApiClient from '../ApiClient'; /** * The ArduinoDevicev2Pass model module. * @module model/ArduinoDevicev2Pass - * @version 2.0.2 + * @version 2.0.3 */ class ArduinoDevicev2Pass { /** diff --git a/src/model/ArduinoDevicev2SimpleProperties.js b/src/model/ArduinoDevicev2SimpleProperties.js index 3139d11..83be2f3 100644 --- a/src/model/ArduinoDevicev2SimpleProperties.js +++ b/src/model/ArduinoDevicev2SimpleProperties.js @@ -16,7 +16,7 @@ import ApiClient from '../ApiClient'; /** * The ArduinoDevicev2SimpleProperties model module. * @module model/ArduinoDevicev2SimpleProperties - * @version 2.0.2 + * @version 2.0.3 */ class ArduinoDevicev2SimpleProperties { /** diff --git a/src/model/ArduinoDevicev2StatusEvent.js b/src/model/ArduinoDevicev2StatusEvent.js index 511d6d9..6865230 100644 --- a/src/model/ArduinoDevicev2StatusEvent.js +++ b/src/model/ArduinoDevicev2StatusEvent.js @@ -16,7 +16,7 @@ import ApiClient from '../ApiClient'; /** * The ArduinoDevicev2StatusEvent model module. * @module model/ArduinoDevicev2StatusEvent - * @version 2.0.2 + * @version 2.0.3 */ class ArduinoDevicev2StatusEvent { /** diff --git a/src/model/ArduinoDevicev2StatusEvents.js b/src/model/ArduinoDevicev2StatusEvents.js index 4318abd..51a797a 100644 --- a/src/model/ArduinoDevicev2StatusEvents.js +++ b/src/model/ArduinoDevicev2StatusEvents.js @@ -17,7 +17,7 @@ import ArduinoDevicev2StatusEvent from './ArduinoDevicev2StatusEvent'; /** * The ArduinoDevicev2StatusEvents model module. * @module model/ArduinoDevicev2StatusEvents - * @version 2.0.2 + * @version 2.0.3 */ class ArduinoDevicev2StatusEvents { /** diff --git a/src/model/ArduinoDevicev2Webhook.js b/src/model/ArduinoDevicev2Webhook.js index e25f584..0a603d2 100644 --- a/src/model/ArduinoDevicev2Webhook.js +++ b/src/model/ArduinoDevicev2Webhook.js @@ -16,7 +16,7 @@ import ApiClient from '../ApiClient'; /** * The ArduinoDevicev2Webhook model module. * @module model/ArduinoDevicev2Webhook - * @version 2.0.2 + * @version 2.0.3 */ class ArduinoDevicev2Webhook { /** diff --git a/src/model/ArduinoDevicev2properties.js b/src/model/ArduinoDevicev2properties.js index 3c775f8..1a1bd6e 100644 --- a/src/model/ArduinoDevicev2properties.js +++ b/src/model/ArduinoDevicev2properties.js @@ -17,7 +17,7 @@ import ArduinoProperty from './ArduinoProperty'; /** * The ArduinoDevicev2properties model module. * @module model/ArduinoDevicev2properties - * @version 2.0.2 + * @version 2.0.3 */ class ArduinoDevicev2properties { /** diff --git a/src/model/ArduinoDevicev2propertyvalue.js b/src/model/ArduinoDevicev2propertyvalue.js index e2f3641..6486502 100644 --- a/src/model/ArduinoDevicev2propertyvalue.js +++ b/src/model/ArduinoDevicev2propertyvalue.js @@ -17,7 +17,7 @@ import ArduinoDevicev2propertyvalueValue from './ArduinoDevicev2propertyvalueVal /** * The ArduinoDevicev2propertyvalue model module. * @module model/ArduinoDevicev2propertyvalue - * @version 2.0.2 + * @version 2.0.3 */ class ArduinoDevicev2propertyvalue { /** diff --git a/src/model/ArduinoDevicev2propertyvalueValue.js b/src/model/ArduinoDevicev2propertyvalueValue.js index 0aa574b..21ab996 100644 --- a/src/model/ArduinoDevicev2propertyvalueValue.js +++ b/src/model/ArduinoDevicev2propertyvalueValue.js @@ -17,7 +17,7 @@ import ArduinoDevicev2propertyvalueValueStatistics from './ArduinoDevicev2proper /** * The ArduinoDevicev2propertyvalueValue model module. * @module model/ArduinoDevicev2propertyvalueValue - * @version 2.0.2 + * @version 2.0.3 */ class ArduinoDevicev2propertyvalueValue { /** diff --git a/src/model/ArduinoDevicev2propertyvalueValueStatistics.js b/src/model/ArduinoDevicev2propertyvalueValueStatistics.js index 31e3ad6..6f937ab 100644 --- a/src/model/ArduinoDevicev2propertyvalueValueStatistics.js +++ b/src/model/ArduinoDevicev2propertyvalueValueStatistics.js @@ -16,7 +16,7 @@ import ApiClient from '../ApiClient'; /** * The ArduinoDevicev2propertyvalueValueStatistics model module. * @module model/ArduinoDevicev2propertyvalueValueStatistics - * @version 2.0.2 + * @version 2.0.3 */ class ArduinoDevicev2propertyvalueValueStatistics { /** diff --git a/src/model/ArduinoDevicev2propertyvalues.js b/src/model/ArduinoDevicev2propertyvalues.js index 5c7ec21..ab6cd9e 100644 --- a/src/model/ArduinoDevicev2propertyvalues.js +++ b/src/model/ArduinoDevicev2propertyvalues.js @@ -18,7 +18,7 @@ import ArduinoDevicev2propertyvaluesLastEvaluatedKey from './ArduinoDevicev2prop /** * The ArduinoDevicev2propertyvalues model module. * @module model/ArduinoDevicev2propertyvalues - * @version 2.0.2 + * @version 2.0.3 */ class ArduinoDevicev2propertyvalues { /** diff --git a/src/model/ArduinoDevicev2propertyvaluesLastEvaluatedKey.js b/src/model/ArduinoDevicev2propertyvaluesLastEvaluatedKey.js index e906de3..8691e56 100644 --- a/src/model/ArduinoDevicev2propertyvaluesLastEvaluatedKey.js +++ b/src/model/ArduinoDevicev2propertyvaluesLastEvaluatedKey.js @@ -16,7 +16,7 @@ import ApiClient from '../ApiClient'; /** * The ArduinoDevicev2propertyvaluesLastEvaluatedKey model module. * @module model/ArduinoDevicev2propertyvaluesLastEvaluatedKey - * @version 2.0.2 + * @version 2.0.3 */ class ArduinoDevicev2propertyvaluesLastEvaluatedKey { /** diff --git a/src/model/ArduinoDevicev2templatedevice.js b/src/model/ArduinoDevicev2templatedevice.js new file mode 100644 index 0000000..2013e94 --- /dev/null +++ b/src/model/ArduinoDevicev2templatedevice.js @@ -0,0 +1,102 @@ +/** + * Arduino IoT Cloud API + * Provides a set of endpoints to manage Arduino IoT Cloud **Devices**, **Things**, **Properties** and **Timeseries**. This API can be called just with any HTTP Client, or using one of these clients: * [Javascript NPM package](https://www.npmjs.com/package/@arduino/arduino-iot-client) * [Python PYPI Package](https://pypi.org/project/arduino-iot-client/) * [Golang Module](https://github.com/arduino/iot-client-go) + * + * The version of the OpenAPI document: 2.0 + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + * + */ + +import ApiClient from '../ApiClient'; + +/** + * The ArduinoDevicev2templatedevice model module. + * @module model/ArduinoDevicev2templatedevice + * @version 2.0.3 + */ +class ArduinoDevicev2templatedevice { + /** + * Constructs a new ArduinoDevicev2templatedevice. + * ArduinoDevicev2templatedevice media type (default view) + * @alias module:model/ArduinoDevicev2templatedevice + */ + constructor() { + + ArduinoDevicev2templatedevice.initialize(this); + } + + /** + * Initializes the fields of this object. + * This method is used by the constructors of any subclasses, in order to implement multiple inheritance (mix-ins). + * Only for internal use. + */ + static initialize(obj) { + } + + /** + * Constructs a ArduinoDevicev2templatedevice from a plain JavaScript object, optionally creating a new instance. + * Copies all relevant properties from data to obj if supplied or a new instance if not. + * @param {Object} data The plain JavaScript object bearing properties of interest. + * @param {module:model/ArduinoDevicev2templatedevice} obj Optional instance to populate. + * @return {module:model/ArduinoDevicev2templatedevice} The populated ArduinoDevicev2templatedevice instance. + */ + static constructFromObject(data, obj) { + if (data) { + obj = obj || new ArduinoDevicev2templatedevice(); + + if (data.hasOwnProperty('fqbn')) { + obj['fqbn'] = ApiClient.convertToType(data['fqbn'], 'String'); + } + if (data.hasOwnProperty('name')) { + obj['name'] = ApiClient.convertToType(data['name'], 'String'); + } + } + return obj; + } + + /** + * Validates the JSON data with respect to ArduinoDevicev2templatedevice. + * @param {Object} data The plain JavaScript object bearing properties of interest. + * @return {boolean} to indicate whether the JSON data is valid with respect to ArduinoDevicev2templatedevice. + */ + static validateJSON(data) { + // ensure the json data is a string + if (data['fqbn'] && !(typeof data['fqbn'] === 'string' || data['fqbn'] instanceof String)) { + throw new Error("Expected the field `fqbn` to be a primitive type in the JSON string but got " + data['fqbn']); + } + // ensure the json data is a string + if (data['name'] && !(typeof data['name'] === 'string' || data['name'] instanceof String)) { + throw new Error("Expected the field `name` to be a primitive type in the JSON string but got " + data['name']); + } + + return true; + } + + +} + + + +/** + * The device fqbn + * @member {String} fqbn + */ +ArduinoDevicev2templatedevice.prototype['fqbn'] = undefined; + +/** + * The device type name + * @member {String} name + */ +ArduinoDevicev2templatedevice.prototype['name'] = undefined; + + + + + + +export default ArduinoDevicev2templatedevice; + diff --git a/src/model/ArduinoLinkedvariable.js b/src/model/ArduinoLinkedvariable.js index c73928a..edf17f8 100644 --- a/src/model/ArduinoLinkedvariable.js +++ b/src/model/ArduinoLinkedvariable.js @@ -17,7 +17,7 @@ import ArduinoTimezone from './ArduinoTimezone'; /** * The ArduinoLinkedvariable model module. * @module model/ArduinoLinkedvariable - * @version 2.0.2 + * @version 2.0.3 */ class ArduinoLinkedvariable { /** diff --git a/src/model/ArduinoLoradevicev1.js b/src/model/ArduinoLoradevicev1.js index 246375b..ee6f924 100644 --- a/src/model/ArduinoLoradevicev1.js +++ b/src/model/ArduinoLoradevicev1.js @@ -16,7 +16,7 @@ import ApiClient from '../ApiClient'; /** * The ArduinoLoradevicev1 model module. * @module model/ArduinoLoradevicev1 - * @version 2.0.2 + * @version 2.0.3 */ class ArduinoLoradevicev1 { /** diff --git a/src/model/ArduinoLorafreqplansv1.js b/src/model/ArduinoLorafreqplansv1.js index fe10f1e..5f77211 100644 --- a/src/model/ArduinoLorafreqplansv1.js +++ b/src/model/ArduinoLorafreqplansv1.js @@ -17,7 +17,7 @@ import ArduinoLorafreqplanv1 from './ArduinoLorafreqplanv1'; /** * The ArduinoLorafreqplansv1 model module. * @module model/ArduinoLorafreqplansv1 - * @version 2.0.2 + * @version 2.0.3 */ class ArduinoLorafreqplansv1 { /** diff --git a/src/model/ArduinoLorafreqplanv1.js b/src/model/ArduinoLorafreqplanv1.js index 02f0ece..c878c98 100644 --- a/src/model/ArduinoLorafreqplanv1.js +++ b/src/model/ArduinoLorafreqplanv1.js @@ -16,7 +16,7 @@ import ApiClient from '../ApiClient'; /** * The ArduinoLorafreqplanv1 model module. * @module model/ArduinoLorafreqplanv1 - * @version 2.0.2 + * @version 2.0.3 */ class ArduinoLorafreqplanv1 { /** diff --git a/src/model/ArduinoProperty.js b/src/model/ArduinoProperty.js index a90b0db..5c6f3a7 100644 --- a/src/model/ArduinoProperty.js +++ b/src/model/ArduinoProperty.js @@ -16,7 +16,7 @@ import ApiClient from '../ApiClient'; /** * The ArduinoProperty model module. * @module model/ArduinoProperty - * @version 2.0.2 + * @version 2.0.3 */ class ArduinoProperty { /** diff --git a/src/model/ArduinoSeriesBatch.js b/src/model/ArduinoSeriesBatch.js index e6219cc..b303628 100644 --- a/src/model/ArduinoSeriesBatch.js +++ b/src/model/ArduinoSeriesBatch.js @@ -17,7 +17,7 @@ import ArduinoSeriesResponse from './ArduinoSeriesResponse'; /** * The ArduinoSeriesBatch model module. * @module model/ArduinoSeriesBatch - * @version 2.0.2 + * @version 2.0.3 */ class ArduinoSeriesBatch { /** diff --git a/src/model/ArduinoSeriesBatchSampled.js b/src/model/ArduinoSeriesBatchSampled.js new file mode 100644 index 0000000..4c307be --- /dev/null +++ b/src/model/ArduinoSeriesBatchSampled.js @@ -0,0 +1,115 @@ +/** + * Arduino IoT Cloud API + * Provides a set of endpoints to manage Arduino IoT Cloud **Devices**, **Things**, **Properties** and **Timeseries**. This API can be called just with any HTTP Client, or using one of these clients: * [Javascript NPM package](https://www.npmjs.com/package/@arduino/arduino-iot-client) * [Python PYPI Package](https://pypi.org/project/arduino-iot-client/) * [Golang Module](https://github.com/arduino/iot-client-go) + * + * The version of the OpenAPI document: 2.0 + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + * + */ + +import ApiClient from '../ApiClient'; +import ArduinoSeriesSampledResponse from './ArduinoSeriesSampledResponse'; + +/** + * The ArduinoSeriesBatchSampled model module. + * @module model/ArduinoSeriesBatchSampled + * @version 2.0.3 + */ +class ArduinoSeriesBatchSampled { + /** + * Constructs a new ArduinoSeriesBatchSampled. + * ArduinoSeriesBatchSampled media type (default view) + * @alias module:model/ArduinoSeriesBatchSampled + * @param respVersion {Number} Response version + * @param responses {Array.} Responses of the request + */ + constructor(respVersion, responses) { + + ArduinoSeriesBatchSampled.initialize(this, respVersion, responses); + } + + /** + * Initializes the fields of this object. + * This method is used by the constructors of any subclasses, in order to implement multiple inheritance (mix-ins). + * Only for internal use. + */ + static initialize(obj, respVersion, responses) { + obj['resp_version'] = respVersion; + obj['responses'] = responses; + } + + /** + * Constructs a ArduinoSeriesBatchSampled from a plain JavaScript object, optionally creating a new instance. + * Copies all relevant properties from data to obj if supplied or a new instance if not. + * @param {Object} data The plain JavaScript object bearing properties of interest. + * @param {module:model/ArduinoSeriesBatchSampled} obj Optional instance to populate. + * @return {module:model/ArduinoSeriesBatchSampled} The populated ArduinoSeriesBatchSampled instance. + */ + static constructFromObject(data, obj) { + if (data) { + obj = obj || new ArduinoSeriesBatchSampled(); + + if (data.hasOwnProperty('resp_version')) { + obj['resp_version'] = ApiClient.convertToType(data['resp_version'], 'Number'); + } + if (data.hasOwnProperty('responses')) { + obj['responses'] = ApiClient.convertToType(data['responses'], [ArduinoSeriesSampledResponse]); + } + } + return obj; + } + + /** + * Validates the JSON data with respect to ArduinoSeriesBatchSampled. + * @param {Object} data The plain JavaScript object bearing properties of interest. + * @return {boolean} to indicate whether the JSON data is valid with respect to ArduinoSeriesBatchSampled. + */ + static validateJSON(data) { + // check to make sure all required properties are present in the JSON string + for (const property of ArduinoSeriesBatchSampled.RequiredProperties) { + if (!data[property]) { + throw new Error("The required field `" + property + "` is not found in the JSON data: " + JSON.stringify(data)); + } + } + if (data['responses']) { // data not null + // ensure the json data is an array + if (!Array.isArray(data['responses'])) { + throw new Error("Expected the field `responses` to be an array in the JSON data but got " + data['responses']); + } + // validate the optional field `responses` (array) + for (const item of data['responses']) { + ArduinoSeriesSampledResponse.validateJSON(item); + }; + } + + return true; + } + + +} + +ArduinoSeriesBatchSampled.RequiredProperties = ["resp_version", "responses"]; + +/** + * Response version + * @member {Number} resp_version + */ +ArduinoSeriesBatchSampled.prototype['resp_version'] = undefined; + +/** + * Responses of the request + * @member {Array.} responses + */ +ArduinoSeriesBatchSampled.prototype['responses'] = undefined; + + + + + + +export default ArduinoSeriesBatchSampled; + diff --git a/src/model/ArduinoSeriesRawBatch.js b/src/model/ArduinoSeriesRawBatch.js index 77f92e6..859accc 100644 --- a/src/model/ArduinoSeriesRawBatch.js +++ b/src/model/ArduinoSeriesRawBatch.js @@ -17,7 +17,7 @@ import ArduinoSeriesRawResponse from './ArduinoSeriesRawResponse'; /** * The ArduinoSeriesRawBatch model module. * @module model/ArduinoSeriesRawBatch - * @version 2.0.2 + * @version 2.0.3 */ class ArduinoSeriesRawBatch { /** diff --git a/src/model/ArduinoSeriesRawBatchLastvalue.js b/src/model/ArduinoSeriesRawBatchLastvalue.js index 7f923f6..fba1d83 100644 --- a/src/model/ArduinoSeriesRawBatchLastvalue.js +++ b/src/model/ArduinoSeriesRawBatchLastvalue.js @@ -17,7 +17,7 @@ import ArduinoSeriesRawLastValueResponse from './ArduinoSeriesRawLastValueRespon /** * The ArduinoSeriesRawBatchLastvalue model module. * @module model/ArduinoSeriesRawBatchLastvalue - * @version 2.0.2 + * @version 2.0.3 */ class ArduinoSeriesRawBatchLastvalue { /** diff --git a/src/model/ArduinoSeriesRawLastValueResponse.js b/src/model/ArduinoSeriesRawLastValueResponse.js index 990fa0a..cfe5673 100644 --- a/src/model/ArduinoSeriesRawLastValueResponse.js +++ b/src/model/ArduinoSeriesRawLastValueResponse.js @@ -16,7 +16,7 @@ import ApiClient from '../ApiClient'; /** * The ArduinoSeriesRawLastValueResponse model module. * @module model/ArduinoSeriesRawLastValueResponse - * @version 2.0.2 + * @version 2.0.3 */ class ArduinoSeriesRawLastValueResponse { /** diff --git a/src/model/ArduinoSeriesRawResponse.js b/src/model/ArduinoSeriesRawResponse.js index 3f2752a..45aa2c5 100644 --- a/src/model/ArduinoSeriesRawResponse.js +++ b/src/model/ArduinoSeriesRawResponse.js @@ -17,7 +17,7 @@ import BatchQueryRawResponseSeriesMediaV1 from './BatchQueryRawResponseSeriesMed /** * The ArduinoSeriesRawResponse model module. * @module model/ArduinoSeriesRawResponse - * @version 2.0.2 + * @version 2.0.3 */ class ArduinoSeriesRawResponse { /** diff --git a/src/model/ArduinoSeriesResponse.js b/src/model/ArduinoSeriesResponse.js index 36b009f..4747816 100644 --- a/src/model/ArduinoSeriesResponse.js +++ b/src/model/ArduinoSeriesResponse.js @@ -16,7 +16,7 @@ import ApiClient from '../ApiClient'; /** * The ArduinoSeriesResponse model module. * @module model/ArduinoSeriesResponse - * @version 2.0.2 + * @version 2.0.3 */ class ArduinoSeriesResponse { /** diff --git a/src/model/ArduinoSeriesSampledResponse.js b/src/model/ArduinoSeriesSampledResponse.js new file mode 100644 index 0000000..b988a90 --- /dev/null +++ b/src/model/ArduinoSeriesSampledResponse.js @@ -0,0 +1,220 @@ +/** + * Arduino IoT Cloud API + * Provides a set of endpoints to manage Arduino IoT Cloud **Devices**, **Things**, **Properties** and **Timeseries**. This API can be called just with any HTTP Client, or using one of these clients: * [Javascript NPM package](https://www.npmjs.com/package/@arduino/arduino-iot-client) * [Python PYPI Package](https://pypi.org/project/arduino-iot-client/) * [Golang Module](https://github.com/arduino/iot-client-go) + * + * The version of the OpenAPI document: 2.0 + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + * + */ + +import ApiClient from '../ApiClient'; + +/** + * The ArduinoSeriesSampledResponse model module. + * @module model/ArduinoSeriesSampledResponse + * @version 2.0.3 + */ +class ArduinoSeriesSampledResponse { + /** + * Constructs a new ArduinoSeriesSampledResponse. + * ArduinoSeriesSampledResponse media type (default view) + * @alias module:model/ArduinoSeriesSampledResponse + * @param countValues {Number} Total number of values in the array 'values' + * @param fromDate {Date} From date + * @param interval {Number} Resolution in seconds + * @param query {String} Query of for the data + * @param respVersion {Number} Response version + * @param status {String} Status of the response + * @param times {Array.} Timestamp in RFC3339 + * @param toDate {Date} To date + * @param values {Array.} Values in Float + */ + constructor(countValues, fromDate, interval, query, respVersion, status, times, toDate, values) { + + ArduinoSeriesSampledResponse.initialize(this, countValues, fromDate, interval, query, respVersion, status, times, toDate, values); + } + + /** + * Initializes the fields of this object. + * This method is used by the constructors of any subclasses, in order to implement multiple inheritance (mix-ins). + * Only for internal use. + */ + static initialize(obj, countValues, fromDate, interval, query, respVersion, status, times, toDate, values) { + obj['count_values'] = countValues; + obj['from_date'] = fromDate; + obj['interval'] = interval; + obj['query'] = query; + obj['resp_version'] = respVersion; + obj['status'] = status; + obj['times'] = times; + obj['to_date'] = toDate; + obj['values'] = values; + } + + /** + * Constructs a ArduinoSeriesSampledResponse from a plain JavaScript object, optionally creating a new instance. + * Copies all relevant properties from data to obj if supplied or a new instance if not. + * @param {Object} data The plain JavaScript object bearing properties of interest. + * @param {module:model/ArduinoSeriesSampledResponse} obj Optional instance to populate. + * @return {module:model/ArduinoSeriesSampledResponse} The populated ArduinoSeriesSampledResponse instance. + */ + static constructFromObject(data, obj) { + if (data) { + obj = obj || new ArduinoSeriesSampledResponse(); + + if (data.hasOwnProperty('count_values')) { + obj['count_values'] = ApiClient.convertToType(data['count_values'], 'Number'); + } + if (data.hasOwnProperty('from_date')) { + obj['from_date'] = ApiClient.convertToType(data['from_date'], 'Date'); + } + if (data.hasOwnProperty('interval')) { + obj['interval'] = ApiClient.convertToType(data['interval'], 'Number'); + } + if (data.hasOwnProperty('message')) { + obj['message'] = ApiClient.convertToType(data['message'], 'String'); + } + if (data.hasOwnProperty('query')) { + obj['query'] = ApiClient.convertToType(data['query'], 'String'); + } + if (data.hasOwnProperty('resp_version')) { + obj['resp_version'] = ApiClient.convertToType(data['resp_version'], 'Number'); + } + if (data.hasOwnProperty('series_limit')) { + obj['series_limit'] = ApiClient.convertToType(data['series_limit'], 'Number'); + } + if (data.hasOwnProperty('status')) { + obj['status'] = ApiClient.convertToType(data['status'], 'String'); + } + if (data.hasOwnProperty('times')) { + obj['times'] = ApiClient.convertToType(data['times'], ['Date']); + } + if (data.hasOwnProperty('to_date')) { + obj['to_date'] = ApiClient.convertToType(data['to_date'], 'Date'); + } + if (data.hasOwnProperty('values')) { + obj['values'] = ApiClient.convertToType(data['values'], [Object]); + } + } + return obj; + } + + /** + * Validates the JSON data with respect to ArduinoSeriesSampledResponse. + * @param {Object} data The plain JavaScript object bearing properties of interest. + * @return {boolean} to indicate whether the JSON data is valid with respect to ArduinoSeriesSampledResponse. + */ + static validateJSON(data) { + // check to make sure all required properties are present in the JSON string + for (const property of ArduinoSeriesSampledResponse.RequiredProperties) { + if (!data[property]) { + throw new Error("The required field `" + property + "` is not found in the JSON data: " + JSON.stringify(data)); + } + } + // ensure the json data is a string + if (data['message'] && !(typeof data['message'] === 'string' || data['message'] instanceof String)) { + throw new Error("Expected the field `message` to be a primitive type in the JSON string but got " + data['message']); + } + // ensure the json data is a string + if (data['query'] && !(typeof data['query'] === 'string' || data['query'] instanceof String)) { + throw new Error("Expected the field `query` to be a primitive type in the JSON string but got " + data['query']); + } + // ensure the json data is a string + if (data['status'] && !(typeof data['status'] === 'string' || data['status'] instanceof String)) { + throw new Error("Expected the field `status` to be a primitive type in the JSON string but got " + data['status']); + } + // ensure the json data is an array + if (!Array.isArray(data['times'])) { + throw new Error("Expected the field `times` to be an array in the JSON data but got " + data['times']); + } + // ensure the json data is an array + if (!Array.isArray(data['values'])) { + throw new Error("Expected the field `values` to be an array in the JSON data but got " + data['values']); + } + + return true; + } + + +} + +ArduinoSeriesSampledResponse.RequiredProperties = ["count_values", "from_date", "interval", "query", "resp_version", "status", "times", "to_date", "values"]; + +/** + * Total number of values in the array 'values' + * @member {Number} count_values + */ +ArduinoSeriesSampledResponse.prototype['count_values'] = undefined; + +/** + * From date + * @member {Date} from_date + */ +ArduinoSeriesSampledResponse.prototype['from_date'] = undefined; + +/** + * Resolution in seconds + * @member {Number} interval + */ +ArduinoSeriesSampledResponse.prototype['interval'] = undefined; + +/** + * If the response is different than 'ok' + * @member {String} message + * @default '' + */ +ArduinoSeriesSampledResponse.prototype['message'] = ''; + +/** + * Query of for the data + * @member {String} query + */ +ArduinoSeriesSampledResponse.prototype['query'] = undefined; + +/** + * Response version + * @member {Number} resp_version + */ +ArduinoSeriesSampledResponse.prototype['resp_version'] = undefined; + +/** + * Maximum number of values returned after data aggregation, if any + * @member {Number} series_limit + */ +ArduinoSeriesSampledResponse.prototype['series_limit'] = undefined; + +/** + * Status of the response + * @member {String} status + */ +ArduinoSeriesSampledResponse.prototype['status'] = undefined; + +/** + * Timestamp in RFC3339 + * @member {Array.} times + */ +ArduinoSeriesSampledResponse.prototype['times'] = undefined; + +/** + * To date + * @member {Date} to_date + */ +ArduinoSeriesSampledResponse.prototype['to_date'] = undefined; + +/** + * Values in Float + * @member {Array.} values + */ +ArduinoSeriesSampledResponse.prototype['values'] = undefined; + + + + + + +export default ArduinoSeriesSampledResponse; + diff --git a/src/model/ArduinoTags.js b/src/model/ArduinoTags.js index 0874e2d..52f692e 100644 --- a/src/model/ArduinoTags.js +++ b/src/model/ArduinoTags.js @@ -17,7 +17,7 @@ import Tag from './Tag'; /** * The ArduinoTags model module. * @module model/ArduinoTags - * @version 2.0.2 + * @version 2.0.3 */ class ArduinoTags { /** diff --git a/src/model/ArduinoTemplateproperty.js b/src/model/ArduinoTemplateproperty.js index 3676334..2f8d187 100644 --- a/src/model/ArduinoTemplateproperty.js +++ b/src/model/ArduinoTemplateproperty.js @@ -16,7 +16,7 @@ import ApiClient from '../ApiClient'; /** * The ArduinoTemplateproperty model module. * @module model/ArduinoTemplateproperty - * @version 2.0.2 + * @version 2.0.3 */ class ArduinoTemplateproperty { /** @@ -56,6 +56,9 @@ class ArduinoTemplateproperty { if (data) { obj = obj || new ArduinoTemplateproperty(); + if (data.hasOwnProperty('id')) { + obj['id'] = ApiClient.convertToType(data['id'], 'String'); + } if (data.hasOwnProperty('name')) { obj['name'] = ApiClient.convertToType(data['name'], 'String'); } @@ -91,6 +94,10 @@ class ArduinoTemplateproperty { } } // ensure the json data is a string + if (data['id'] && !(typeof data['id'] === 'string' || data['id'] instanceof String)) { + throw new Error("Expected the field `id` to be a primitive type in the JSON string but got " + data['id']); + } + // ensure the json data is a string if (data['name'] && !(typeof data['name'] === 'string' || data['name'] instanceof String)) { throw new Error("Expected the field `name` to be a primitive type in the JSON string but got " + data['name']); } @@ -119,6 +126,12 @@ class ArduinoTemplateproperty { ArduinoTemplateproperty.RequiredProperties = ["name", "permission", "type", "update_strategy"]; +/** + * The friendly id of the property + * @member {String} id + */ +ArduinoTemplateproperty.prototype['id'] = undefined; + /** * The friendly name of the property * @member {String} name diff --git a/src/model/ArduinoTemplatevariable.js b/src/model/ArduinoTemplatevariable.js index ebe1bbb..8f6e68c 100644 --- a/src/model/ArduinoTemplatevariable.js +++ b/src/model/ArduinoTemplatevariable.js @@ -17,7 +17,7 @@ import ArduinoTimezone from './ArduinoTimezone'; /** * The ArduinoTemplatevariable model module. * @module model/ArduinoTemplatevariable - * @version 2.0.2 + * @version 2.0.3 */ class ArduinoTemplatevariable { /** diff --git a/src/model/ArduinoThing.js b/src/model/ArduinoThing.js index 42547f5..0674872 100644 --- a/src/model/ArduinoThing.js +++ b/src/model/ArduinoThing.js @@ -17,7 +17,7 @@ import ArduinoProperty from './ArduinoProperty'; /** * The ArduinoThing model module. * @module model/ArduinoThing - * @version 2.0.2 + * @version 2.0.3 */ class ArduinoThing { /** @@ -59,6 +59,9 @@ class ArduinoThing { if (data) { obj = obj || new ArduinoThing(); + if (data.hasOwnProperty('assistant')) { + obj['assistant'] = ApiClient.convertToType(data['assistant'], 'String'); + } if (data.hasOwnProperty('created_at')) { obj['created_at'] = ApiClient.convertToType(data['created_at'], 'Date'); } @@ -133,6 +136,10 @@ class ArduinoThing { } } // ensure the json data is a string + if (data['assistant'] && !(typeof data['assistant'] === 'string' || data['assistant'] instanceof String)) { + throw new Error("Expected the field `assistant` to be a primitive type in the JSON string but got " + data['assistant']); + } + // ensure the json data is a string if (data['device_fqbn'] && !(typeof data['device_fqbn'] === 'string' || data['device_fqbn'] instanceof String)) { throw new Error("Expected the field `device_fqbn` to be a primitive type in the JSON string but got " + data['device_fqbn']); } @@ -199,6 +206,12 @@ class ArduinoThing { ArduinoThing.RequiredProperties = ["href", "id", "name", "timezone", "user_id"]; +/** + * The kind of voice assistant the thing is connected to, it can be ALEXA | GOOGLE | NONE + * @member {module:model/ArduinoThing.AssistantEnum} assistant + */ +ArduinoThing.prototype['assistant'] = undefined; + /** * Creation date of the thing * @member {Date} created_at @@ -317,6 +330,33 @@ ArduinoThing.prototype['webhook_uri'] = undefined; +/** + * Allowed values for the assistant property. + * @enum {String} + * @readonly + */ +ArduinoThing['AssistantEnum'] = { + + /** + * value: "ALEXA" + * @const + */ + "ALEXA": "ALEXA", + + /** + * value: "GOOGLE" + * @const + */ + "GOOGLE": "GOOGLE", + + /** + * value: "NONE" + * @const + */ + "NONE": "NONE" +}; + + export default ArduinoThing; diff --git a/src/model/ArduinoThingtemplate.js b/src/model/ArduinoThingtemplate.js index c0fa846..ea48ed4 100644 --- a/src/model/ArduinoThingtemplate.js +++ b/src/model/ArduinoThingtemplate.js @@ -12,13 +12,14 @@ */ import ApiClient from '../ApiClient'; +import ArduinoDevicev2templatedevice from './ArduinoDevicev2templatedevice'; import ArduinoTemplateproperty from './ArduinoTemplateproperty'; import Tag from './Tag'; /** * The ArduinoThingtemplate model module. * @module model/ArduinoThingtemplate - * @version 2.0.2 + * @version 2.0.3 */ class ArduinoThingtemplate { /** @@ -54,14 +55,20 @@ class ArduinoThingtemplate { if (data) { obj = obj || new ArduinoThingtemplate(); + if (data.hasOwnProperty('device_metadata')) { + obj['device_metadata'] = ArduinoDevicev2templatedevice.constructFromObject(data['device_metadata']); + } + if (data.hasOwnProperty('id')) { + obj['id'] = ApiClient.convertToType(data['id'], 'String'); + } if (data.hasOwnProperty('name')) { obj['name'] = ApiClient.convertToType(data['name'], 'String'); } if (data.hasOwnProperty('organization_id')) { obj['organization_id'] = ApiClient.convertToType(data['organization_id'], 'String'); } - if (data.hasOwnProperty('properties')) { - obj['properties'] = ApiClient.convertToType(data['properties'], [ArduinoTemplateproperty]); + if (data.hasOwnProperty('sketch_template')) { + obj['sketch_template'] = ApiClient.convertToType(data['sketch_template'], 'String'); } if (data.hasOwnProperty('tags')) { obj['tags'] = ApiClient.convertToType(data['tags'], [Tag]); @@ -69,6 +76,9 @@ class ArduinoThingtemplate { if (data.hasOwnProperty('timezone')) { obj['timezone'] = ApiClient.convertToType(data['timezone'], 'String'); } + if (data.hasOwnProperty('variables')) { + obj['variables'] = ApiClient.convertToType(data['variables'], [ArduinoTemplateproperty]); + } if (data.hasOwnProperty('webhook_uri')) { obj['webhook_uri'] = ApiClient.convertToType(data['webhook_uri'], 'String'); } @@ -88,6 +98,14 @@ class ArduinoThingtemplate { throw new Error("The required field `" + property + "` is not found in the JSON data: " + JSON.stringify(data)); } } + // validate the optional field `device_metadata` + if (data['device_metadata']) { // data not null + ArduinoDevicev2templatedevice.validateJSON(data['device_metadata']); + } + // ensure the json data is a string + if (data['id'] && !(typeof data['id'] === 'string' || data['id'] instanceof String)) { + throw new Error("Expected the field `id` to be a primitive type in the JSON string but got " + data['id']); + } // ensure the json data is a string if (data['name'] && !(typeof data['name'] === 'string' || data['name'] instanceof String)) { throw new Error("Expected the field `name` to be a primitive type in the JSON string but got " + data['name']); @@ -96,15 +114,9 @@ class ArduinoThingtemplate { if (data['organization_id'] && !(typeof data['organization_id'] === 'string' || data['organization_id'] instanceof String)) { throw new Error("Expected the field `organization_id` to be a primitive type in the JSON string but got " + data['organization_id']); } - if (data['properties']) { // data not null - // ensure the json data is an array - if (!Array.isArray(data['properties'])) { - throw new Error("Expected the field `properties` to be an array in the JSON data but got " + data['properties']); - } - // validate the optional field `properties` (array) - for (const item of data['properties']) { - ArduinoTemplateproperty.validateJSON(item); - }; + // ensure the json data is a string + if (data['sketch_template'] && !(typeof data['sketch_template'] === 'string' || data['sketch_template'] instanceof String)) { + throw new Error("Expected the field `sketch_template` to be a primitive type in the JSON string but got " + data['sketch_template']); } if (data['tags']) { // data not null // ensure the json data is an array @@ -120,6 +132,16 @@ class ArduinoThingtemplate { if (data['timezone'] && !(typeof data['timezone'] === 'string' || data['timezone'] instanceof String)) { throw new Error("Expected the field `timezone` to be a primitive type in the JSON string but got " + data['timezone']); } + if (data['variables']) { // data not null + // ensure the json data is an array + if (!Array.isArray(data['variables'])) { + throw new Error("Expected the field `variables` to be an array in the JSON data but got " + data['variables']); + } + // validate the optional field `variables` (array) + for (const item of data['variables']) { + ArduinoTemplateproperty.validateJSON(item); + }; + } // ensure the json data is a string if (data['webhook_uri'] && !(typeof data['webhook_uri'] === 'string' || data['webhook_uri'] instanceof String)) { throw new Error("Expected the field `webhook_uri` to be a primitive type in the JSON string but got " + data['webhook_uri']); @@ -133,6 +155,17 @@ class ArduinoThingtemplate { ArduinoThingtemplate.RequiredProperties = ["name", "timezone"]; +/** + * @member {module:model/ArduinoDevicev2templatedevice} device_metadata + */ +ArduinoThingtemplate.prototype['device_metadata'] = undefined; + +/** + * The friendly id of the thing + * @member {String} id + */ +ArduinoThingtemplate.prototype['id'] = undefined; + /** * The friendly name of the thing * @member {String} name @@ -146,10 +179,10 @@ ArduinoThingtemplate.prototype['name'] = undefined; ArduinoThingtemplate.prototype['organization_id'] = undefined; /** - * ArduinoTemplatepropertyCollection is the media type for an array of ArduinoTemplateproperty (default view) - * @member {Array.} properties + * The ID of the template's sketch + * @member {String} sketch_template */ -ArduinoThingtemplate.prototype['properties'] = undefined; +ArduinoThingtemplate.prototype['sketch_template'] = undefined; /** * Tags of the thing @@ -163,6 +196,12 @@ ArduinoThingtemplate.prototype['tags'] = undefined; */ ArduinoThingtemplate.prototype['timezone'] = undefined; +/** + * ArduinoTemplatepropertyCollection is the media type for an array of ArduinoTemplateproperty (default view) + * @member {Array.} variables + */ +ArduinoThingtemplate.prototype['variables'] = undefined; + /** * Webhook uri * @member {String} webhook_uri diff --git a/src/model/ArduinoTimeseriesmedia.js b/src/model/ArduinoTimeseriesmedia.js index 277db5f..adf40b9 100644 --- a/src/model/ArduinoTimeseriesmedia.js +++ b/src/model/ArduinoTimeseriesmedia.js @@ -17,7 +17,7 @@ import TimeseriesDataPoint from './TimeseriesDataPoint'; /** * The ArduinoTimeseriesmedia model module. * @module model/ArduinoTimeseriesmedia - * @version 2.0.2 + * @version 2.0.3 */ class ArduinoTimeseriesmedia { /** diff --git a/src/model/ArduinoTimezone.js b/src/model/ArduinoTimezone.js index 7bcb294..8056661 100644 --- a/src/model/ArduinoTimezone.js +++ b/src/model/ArduinoTimezone.js @@ -16,7 +16,7 @@ import ApiClient from '../ApiClient'; /** * The ArduinoTimezone model module. * @module model/ArduinoTimezone - * @version 2.0.2 + * @version 2.0.3 */ class ArduinoTimezone { /** diff --git a/src/model/ArduinoVariableslinks.js b/src/model/ArduinoVariableslinks.js index 98a9aaa..e6a7658 100644 --- a/src/model/ArduinoVariableslinks.js +++ b/src/model/ArduinoVariableslinks.js @@ -16,7 +16,7 @@ import ApiClient from '../ApiClient'; /** * The ArduinoVariableslinks model module. * @module model/ArduinoVariableslinks - * @version 2.0.2 + * @version 2.0.3 */ class ArduinoVariableslinks { /** diff --git a/src/model/ArduinoWidgetv2.js b/src/model/ArduinoWidgetv2.js index 1733b08..c6fb0b6 100644 --- a/src/model/ArduinoWidgetv2.js +++ b/src/model/ArduinoWidgetv2.js @@ -17,7 +17,7 @@ import ArduinoLinkedvariable from './ArduinoLinkedvariable'; /** * The ArduinoWidgetv2 model module. * @module model/ArduinoWidgetv2 - * @version 2.0.2 + * @version 2.0.3 */ class ArduinoWidgetv2 { /** @@ -27,7 +27,7 @@ class ArduinoWidgetv2 { * @param height {Number} Widget current height for desktop * @param id {String} The UUID of the widget, set by client * @param options {Object.} Widget options - * @param type {module:model/ArduinoWidgetv2.TypeEnum} The type of the widget + * @param type {String} The type of the widget * @param width {Number} Widget current width for desktop * @param x {Number} Widget x position for desktop * @param y {Number} Widget y position for desktop @@ -208,7 +208,7 @@ ArduinoWidgetv2.prototype['options'] = undefined; /** * The type of the widget - * @member {module:model/ArduinoWidgetv2.TypeEnum} type + * @member {String} type */ ArduinoWidgetv2.prototype['type'] = undefined; @@ -258,21 +258,6 @@ ArduinoWidgetv2.prototype['y_mobile'] = undefined; -/** - * Allowed values for the type property. - * @enum {String} - * @readonly - */ -ArduinoWidgetv2['TypeEnum'] = { - - /** - * value: "slider, gauge" - * @const - */ - "slider, gauge": "slider, gauge" -}; - - export default ArduinoWidgetv2; diff --git a/src/model/ArduinoWidgetv2template.js b/src/model/ArduinoWidgetv2template.js index e22f1a2..955bd4c 100644 --- a/src/model/ArduinoWidgetv2template.js +++ b/src/model/ArduinoWidgetv2template.js @@ -17,7 +17,7 @@ import ArduinoTemplatevariable from './ArduinoTemplatevariable'; /** * The ArduinoWidgetv2template model module. * @module model/ArduinoWidgetv2template - * @version 2.0.2 + * @version 2.0.3 */ class ArduinoWidgetv2template { /** diff --git a/src/model/BatchLastValueRequestsMediaV1.js b/src/model/BatchLastValueRequestsMediaV1.js index 3e1948d..f1c20c0 100644 --- a/src/model/BatchLastValueRequestsMediaV1.js +++ b/src/model/BatchLastValueRequestsMediaV1.js @@ -17,7 +17,7 @@ import BatchQueryRawLastValueRequestMediaV1 from './BatchQueryRawLastValueReques /** * The BatchLastValueRequestsMediaV1 model module. * @module model/BatchLastValueRequestsMediaV1 - * @version 2.0.2 + * @version 2.0.3 */ class BatchLastValueRequestsMediaV1 { /** diff --git a/src/model/BatchQueryRawLastValueRequestMediaV1.js b/src/model/BatchQueryRawLastValueRequestMediaV1.js index 7a4e27b..f89d6a3 100644 --- a/src/model/BatchQueryRawLastValueRequestMediaV1.js +++ b/src/model/BatchQueryRawLastValueRequestMediaV1.js @@ -16,7 +16,7 @@ import ApiClient from '../ApiClient'; /** * The BatchQueryRawLastValueRequestMediaV1 model module. * @module model/BatchQueryRawLastValueRequestMediaV1 - * @version 2.0.2 + * @version 2.0.3 */ class BatchQueryRawLastValueRequestMediaV1 { /** diff --git a/src/model/BatchQueryRawRequestMediaV1.js b/src/model/BatchQueryRawRequestMediaV1.js index af36d8f..e0f83f1 100644 --- a/src/model/BatchQueryRawRequestMediaV1.js +++ b/src/model/BatchQueryRawRequestMediaV1.js @@ -16,7 +16,7 @@ import ApiClient from '../ApiClient'; /** * The BatchQueryRawRequestMediaV1 model module. * @module model/BatchQueryRawRequestMediaV1 - * @version 2.0.2 + * @version 2.0.3 */ class BatchQueryRawRequestMediaV1 { /** diff --git a/src/model/BatchQueryRawRequestsMediaV1.js b/src/model/BatchQueryRawRequestsMediaV1.js index 8ab2493..d145629 100644 --- a/src/model/BatchQueryRawRequestsMediaV1.js +++ b/src/model/BatchQueryRawRequestsMediaV1.js @@ -17,7 +17,7 @@ import BatchQueryRawRequestMediaV1 from './BatchQueryRawRequestMediaV1'; /** * The BatchQueryRawRequestsMediaV1 model module. * @module model/BatchQueryRawRequestsMediaV1 - * @version 2.0.2 + * @version 2.0.3 */ class BatchQueryRawRequestsMediaV1 { /** diff --git a/src/model/BatchQueryRawResponseSeriesMediaV1.js b/src/model/BatchQueryRawResponseSeriesMediaV1.js index e829467..f0f5165 100644 --- a/src/model/BatchQueryRawResponseSeriesMediaV1.js +++ b/src/model/BatchQueryRawResponseSeriesMediaV1.js @@ -16,7 +16,7 @@ import ApiClient from '../ApiClient'; /** * The BatchQueryRawResponseSeriesMediaV1 model module. * @module model/BatchQueryRawResponseSeriesMediaV1 - * @version 2.0.2 + * @version 2.0.3 */ class BatchQueryRawResponseSeriesMediaV1 { /** diff --git a/src/model/BatchQueryRequestMediaV1.js b/src/model/BatchQueryRequestMediaV1.js index ad602bb..3f45348 100644 --- a/src/model/BatchQueryRequestMediaV1.js +++ b/src/model/BatchQueryRequestMediaV1.js @@ -16,7 +16,7 @@ import ApiClient from '../ApiClient'; /** * The BatchQueryRequestMediaV1 model module. * @module model/BatchQueryRequestMediaV1 - * @version 2.0.2 + * @version 2.0.3 */ class BatchQueryRequestMediaV1 { /** diff --git a/src/model/BatchQueryRequestsMediaV1.js b/src/model/BatchQueryRequestsMediaV1.js index a0fcabe..7f70139 100644 --- a/src/model/BatchQueryRequestsMediaV1.js +++ b/src/model/BatchQueryRequestsMediaV1.js @@ -17,7 +17,7 @@ import BatchQueryRequestMediaV1 from './BatchQueryRequestMediaV1'; /** * The BatchQueryRequestsMediaV1 model module. * @module model/BatchQueryRequestsMediaV1 - * @version 2.0.2 + * @version 2.0.3 */ class BatchQueryRequestsMediaV1 { /** diff --git a/src/model/BatchQuerySampledRequestMediaV1.js b/src/model/BatchQuerySampledRequestMediaV1.js new file mode 100644 index 0000000..67b568f --- /dev/null +++ b/src/model/BatchQuerySampledRequestMediaV1.js @@ -0,0 +1,133 @@ +/** + * Arduino IoT Cloud API + * Provides a set of endpoints to manage Arduino IoT Cloud **Devices**, **Things**, **Properties** and **Timeseries**. This API can be called just with any HTTP Client, or using one of these clients: * [Javascript NPM package](https://www.npmjs.com/package/@arduino/arduino-iot-client) * [Python PYPI Package](https://pypi.org/project/arduino-iot-client/) * [Golang Module](https://github.com/arduino/iot-client-go) + * + * The version of the OpenAPI document: 2.0 + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + * + */ + +import ApiClient from '../ApiClient'; + +/** + * The BatchQuerySampledRequestMediaV1 model module. + * @module model/BatchQuerySampledRequestMediaV1 + * @version 2.0.3 + */ +class BatchQuerySampledRequestMediaV1 { + /** + * Constructs a new BatchQuerySampledRequestMediaV1. + * @alias module:model/BatchQuerySampledRequestMediaV1 + * @param q {String} Data selection query (e.g. property.2a99729d-2556-4220-a139-023348a1e6b5) + */ + constructor(q) { + + BatchQuerySampledRequestMediaV1.initialize(this, q); + } + + /** + * Initializes the fields of this object. + * This method is used by the constructors of any subclasses, in order to implement multiple inheritance (mix-ins). + * Only for internal use. + */ + static initialize(obj, q) { + obj['q'] = q; + } + + /** + * Constructs a BatchQuerySampledRequestMediaV1 from a plain JavaScript object, optionally creating a new instance. + * Copies all relevant properties from data to obj if supplied or a new instance if not. + * @param {Object} data The plain JavaScript object bearing properties of interest. + * @param {module:model/BatchQuerySampledRequestMediaV1} obj Optional instance to populate. + * @return {module:model/BatchQuerySampledRequestMediaV1} The populated BatchQuerySampledRequestMediaV1 instance. + */ + static constructFromObject(data, obj) { + if (data) { + obj = obj || new BatchQuerySampledRequestMediaV1(); + + if (data.hasOwnProperty('from')) { + obj['from'] = ApiClient.convertToType(data['from'], 'Date'); + } + if (data.hasOwnProperty('interval')) { + obj['interval'] = ApiClient.convertToType(data['interval'], 'Number'); + } + if (data.hasOwnProperty('q')) { + obj['q'] = ApiClient.convertToType(data['q'], 'String'); + } + if (data.hasOwnProperty('series_limit')) { + obj['series_limit'] = ApiClient.convertToType(data['series_limit'], 'Number'); + } + if (data.hasOwnProperty('to')) { + obj['to'] = ApiClient.convertToType(data['to'], 'Date'); + } + } + return obj; + } + + /** + * Validates the JSON data with respect to BatchQuerySampledRequestMediaV1. + * @param {Object} data The plain JavaScript object bearing properties of interest. + * @return {boolean} to indicate whether the JSON data is valid with respect to BatchQuerySampledRequestMediaV1. + */ + static validateJSON(data) { + // check to make sure all required properties are present in the JSON string + for (const property of BatchQuerySampledRequestMediaV1.RequiredProperties) { + if (!data[property]) { + throw new Error("The required field `" + property + "` is not found in the JSON data: " + JSON.stringify(data)); + } + } + // ensure the json data is a string + if (data['q'] && !(typeof data['q'] === 'string' || data['q'] instanceof String)) { + throw new Error("Expected the field `q` to be a primitive type in the JSON string but got " + data['q']); + } + + return true; + } + + +} + +BatchQuerySampledRequestMediaV1.RequiredProperties = ["q"]; + +/** + * From timestamp (default: now UTC - 24h) + * @member {Date} from + */ +BatchQuerySampledRequestMediaV1.prototype['from'] = undefined; + +/** + * Resolution in seconds (allowed min:60, max:86400) + * @member {Number} interval + * @default 300 + */ +BatchQuerySampledRequestMediaV1.prototype['interval'] = 300; + +/** + * Data selection query (e.g. property.2a99729d-2556-4220-a139-023348a1e6b5) + * @member {String} q + */ +BatchQuerySampledRequestMediaV1.prototype['q'] = undefined; + +/** + * Maximum number of values returned after data aggregation, if any (default: 300, limit: 1000) + * @member {Number} series_limit + */ +BatchQuerySampledRequestMediaV1.prototype['series_limit'] = undefined; + +/** + * To timestamp (default: now UTC) + * @member {Date} to + */ +BatchQuerySampledRequestMediaV1.prototype['to'] = undefined; + + + + + + +export default BatchQuerySampledRequestMediaV1; + diff --git a/src/model/BatchQuerySampledRequestsMediaV1.js b/src/model/BatchQuerySampledRequestsMediaV1.js new file mode 100644 index 0000000..cc1eebd --- /dev/null +++ b/src/model/BatchQuerySampledRequestsMediaV1.js @@ -0,0 +1,114 @@ +/** + * Arduino IoT Cloud API + * Provides a set of endpoints to manage Arduino IoT Cloud **Devices**, **Things**, **Properties** and **Timeseries**. This API can be called just with any HTTP Client, or using one of these clients: * [Javascript NPM package](https://www.npmjs.com/package/@arduino/arduino-iot-client) * [Python PYPI Package](https://pypi.org/project/arduino-iot-client/) * [Golang Module](https://github.com/arduino/iot-client-go) + * + * The version of the OpenAPI document: 2.0 + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + * + */ + +import ApiClient from '../ApiClient'; +import BatchQuerySampledRequestMediaV1 from './BatchQuerySampledRequestMediaV1'; + +/** + * The BatchQuerySampledRequestsMediaV1 model module. + * @module model/BatchQuerySampledRequestsMediaV1 + * @version 2.0.3 + */ +class BatchQuerySampledRequestsMediaV1 { + /** + * Constructs a new BatchQuerySampledRequestsMediaV1. + * @alias module:model/BatchQuerySampledRequestsMediaV1 + * @param requests {Array.} Requests + * @param respVersion {Number} Response version + */ + constructor(requests, respVersion) { + + BatchQuerySampledRequestsMediaV1.initialize(this, requests, respVersion); + } + + /** + * Initializes the fields of this object. + * This method is used by the constructors of any subclasses, in order to implement multiple inheritance (mix-ins). + * Only for internal use. + */ + static initialize(obj, requests, respVersion) { + obj['requests'] = requests; + obj['resp_version'] = respVersion; + } + + /** + * Constructs a BatchQuerySampledRequestsMediaV1 from a plain JavaScript object, optionally creating a new instance. + * Copies all relevant properties from data to obj if supplied or a new instance if not. + * @param {Object} data The plain JavaScript object bearing properties of interest. + * @param {module:model/BatchQuerySampledRequestsMediaV1} obj Optional instance to populate. + * @return {module:model/BatchQuerySampledRequestsMediaV1} The populated BatchQuerySampledRequestsMediaV1 instance. + */ + static constructFromObject(data, obj) { + if (data) { + obj = obj || new BatchQuerySampledRequestsMediaV1(); + + if (data.hasOwnProperty('requests')) { + obj['requests'] = ApiClient.convertToType(data['requests'], [BatchQuerySampledRequestMediaV1]); + } + if (data.hasOwnProperty('resp_version')) { + obj['resp_version'] = ApiClient.convertToType(data['resp_version'], 'Number'); + } + } + return obj; + } + + /** + * Validates the JSON data with respect to BatchQuerySampledRequestsMediaV1. + * @param {Object} data The plain JavaScript object bearing properties of interest. + * @return {boolean} to indicate whether the JSON data is valid with respect to BatchQuerySampledRequestsMediaV1. + */ + static validateJSON(data) { + // check to make sure all required properties are present in the JSON string + for (const property of BatchQuerySampledRequestsMediaV1.RequiredProperties) { + if (!data[property]) { + throw new Error("The required field `" + property + "` is not found in the JSON data: " + JSON.stringify(data)); + } + } + if (data['requests']) { // data not null + // ensure the json data is an array + if (!Array.isArray(data['requests'])) { + throw new Error("Expected the field `requests` to be an array in the JSON data but got " + data['requests']); + } + // validate the optional field `requests` (array) + for (const item of data['requests']) { + BatchQuerySampledRequestMediaV1.validateJSON(item); + }; + } + + return true; + } + + +} + +BatchQuerySampledRequestsMediaV1.RequiredProperties = ["requests", "resp_version"]; + +/** + * Requests + * @member {Array.} requests + */ +BatchQuerySampledRequestsMediaV1.prototype['requests'] = undefined; + +/** + * Response version + * @member {Number} resp_version + */ +BatchQuerySampledRequestsMediaV1.prototype['resp_version'] = undefined; + + + + + + +export default BatchQuerySampledRequestsMediaV1; + diff --git a/src/model/CheckDevicesV2PassPayload.js b/src/model/CheckDevicesV2PassPayload.js index 992e27e..dd59cd7 100644 --- a/src/model/CheckDevicesV2PassPayload.js +++ b/src/model/CheckDevicesV2PassPayload.js @@ -16,7 +16,7 @@ import ApiClient from '../ApiClient'; /** * The CheckDevicesV2PassPayload model module. * @module model/CheckDevicesV2PassPayload - * @version 2.0.2 + * @version 2.0.3 */ class CheckDevicesV2PassPayload { /** diff --git a/src/model/Clone.js b/src/model/Clone.js index 62b2a29..8a279f5 100644 --- a/src/model/Clone.js +++ b/src/model/Clone.js @@ -17,7 +17,7 @@ import Override from './Override'; /** * The Clone model module. * @module model/Clone - * @version 2.0.2 + * @version 2.0.3 */ class Clone { /** diff --git a/src/model/CreateDevicesV2CertsPayload.js b/src/model/CreateDevicesV2CertsPayload.js index 7f25fc3..e7c2350 100644 --- a/src/model/CreateDevicesV2CertsPayload.js +++ b/src/model/CreateDevicesV2CertsPayload.js @@ -16,7 +16,7 @@ import ApiClient from '../ApiClient'; /** * The CreateDevicesV2CertsPayload model module. * @module model/CreateDevicesV2CertsPayload - * @version 2.0.2 + * @version 2.0.3 */ class CreateDevicesV2CertsPayload { /** diff --git a/src/model/CreateDevicesV2Payload.js b/src/model/CreateDevicesV2Payload.js index d343546..fcd5d3f 100644 --- a/src/model/CreateDevicesV2Payload.js +++ b/src/model/CreateDevicesV2Payload.js @@ -16,7 +16,7 @@ import ApiClient from '../ApiClient'; /** * The CreateDevicesV2Payload model module. * @module model/CreateDevicesV2Payload - * @version 2.0.2 + * @version 2.0.3 */ class CreateDevicesV2Payload { /** @@ -211,7 +211,19 @@ CreateDevicesV2Payload['ConnectionTypeEnum'] = { * value: "lora" * @const */ - "lora": "lora" + "lora": "lora", + + /** + * value: "catm1" + * @const + */ + "catm1": "catm1", + + /** + * value: "cellular" + * @const + */ + "cellular": "cellular" }; diff --git a/src/model/CreateLoraDevicesV1Payload.js b/src/model/CreateLoraDevicesV1Payload.js index 74a62d7..42464ce 100644 --- a/src/model/CreateLoraDevicesV1Payload.js +++ b/src/model/CreateLoraDevicesV1Payload.js @@ -16,7 +16,7 @@ import ApiClient from '../ApiClient'; /** * The CreateLoraDevicesV1Payload model module. * @module model/CreateLoraDevicesV1Payload - * @version 2.0.2 + * @version 2.0.3 */ class CreateLoraDevicesV1Payload { /** diff --git a/src/model/Dashboardshare.js b/src/model/Dashboardshare.js index 966fe5b..65b7b22 100644 --- a/src/model/Dashboardshare.js +++ b/src/model/Dashboardshare.js @@ -16,7 +16,7 @@ import ApiClient from '../ApiClient'; /** * The Dashboardshare model module. * @module model/Dashboardshare - * @version 2.0.2 + * @version 2.0.3 */ class Dashboardshare { /** diff --git a/src/model/Dashboardv2.js b/src/model/Dashboardv2.js index 9ae7095..6dcfc06 100644 --- a/src/model/Dashboardv2.js +++ b/src/model/Dashboardv2.js @@ -17,7 +17,7 @@ import Widget from './Widget'; /** * The Dashboardv2 model module. * @module model/Dashboardv2 - * @version 2.0.2 + * @version 2.0.3 */ class Dashboardv2 { /** diff --git a/src/model/Devicev2.js b/src/model/Devicev2.js index 640b1b4..97d754f 100644 --- a/src/model/Devicev2.js +++ b/src/model/Devicev2.js @@ -16,7 +16,7 @@ import ApiClient from '../ApiClient'; /** * The Devicev2 model module. * @module model/Devicev2 - * @version 2.0.2 + * @version 2.0.3 */ class Devicev2 { /** @@ -203,7 +203,19 @@ Devicev2['ConnectionTypeEnum'] = { * value: "lora" * @const */ - "lora": "lora" + "lora": "lora", + + /** + * value: "catm1" + * @const + */ + "catm1": "catm1", + + /** + * value: "cellular" + * @const + */ + "cellular": "cellular" }; diff --git a/src/model/Devicev2Cert.js b/src/model/Devicev2Cert.js index 3b15d5d..4a149f8 100644 --- a/src/model/Devicev2Cert.js +++ b/src/model/Devicev2Cert.js @@ -16,7 +16,7 @@ import ApiClient from '../ApiClient'; /** * The Devicev2Cert model module. * @module model/Devicev2Cert - * @version 2.0.2 + * @version 2.0.3 */ class Devicev2Cert { /** diff --git a/src/model/Devicev2Otabinaryurl.js b/src/model/Devicev2Otabinaryurl.js index d3a6f68..9dcd15b 100644 --- a/src/model/Devicev2Otabinaryurl.js +++ b/src/model/Devicev2Otabinaryurl.js @@ -16,7 +16,7 @@ import ApiClient from '../ApiClient'; /** * The Devicev2Otabinaryurl model module. * @module model/Devicev2Otabinaryurl - * @version 2.0.2 + * @version 2.0.3 */ class Devicev2Otabinaryurl { /** diff --git a/src/model/Devicev2Otaurlpyalod.js b/src/model/Devicev2Otaurlpyalod.js index d929648..ff58056 100644 --- a/src/model/Devicev2Otaurlpyalod.js +++ b/src/model/Devicev2Otaurlpyalod.js @@ -16,7 +16,7 @@ import ApiClient from '../ApiClient'; /** * The Devicev2Otaurlpyalod model module. * @module model/Devicev2Otaurlpyalod - * @version 2.0.2 + * @version 2.0.3 */ class Devicev2Otaurlpyalod { /** diff --git a/src/model/Devicev2Pass.js b/src/model/Devicev2Pass.js index 4f0bab1..3f1ed90 100644 --- a/src/model/Devicev2Pass.js +++ b/src/model/Devicev2Pass.js @@ -16,7 +16,7 @@ import ApiClient from '../ApiClient'; /** * The Devicev2Pass model module. * @module model/Devicev2Pass - * @version 2.0.2 + * @version 2.0.3 */ class Devicev2Pass { /** diff --git a/src/model/Error.js b/src/model/Error.js index 06259bf..5f9e36d 100644 --- a/src/model/Error.js +++ b/src/model/Error.js @@ -16,7 +16,7 @@ import ApiClient from '../ApiClient'; /** * The Error model module. * @module model/Error - * @version 2.0.2 + * @version 2.0.3 */ class Error { /** diff --git a/src/model/HistoricDataRequest.js b/src/model/HistoricDataRequest.js index a0972e0..37fc2ac 100644 --- a/src/model/HistoricDataRequest.js +++ b/src/model/HistoricDataRequest.js @@ -16,7 +16,7 @@ import ApiClient from '../ApiClient'; /** * The HistoricDataRequest model module. * @module model/HistoricDataRequest - * @version 2.0.2 + * @version 2.0.3 */ class HistoricDataRequest { /** diff --git a/src/model/Override.js b/src/model/Override.js index 61eb80f..fd60dbc 100644 --- a/src/model/Override.js +++ b/src/model/Override.js @@ -16,7 +16,7 @@ import ApiClient from '../ApiClient'; /** * The Override model module. * @module model/Override - * @version 2.0.2 + * @version 2.0.3 */ class Override { /** diff --git a/src/model/PropertiesValue.js b/src/model/PropertiesValue.js index 8ac7e2e..784d401 100644 --- a/src/model/PropertiesValue.js +++ b/src/model/PropertiesValue.js @@ -16,7 +16,7 @@ import ApiClient from '../ApiClient'; /** * The PropertiesValue model module. * @module model/PropertiesValue - * @version 2.0.2 + * @version 2.0.3 */ class PropertiesValue { /** diff --git a/src/model/PropertiesValues.js b/src/model/PropertiesValues.js index 130d3dd..e74ba01 100644 --- a/src/model/PropertiesValues.js +++ b/src/model/PropertiesValues.js @@ -17,7 +17,7 @@ import PropertiesValue from './PropertiesValue'; /** * The PropertiesValues model module. * @module model/PropertiesValues - * @version 2.0.2 + * @version 2.0.3 */ class PropertiesValues { /** diff --git a/src/model/Property.js b/src/model/Property.js index 278f965..750eba0 100644 --- a/src/model/Property.js +++ b/src/model/Property.js @@ -16,7 +16,7 @@ import ApiClient from '../ApiClient'; /** * The Property model module. * @module model/Property - * @version 2.0.2 + * @version 2.0.3 */ class Property { /** diff --git a/src/model/PropertyValue.js b/src/model/PropertyValue.js index 12bdd55..e78d773 100644 --- a/src/model/PropertyValue.js +++ b/src/model/PropertyValue.js @@ -16,7 +16,7 @@ import ApiClient from '../ApiClient'; /** * The PropertyValue model module. * @module model/PropertyValue - * @version 2.0.2 + * @version 2.0.3 */ class PropertyValue { /** diff --git a/src/model/Sharerequest.js b/src/model/Sharerequest.js index bf10270..0b9c541 100644 --- a/src/model/Sharerequest.js +++ b/src/model/Sharerequest.js @@ -16,7 +16,7 @@ import ApiClient from '../ApiClient'; /** * The Sharerequest model module. * @module model/Sharerequest - * @version 2.0.2 + * @version 2.0.3 */ class Sharerequest { /** diff --git a/src/model/Tag.js b/src/model/Tag.js index 46fba38..f950aaf 100644 --- a/src/model/Tag.js +++ b/src/model/Tag.js @@ -16,7 +16,7 @@ import ApiClient from '../ApiClient'; /** * The Tag model module. * @module model/Tag - * @version 2.0.2 + * @version 2.0.3 */ class Tag { /** diff --git a/src/model/ThingClone.js b/src/model/ThingClone.js index fd29a8a..6916d53 100644 --- a/src/model/ThingClone.js +++ b/src/model/ThingClone.js @@ -16,7 +16,7 @@ import ApiClient from '../ApiClient'; /** * The ThingClone model module. * @module model/ThingClone - * @version 2.0.2 + * @version 2.0.3 */ class ThingClone { /** diff --git a/src/model/ThingCreate.js b/src/model/ThingCreate.js index b3ef146..778e317 100644 --- a/src/model/ThingCreate.js +++ b/src/model/ThingCreate.js @@ -18,7 +18,7 @@ import Tag from './Tag'; /** * The ThingCreate model module. * @module model/ThingCreate - * @version 2.0.2 + * @version 2.0.3 */ class ThingCreate { /** @@ -50,6 +50,9 @@ class ThingCreate { if (data) { obj = obj || new ThingCreate(); + if (data.hasOwnProperty('assistant')) { + obj['assistant'] = ApiClient.convertToType(data['assistant'], 'String'); + } if (data.hasOwnProperty('device_id')) { obj['device_id'] = ApiClient.convertToType(data['device_id'], 'String'); } @@ -84,6 +87,10 @@ class ThingCreate { * @return {boolean} to indicate whether the JSON data is valid with respect to ThingCreate. */ static validateJSON(data) { + // ensure the json data is a string + if (data['assistant'] && !(typeof data['assistant'] === 'string' || data['assistant'] instanceof String)) { + throw new Error("Expected the field `assistant` to be a primitive type in the JSON string but got " + data['assistant']); + } // ensure the json data is a string if (data['device_id'] && !(typeof data['device_id'] === 'string' || data['device_id'] instanceof String)) { throw new Error("Expected the field `device_id` to be a primitive type in the JSON string but got " + data['device_id']); @@ -133,6 +140,12 @@ class ThingCreate { +/** + * The kind of voice assistant the thing is connected to, it can be ALEXA | GOOGLE | NONE + * @member {module:model/ThingCreate.AssistantEnum} assistant + */ +ThingCreate.prototype['assistant'] = undefined; + /** * The arn of the associated device * @member {String} device_id @@ -186,6 +199,33 @@ ThingCreate.prototype['webhook_uri'] = undefined; +/** + * Allowed values for the assistant property. + * @enum {String} + * @readonly + */ +ThingCreate['AssistantEnum'] = { + + /** + * value: "ALEXA" + * @const + */ + "ALEXA": "ALEXA", + + /** + * value: "GOOGLE" + * @const + */ + "GOOGLE": "GOOGLE", + + /** + * value: "NONE" + * @const + */ + "NONE": "NONE" +}; + + export default ThingCreate; diff --git a/src/model/ThingSketch.js b/src/model/ThingSketch.js index 3d5e37f..3d96394 100644 --- a/src/model/ThingSketch.js +++ b/src/model/ThingSketch.js @@ -16,7 +16,7 @@ import ApiClient from '../ApiClient'; /** * The ThingSketch model module. * @module model/ThingSketch - * @version 2.0.2 + * @version 2.0.3 */ class ThingSketch { /** diff --git a/src/model/ThingUpdate.js b/src/model/ThingUpdate.js index 36f8572..39cb350 100644 --- a/src/model/ThingUpdate.js +++ b/src/model/ThingUpdate.js @@ -17,7 +17,7 @@ import Property from './Property'; /** * The ThingUpdate model module. * @module model/ThingUpdate - * @version 2.0.2 + * @version 2.0.3 */ class ThingUpdate { /** @@ -49,6 +49,9 @@ class ThingUpdate { if (data) { obj = obj || new ThingUpdate(); + if (data.hasOwnProperty('assistant')) { + obj['assistant'] = ApiClient.convertToType(data['assistant'], 'String'); + } if (data.hasOwnProperty('device_id')) { obj['device_id'] = ApiClient.convertToType(data['device_id'], 'String'); } @@ -80,6 +83,10 @@ class ThingUpdate { * @return {boolean} to indicate whether the JSON data is valid with respect to ThingUpdate. */ static validateJSON(data) { + // ensure the json data is a string + if (data['assistant'] && !(typeof data['assistant'] === 'string' || data['assistant'] instanceof String)) { + throw new Error("Expected the field `assistant` to be a primitive type in the JSON string but got " + data['assistant']); + } // ensure the json data is a string if (data['device_id'] && !(typeof data['device_id'] === 'string' || data['device_id'] instanceof String)) { throw new Error("Expected the field `device_id` to be a primitive type in the JSON string but got " + data['device_id']); @@ -119,6 +126,12 @@ class ThingUpdate { +/** + * The kind of voice assistant the thing is connected to, it can be ALEXA | GOOGLE | NONE + * @member {module:model/ThingUpdate.AssistantEnum} assistant + */ +ThingUpdate.prototype['assistant'] = undefined; + /** * The arn of the associated device * @member {String} device_id @@ -165,6 +178,33 @@ ThingUpdate.prototype['webhook_uri'] = undefined; +/** + * Allowed values for the assistant property. + * @enum {String} + * @readonly + */ +ThingUpdate['AssistantEnum'] = { + + /** + * value: "ALEXA" + * @const + */ + "ALEXA": "ALEXA", + + /** + * value: "GOOGLE" + * @const + */ + "GOOGLE": "GOOGLE", + + /** + * value: "NONE" + * @const + */ + "NONE": "NONE" +}; + + export default ThingUpdate; diff --git a/src/model/TimeseriesDataPoint.js b/src/model/TimeseriesDataPoint.js index f6eab69..d1e3cf3 100644 --- a/src/model/TimeseriesDataPoint.js +++ b/src/model/TimeseriesDataPoint.js @@ -16,7 +16,7 @@ import ApiClient from '../ApiClient'; /** * The TimeseriesDataPoint model module. * @module model/TimeseriesDataPoint - * @version 2.0.2 + * @version 2.0.3 */ class TimeseriesDataPoint { /** diff --git a/src/model/UpdateSketch.js b/src/model/UpdateSketch.js index ab89fe2..7689fea 100644 --- a/src/model/UpdateSketch.js +++ b/src/model/UpdateSketch.js @@ -16,7 +16,7 @@ import ApiClient from '../ApiClient'; /** * The UpdateSketch model module. * @module model/UpdateSketch - * @version 2.0.2 + * @version 2.0.3 */ class UpdateSketch { /** diff --git a/src/model/Widget.js b/src/model/Widget.js index 003a137..a05da55 100644 --- a/src/model/Widget.js +++ b/src/model/Widget.js @@ -16,7 +16,7 @@ import ApiClient from '../ApiClient'; /** * The Widget model module. * @module model/Widget - * @version 2.0.2 + * @version 2.0.3 */ class Widget { /** diff --git a/src/model/Widgetlink.js b/src/model/Widgetlink.js index b4227d9..7e172cf 100644 --- a/src/model/Widgetlink.js +++ b/src/model/Widgetlink.js @@ -16,7 +16,7 @@ import ApiClient from '../ApiClient'; /** * The Widgetlink model module. * @module model/Widgetlink - * @version 2.0.2 + * @version 2.0.3 */ class Widgetlink { /**