Skip to content

Commit d9626c8

Browse files
committed
Updated with build b2c35369-4e71-45f5-8a07-89d5ec37546a from OmniCore-SDK-Generator commit 7df38a2e812a31c4a31869db42c92a58da24b223
1 parent 9d5e2e0 commit d9626c8

File tree

147 files changed

+838
-211
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

147 files changed

+838
-211
lines changed

README.md

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -3,8 +3,8 @@
33
OmniCoreModelAndStateManagementApi - JavaScript client for omni_core_model_and_state_management_api
44
This is an OmniCore Model and State Management server.
55

6-
- API version: 1.8.7
7-
- Package version: 1.8.7
6+
- API version: 1.8.10
7+
- Package version: 1.8.10
88
- Build package: org.openapitools.codegen.languages.JavascriptClientCodegen
99
For more information, please visit [http://www.korewireless.com](http://www.korewireless.com)
1010

@@ -140,6 +140,7 @@ Class | Method | HTTP request | Description
140140
*OmniCoreModelAndStateManagementApi.DeviceApi* | [**getDevice**](docs/DeviceApi.md#getDevice) | **GET** /omnicore/subscriptions/{subscriptionId}/registries/{registryId}/devices/{deviceId} |
141141
*OmniCoreModelAndStateManagementApi.DeviceApi* | [**getDevices**](docs/DeviceApi.md#getDevices) | **GET** /omnicore/subscriptions/{subscriptionId}/registries/{registryId}/devices |
142142
*OmniCoreModelAndStateManagementApi.DeviceApi* | [**getStates**](docs/DeviceApi.md#getStates) | **GET** /omnicore/subscriptions/{subscriptionid}/registries/{registryId}/devices/{deviceId}/states |
143+
*OmniCoreModelAndStateManagementApi.DeviceApi* | [**getSubscriptionDevices**](docs/DeviceApi.md#getSubscriptionDevices) | **GET** /omnicore/subscriptions/{subscriptionId}/devices |
143144
*OmniCoreModelAndStateManagementApi.DeviceApi* | [**sendCommandToDevice**](docs/DeviceApi.md#sendCommandToDevice) | **POST** /omnicore/subscriptions/{subscriptionid}/registries/{registryId}/devices/{deviceId}/sendCommandToDevice |
144145
*OmniCoreModelAndStateManagementApi.DeviceApi* | [**unBindDevice**](docs/DeviceApi.md#unBindDevice) | **POST** /omnicore/subscriptions/{subscriptionId}/registries/{registryId}/unbindDeviceFromGateway |
145146
*OmniCoreModelAndStateManagementApi.DeviceApi* | [**unBindDevices**](docs/DeviceApi.md#unBindDevices) | **POST** /omnicore/subscriptions/{subscriptionId}/registries/{registryId}/unbindDevicesFromGateway |
@@ -193,6 +194,7 @@ Class | Method | HTTP request | Description
193194
- [OmniCoreModelAndStateManagementApi.DeviceConfig](docs/DeviceConfig.md)
194195
- [OmniCoreModelAndStateManagementApi.DeviceConfiguration](docs/DeviceConfiguration.md)
195196
- [OmniCoreModelAndStateManagementApi.DeviceCredential](docs/DeviceCredential.md)
197+
- [OmniCoreModelAndStateManagementApi.DeviceOnline](docs/DeviceOnline.md)
196198
- [OmniCoreModelAndStateManagementApi.DeviceRegistry](docs/DeviceRegistry.md)
197199
- [OmniCoreModelAndStateManagementApi.DeviceState](docs/DeviceState.md)
198200
- [OmniCoreModelAndStateManagementApi.EnableEncryptionBody](docs/EnableEncryptionBody.md)
@@ -215,6 +217,7 @@ Class | Method | HTTP request | Description
215217
- [OmniCoreModelAndStateManagementApi.ListDeviceConfigVersionsResponse](docs/ListDeviceConfigVersionsResponse.md)
216218
- [OmniCoreModelAndStateManagementApi.ListDeviceRegistries](docs/ListDeviceRegistries.md)
217219
- [OmniCoreModelAndStateManagementApi.ListDeviceStatesResponse](docs/ListDeviceStatesResponse.md)
220+
- [OmniCoreModelAndStateManagementApi.ListDevicesOnlineResponse](docs/ListDevicesOnlineResponse.md)
218221
- [OmniCoreModelAndStateManagementApi.ListDevicesResponse](docs/ListDevicesResponse.md)
219222
- [OmniCoreModelAndStateManagementApi.ListSinks](docs/ListSinks.md)
220223
- [OmniCoreModelAndStateManagementApi.LogLevel](docs/LogLevel.md)

docs/DeviceApi.md

Lines changed: 75 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -13,6 +13,7 @@ Method | HTTP request | Description
1313
[**getDevice**](DeviceApi.md#getDevice) | **GET** /omnicore/subscriptions/{subscriptionId}/registries/{registryId}/devices/{deviceId} |
1414
[**getDevices**](DeviceApi.md#getDevices) | **GET** /omnicore/subscriptions/{subscriptionId}/registries/{registryId}/devices |
1515
[**getStates**](DeviceApi.md#getStates) | **GET** /omnicore/subscriptions/{subscriptionid}/registries/{registryId}/devices/{deviceId}/states |
16+
[**getSubscriptionDevices**](DeviceApi.md#getSubscriptionDevices) | **GET** /omnicore/subscriptions/{subscriptionId}/devices |
1617
[**sendCommandToDevice**](DeviceApi.md#sendCommandToDevice) | **POST** /omnicore/subscriptions/{subscriptionid}/registries/{registryId}/devices/{deviceId}/sendCommandToDevice |
1718
[**unBindDevice**](DeviceApi.md#unBindDevice) | **POST** /omnicore/subscriptions/{subscriptionId}/registries/{registryId}/unbindDeviceFromGateway |
1819
[**unBindDevices**](DeviceApi.md#unBindDevices) | **POST** /omnicore/subscriptions/{subscriptionId}/registries/{registryId}/unbindDevicesFromGateway |
@@ -570,6 +571,80 @@ Name | Type | Description | Notes
570571
- **Accept**: application/json
571572

572573

574+
## getSubscriptionDevices
575+
576+
> ListDevicesOnlineResponse getSubscriptionDevices(subscriptionId, opts)
577+
578+
579+
580+
Get all devices under a subscription
581+
582+
### Example
583+
584+
```javascript
585+
import OmniCoreModelAndStateManagementApi from 'omni_core_model_and_state_management_api';
586+
let defaultClient = OmniCoreModelAndStateManagementApi.ApiClient.instance;
587+
// Configure API key authorization: apiKey
588+
let apiKey = defaultClient.authentications['apiKey'];
589+
apiKey.apiKey = 'YOUR API KEY';
590+
// Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null)
591+
//apiKey.apiKeyPrefix = 'Token';
592+
// Configure Bearer (JWT) access token for authorization: bearerAuth
593+
let bearerAuth = defaultClient.authentications['bearerAuth'];
594+
bearerAuth.accessToken = "YOUR ACCESS TOKEN"
595+
596+
let apiInstance = new OmniCoreModelAndStateManagementApi.DeviceApi();
597+
let subscriptionId = "subscriptionId_example"; // String | Subscription ID
598+
let opts = {
599+
'pageNumber': 56, // Number | Page Number
600+
'pageSize': 56, // Number | The maximum number of devices to return in the response. If this value is zero, the service will select a default size.
601+
'fieldMask': "fieldMask_example", // String | The fields of the Device resource to be returned to the response. The fields id and numId are always returned, along with any other fields specified. A comma-separated list of fully qualified names of fields. Example:
602+
'sortByClientOnline': true, // Boolean | Set to true to return devices sorted by last heartbeat
603+
'deviceIds': ["null"], // [String] | A list of device string IDs. For example, ['device0', 'device12']. If empty, this field is ignored. Maximum IDs: 10,000
604+
'deviceNumIds': ["null"], // [String] | A list of device numeric IDs. If empty, this field is ignored. Maximum IDs: 10,000.
605+
'gatewayListOptionsAssociationsDeviceId': "gatewayListOptionsAssociationsDeviceId_example", // String | If set, returns only the gateways with which the specified device is associated. The device ID can be numeric (num_id) or the user-defined string (id). For example, if 456 is specified, returns only the gateways to which the device with num_id 456 is bound.
606+
'gatewayListOptionsAssociationsGatewayId': "gatewayListOptionsAssociationsGatewayId_example", // String | If set, only devices associated with the specified gateway are returned. The gateway ID can be numeric (num_id) or the user-defined string (id). For example, if 123 is specified, only devices bound to the gateway with num_id 123 are returned
607+
'gatewayListOptionsGatewayType': "gatewayListOptionsGatewayType_example" // String | If GATEWAY is specified, only gateways are returned. If NON_GATEWAY is specified, only non-gateway devices are returned. If GATEWAY_TYPE_UNSPECIFIED is specified, all devices are returned.
608+
};
609+
apiInstance.getSubscriptionDevices(subscriptionId, opts, (error, data, response) => {
610+
if (error) {
611+
console.error(error);
612+
} else {
613+
console.log('API called successfully. Returned data: ' + data);
614+
}
615+
});
616+
```
617+
618+
### Parameters
619+
620+
621+
Name | Type | Description | Notes
622+
------------- | ------------- | ------------- | -------------
623+
**subscriptionId** | **String**| Subscription ID |
624+
**pageNumber** | **Number**| Page Number | [optional]
625+
**pageSize** | **Number**| The maximum number of devices to return in the response. If this value is zero, the service will select a default size. | [optional]
626+
**fieldMask** | **String**| The fields of the Device resource to be returned to the response. The fields id and numId are always returned, along with any other fields specified. A comma-separated list of fully qualified names of fields. Example: | [optional]
627+
**sortByClientOnline** | **Boolean**| Set to true to return devices sorted by last heartbeat | [optional]
628+
**deviceIds** | [**[String]**](String.md)| A list of device string IDs. For example, ['device0', 'device12']. If empty, this field is ignored. Maximum IDs: 10,000 | [optional]
629+
**deviceNumIds** | [**[String]**](String.md)| A list of device numeric IDs. If empty, this field is ignored. Maximum IDs: 10,000. | [optional]
630+
**gatewayListOptionsAssociationsDeviceId** | **String**| If set, returns only the gateways with which the specified device is associated. The device ID can be numeric (num_id) or the user-defined string (id). For example, if 456 is specified, returns only the gateways to which the device with num_id 456 is bound. | [optional]
631+
**gatewayListOptionsAssociationsGatewayId** | **String**| If set, only devices associated with the specified gateway are returned. The gateway ID can be numeric (num_id) or the user-defined string (id). For example, if 123 is specified, only devices bound to the gateway with num_id 123 are returned | [optional]
632+
**gatewayListOptionsGatewayType** | **String**| If GATEWAY is specified, only gateways are returned. If NON_GATEWAY is specified, only non-gateway devices are returned. If GATEWAY_TYPE_UNSPECIFIED is specified, all devices are returned. | [optional]
633+
634+
### Return type
635+
636+
[**ListDevicesOnlineResponse**](ListDevicesOnlineResponse.md)
637+
638+
### Authorization
639+
640+
[apiKey](../README.md#apiKey), [bearerAuth](../README.md#bearerAuth)
641+
642+
### HTTP request headers
643+
644+
- **Content-Type**: Not defined
645+
- **Accept**: application/json
646+
647+
573648
## sendCommandToDevice
574649

575650
> Object sendCommandToDevice(subscriptionid, registryId, deviceId, command)

docs/DeviceOnline.md

Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,13 @@
1+
# OmniCoreModelAndStateManagementApi.DeviceOnline
2+
3+
## Properties
4+
5+
Name | Type | Description | Notes
6+
------------ | ------------- | ------------- | -------------
7+
**id** | **String** | |
8+
**registry** | **String** | | [optional] [readonly]
9+
**clientOnline** | **Boolean** | | [optional] [readonly]
10+
**lastHeartbeatTime** | **String** | | [optional] [readonly]
11+
**subscription** | **String** | | [optional] [readonly]
12+
13+

docs/ListDevicesOnlineResponse.md

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,12 @@
1+
# OmniCoreModelAndStateManagementApi.ListDevicesOnlineResponse
2+
3+
## Properties
4+
5+
Name | Type | Description | Notes
6+
------------ | ------------- | ------------- | -------------
7+
**devices** | [**[DeviceOnline]**](DeviceOnline.md) | |
8+
**pageNumber** | **Number** | | [optional]
9+
**pageSize** | **Number** | | [optional]
10+
**totalCount** | **Number** | | [optional]
11+
12+

package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "omni_core_model_and_state_management_api",
3-
"version": "1.8.7",
3+
"version": "1.8.10",
44
"description": "This is an OmniCore Model and State Management server.",
55
"license": "Unlicense",
66
"main": "dist/index.js",

src/ApiClient.js

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
* OmniCore Model and State Management API
33
* This is an OmniCore Model and State Management server.
44
*
5-
* The version of the OpenAPI document: 1.8.7
5+
* The version of the OpenAPI document: 1.8.10
66
* Contact: [email protected]
77
*
88
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
@@ -17,7 +17,7 @@ import querystring from "querystring";
1717

1818
/**
1919
* @module ApiClient
20-
* @version 1.8.7
20+
* @version 1.8.10
2121
*/
2222

2323
/**
@@ -56,7 +56,7 @@ class ApiClient {
5656
* @default {}
5757
*/
5858
this.defaultHeaders = {
59-
'User-Agent': 'OpenAPI-Generator/1.8.7/Javascript'
59+
'User-Agent': 'OpenAPI-Generator/1.8.10/Javascript'
6060
};
6161

6262
/**

src/api/DeviceApi.js

Lines changed: 65 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
* OmniCore Model and State Management API
33
* This is an OmniCore Model and State Management server.
44
*
5-
* The version of the OpenAPI document: 1.8.7
5+
* The version of the OpenAPI document: 1.8.10
66
* Contact: [email protected]
77
*
88
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
@@ -25,12 +25,13 @@ import GenericErrorResponse from '../model/GenericErrorResponse';
2525
import Info from '../model/Info';
2626
import ListDeviceConfigVersionsResponse from '../model/ListDeviceConfigVersionsResponse';
2727
import ListDeviceStatesResponse from '../model/ListDeviceStatesResponse';
28+
import ListDevicesOnlineResponse from '../model/ListDevicesOnlineResponse';
2829
import ListDevicesResponse from '../model/ListDevicesResponse';
2930

3031
/**
3132
* Device service.
3233
* @module api/DeviceApi
33-
* @version 1.8.7
34+
* @version 1.8.10
3435
*/
3536
export default class DeviceApi {
3637

@@ -554,6 +555,68 @@ export default class DeviceApi {
554555
);
555556
}
556557

558+
/**
559+
* Callback function to receive the result of the getSubscriptionDevices operation.
560+
* @callback module:api/DeviceApi~getSubscriptionDevicesCallback
561+
* @param {String} error Error message, if any.
562+
* @param {module:model/ListDevicesOnlineResponse} data The data returned by the service call.
563+
* @param {String} response The complete HTTP response.
564+
*/
565+
566+
/**
567+
* Get all devices under a subscription
568+
* @param {String} subscriptionId Subscription ID
569+
* @param {Object} opts Optional parameters
570+
* @param {Number} opts.pageNumber Page Number
571+
* @param {Number} opts.pageSize The maximum number of devices to return in the response. If this value is zero, the service will select a default size.
572+
* @param {String} opts.fieldMask The fields of the Device resource to be returned to the response. The fields id and numId are always returned, along with any other fields specified. A comma-separated list of fully qualified names of fields. Example:
573+
* @param {Boolean} opts.sortByClientOnline Set to true to return devices sorted by last heartbeat
574+
* @param {Array.<String>} opts.deviceIds A list of device string IDs. For example, ['device0', 'device12']. If empty, this field is ignored. Maximum IDs: 10,000
575+
* @param {Array.<String>} opts.deviceNumIds A list of device numeric IDs. If empty, this field is ignored. Maximum IDs: 10,000.
576+
* @param {String} opts.gatewayListOptionsAssociationsDeviceId If set, returns only the gateways with which the specified device is associated. The device ID can be numeric (num_id) or the user-defined string (id). For example, if 456 is specified, returns only the gateways to which the device with num_id 456 is bound.
577+
* @param {String} opts.gatewayListOptionsAssociationsGatewayId If set, only devices associated with the specified gateway are returned. The gateway ID can be numeric (num_id) or the user-defined string (id). For example, if 123 is specified, only devices bound to the gateway with num_id 123 are returned
578+
* @param {String} opts.gatewayListOptionsGatewayType If GATEWAY is specified, only gateways are returned. If NON_GATEWAY is specified, only non-gateway devices are returned. If GATEWAY_TYPE_UNSPECIFIED is specified, all devices are returned.
579+
* @param {module:api/DeviceApi~getSubscriptionDevicesCallback} callback The callback function, accepting three arguments: error, data, response
580+
* data is of type: {@link module:model/ListDevicesOnlineResponse}
581+
*/
582+
getSubscriptionDevices(subscriptionId, opts, callback) {
583+
opts = opts || {};
584+
let postBody = null;
585+
// verify the required parameter 'subscriptionId' is set
586+
if (subscriptionId === undefined || subscriptionId === null) {
587+
throw new Error("Missing the required parameter 'subscriptionId' when calling getSubscriptionDevices");
588+
}
589+
590+
let pathParams = {
591+
'subscriptionId': subscriptionId
592+
};
593+
let queryParams = {
594+
'pageNumber': opts['pageNumber'],
595+
'pageSize': opts['pageSize'],
596+
'fieldMask': opts['fieldMask'],
597+
'sortByClientOnline': opts['sortByClientOnline'],
598+
'deviceIds': this.apiClient.buildCollectionParam(opts['deviceIds'], 'csv'),
599+
'deviceNumIds': this.apiClient.buildCollectionParam(opts['deviceNumIds'], 'csv'),
600+
'gatewayListOptions.associationsDeviceId': opts['gatewayListOptionsAssociationsDeviceId'],
601+
'gatewayListOptions.associationsGatewayId': opts['gatewayListOptionsAssociationsGatewayId'],
602+
'gatewayListOptions.gatewayType': opts['gatewayListOptionsGatewayType']
603+
};
604+
let headerParams = {
605+
};
606+
let formParams = {
607+
};
608+
609+
let authNames = ['apiKey', 'bearerAuth'];
610+
let contentTypes = [];
611+
let accepts = ['application/json'];
612+
let returnType = ListDevicesOnlineResponse;
613+
return this.apiClient.callApi(
614+
'/omnicore/subscriptions/{subscriptionId}/devices', 'GET',
615+
pathParams, queryParams, headerParams, formParams, postBody,
616+
authNames, contentTypes, accepts, returnType, null, callback
617+
);
618+
}
619+
557620
/**
558621
* Callback function to receive the result of the sendCommandToDevice operation.
559622
* @callback module:api/DeviceApi~sendCommandToDeviceCallback

src/api/MetricsApi.js

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
* OmniCore Model and State Management API
33
* This is an OmniCore Model and State Management server.
44
*
5-
* The version of the OpenAPI document: 1.8.7
5+
* The version of the OpenAPI document: 1.8.10
66
* Contact: [email protected]
77
*
88
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
@@ -19,7 +19,7 @@ import Metrics from '../model/Metrics';
1919
/**
2020
* Metrics service.
2121
* @module api/MetricsApi
22-
* @version 1.8.7
22+
* @version 1.8.10
2323
*/
2424
export default class MetricsApi {
2525

src/api/RegistryApi.js

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
* OmniCore Model and State Management API
33
* This is an OmniCore Model and State Management server.
44
*
5-
* The version of the OpenAPI document: 1.8.7
5+
* The version of the OpenAPI document: 1.8.10
66
* Contact: [email protected]
77
*
88
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
@@ -22,7 +22,7 @@ import ListDeviceRegistries from '../model/ListDeviceRegistries';
2222
/**
2323
* Registry service.
2424
* @module api/RegistryApi
25-
* @version 1.8.7
25+
* @version 1.8.10
2626
*/
2727
export default class RegistryApi {
2828

src/api/SinkApi.js

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
* OmniCore Model and State Management API
33
* This is an OmniCore Model and State Management server.
44
*
5-
* The version of the OpenAPI document: 1.8.7
5+
* The version of the OpenAPI document: 1.8.10
66
* Contact: [email protected]
77
*
88
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
@@ -20,7 +20,7 @@ import Sink from '../model/Sink';
2020
/**
2121
* Sink service.
2222
* @module api/SinkApi
23-
* @version 1.8.7
23+
* @version 1.8.10
2424
*/
2525
export default class SinkApi {
2626

0 commit comments

Comments
 (0)