artikcloud 2.1.1 → 2.2.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/README.md +44 -3
- data/artikcloud.gemspec +3 -4
- data/docs/ActionOut.md +6 -0
- data/docs/CertificateData.md +9 -0
- data/docs/CertificateEnvelope.md +8 -0
- data/docs/CertificateFields.md +13 -0
- data/docs/CertificateId.md +8 -0
- data/docs/ContactInfo.md +9 -0
- data/docs/DevicePricingTier.md +16 -0
- data/docs/DevicePricingTierEnvelope.md +8 -0
- data/docs/DevicePricingTierRequest.md +8 -0
- data/docs/DevicePricingTiers.md +8 -0
- data/docs/DevicePricingTiersEnvelope.md +8 -0
- data/docs/DeviceShareInfo.md +1 -1
- data/docs/DeviceTypePricingList.md +8 -0
- data/docs/DeviceTypePricingTier.md +17 -0
- data/docs/DeviceTypePricingTiersEnvelope.md +8 -0
- data/docs/DeviceTypeUpdateInput.md +8 -0
- data/docs/DevicesSharesApi.md +235 -0
- data/docs/DevicesStatusApi.md +183 -0
- data/docs/MessageOut.md +6 -0
- data/docs/MonetizationApi.md +289 -0
- data/docs/OutputRule.md +1 -0
- data/docs/RejectedCSVRow.md +8 -0
- data/docs/RejectedCSVRowsEnvelope.md +11 -0
- data/docs/Tier.md +17 -0
- data/docs/UpgradePath.md +8 -0
- data/docs/UpgradePathEnvelope.md +8 -0
- data/docs/UpgradePathUserToken.md +10 -0
- data/docs/UpgradePathUserTokenEnvelope.md +8 -0
- data/docs/UploadIdEnvelope.md +8 -0
- data/docs/UploadStatusEnvelope.md +8 -0
- data/docs/UsersApi.md +6 -2
- data/docs/ValidityPeriod.md +9 -0
- data/docs/Whitelist.md +10 -0
- data/docs/WhitelistEnvelope.md +8 -0
- data/docs/WhitelistResultEnvelope.md +12 -0
- data/docs/WhitelistingApi.md +515 -0
- data/lib/artikcloud/api/monetization_api.rb +296 -0
- data/lib/artikcloud/api/users_api.rb +3 -0
- data/lib/artikcloud/api/whitelisting_api.rb +519 -0
- data/lib/artikcloud/models/action_out.rb +62 -1
- data/lib/artikcloud/models/certificate_data.rb +197 -0
- data/lib/artikcloud/models/certificate_envelope.rb +188 -0
- data/lib/artikcloud/models/certificate_fields.rb +237 -0
- data/lib/artikcloud/models/certificate_id.rb +188 -0
- data/lib/artikcloud/models/contact_info.rb +198 -0
- data/lib/artikcloud/models/device_pricing_tier.rb +268 -0
- data/lib/artikcloud/models/device_pricing_tier_envelope.rb +188 -0
- data/lib/artikcloud/models/device_pricing_tier_request.rb +188 -0
- data/lib/artikcloud/models/device_pricing_tiers.rb +190 -0
- data/lib/artikcloud/models/device_pricing_tiers_envelope.rb +188 -0
- data/lib/artikcloud/models/device_share_info.rb +7 -7
- data/lib/artikcloud/models/device_type_pricing_list.rb +190 -0
- data/lib/artikcloud/models/device_type_pricing_tier.rb +280 -0
- data/lib/artikcloud/models/device_type_pricing_tiers_envelope.rb +188 -0
- data/lib/artikcloud/models/device_type_update_input.rb +188 -0
- data/lib/artikcloud/models/message_out.rb +65 -1
- data/lib/artikcloud/models/output_rule.rb +46 -4
- data/lib/artikcloud/models/rejected_csv_row.rb +188 -0
- data/lib/artikcloud/models/rejected_csv_rows_envelope.rb +220 -0
- data/lib/artikcloud/models/tier.rb +278 -0
- data/lib/artikcloud/models/upgrade_path.rb +188 -0
- data/lib/artikcloud/models/upgrade_path_envelope.rb +188 -0
- data/lib/artikcloud/models/upgrade_path_user_token.rb +208 -0
- data/lib/artikcloud/models/upgrade_path_user_token_envelope.rb +187 -0
- data/lib/artikcloud/models/upload_id_envelope.rb +188 -0
- data/lib/artikcloud/models/upload_status_envelope.rb +188 -0
- data/lib/artikcloud/models/validity_period.rb +198 -0
- data/lib/artikcloud/models/whitelist.rb +208 -0
- data/lib/artikcloud/models/whitelist_envelope.rb +190 -0
- data/lib/artikcloud/models/whitelist_result_envelope.rb +230 -0
- data/lib/artikcloud/version.rb +1 -2
- data/lib/artikcloud.rb +33 -3
- data/pom.xml +1 -1
- data/spec/api/device_types_api_spec.rb +3 -15
- data/spec/api/devices_api_spec.rb +6 -22
- data/spec/api/devices_management_api_spec.rb +1 -13
- data/spec/api/export_api_spec.rb +2 -14
- data/spec/api/messages_api_spec.rb +115 -74
- data/spec/api/monetization_api_spec.rb +99 -0
- data/spec/api/registrations_api_spec.rb +1 -13
- data/spec/api/rules_api_spec.rb +3 -15
- data/spec/api/tags_api_spec.rb +0 -12
- data/spec/api/tokens_api_spec.rb +24 -14
- data/spec/api/users_api_spec.rb +119 -57
- data/spec/api/whitelisting_api_spec.rb +152 -0
- data/spec/factories/users.rb +12 -12
- data/spec/models/action_out_spec.rb +36 -0
- data/spec/models/certificate_data_spec.rb +47 -0
- data/spec/models/certificate_envelope_spec.rb +41 -0
- data/spec/models/certificate_fields_spec.rb +71 -0
- data/spec/models/certificate_id_spec.rb +41 -0
- data/spec/models/contact_info_spec.rb +47 -0
- data/spec/models/device_pricing_tier_envelope_spec.rb +41 -0
- data/spec/models/device_pricing_tier_request_spec.rb +41 -0
- data/spec/models/device_pricing_tier_spec.rb +89 -0
- data/spec/models/device_pricing_tiers_envelope_spec.rb +41 -0
- data/spec/models/device_pricing_tiers_spec.rb +41 -0
- data/spec/models/device_share_info_spec.rb +1 -1
- data/spec/models/device_type_pricing_list_spec.rb +41 -0
- data/spec/models/device_type_pricing_tier_spec.rb +95 -0
- data/spec/models/device_type_pricing_tiers_envelope_spec.rb +41 -0
- data/spec/models/device_type_update_input_spec.rb +41 -0
- data/spec/models/message_out_spec.rb +36 -0
- data/spec/models/output_rule_spec.rb +10 -0
- data/spec/models/rejected_csv_row_spec.rb +41 -0
- data/spec/models/rejected_csv_rows_envelope_spec.rb +59 -0
- data/spec/models/tier_spec.rb +95 -0
- data/spec/models/upgrade_path_envelope_spec.rb +41 -0
- data/spec/models/upgrade_path_spec.rb +41 -0
- data/spec/models/upgrade_path_user_token_envelope_spec.rb +41 -0
- data/spec/models/upgrade_path_user_token_spec.rb +53 -0
- data/spec/models/upload_id_envelope_spec.rb +41 -0
- data/spec/models/upload_status_envelope_spec.rb +41 -0
- data/spec/models/validity_period_spec.rb +47 -0
- data/spec/models/whitelist_envelope_spec.rb +41 -0
- data/spec/models/whitelist_result_envelope_spec.rb +65 -0
- data/spec/models/whitelist_spec.rb +53 -0
- metadata +121 -11
- data/docs/.DS_Store +0 -0
- data/lib/.DS_Store +0 -0
- data/lib/artikcloud/.DS_Store +0 -0
- data/lib/artikcloud/api/.DS_Store +0 -0
- data/lib/artikcloud/models/.DS_Store +0 -0
- data/spec/.DS_Store +0 -0
- data/spec/api/.DS_Store +0 -0
|
@@ -0,0 +1,515 @@
|
|
|
1
|
+
# ArtikCloud::WhitelistingApi
|
|
2
|
+
|
|
3
|
+
All URIs are relative to *https://api.artik.cloud/v1.1*
|
|
4
|
+
|
|
5
|
+
Method | HTTP request | Description
|
|
6
|
+
------------- | ------------- | -------------
|
|
7
|
+
[**delete_vdid**](WhitelistingApi.md#delete_vdid) | **DELETE** /devicetypes/{dtid}/whitelist/{vdid} | Delete a vdid from the devicetype whitelist.
|
|
8
|
+
[**delete_whitelist_certificate**](WhitelistingApi.md#delete_whitelist_certificate) | **DELETE** /devicetypes/{dtid}/whitelist/certificates/{cid} | Delete a whitelist certificate associated with a devicetype.
|
|
9
|
+
[**enable_whitelist**](WhitelistingApi.md#enable_whitelist) | **PUT** /devicetypes/:dtid/whitelist/enable | Enable or disble whitelist feature of a device type
|
|
10
|
+
[**get_rejected_row_list**](WhitelistingApi.md#get_rejected_row_list) | **GET** /devicetypes/{dtid}/whitelist/{uploadId}/rejectedRows | Get the list of rejected rows for an uploaded CSV file.
|
|
11
|
+
[**get_upload_status**](WhitelistingApi.md#get_upload_status) | **GET** /devicetypes/{dtid}/whitelist/{uploadId}/status | Get the status of a uploaded CSV file.
|
|
12
|
+
[**get_whitelist**](WhitelistingApi.md#get_whitelist) | **GET** /devicetypes/{dtid}/whitelist | Get whitelisted vdids of a device type.
|
|
13
|
+
[**get_whitelist_certificate**](WhitelistingApi.md#get_whitelist_certificate) | **GET** /devicetypes/{dtid}/whitelist/certificates | Get whitelist certificate of device type.
|
|
14
|
+
[**get_whitelist_status**](WhitelistingApi.md#get_whitelist_status) | **GET** /devicetypes/{dtid}/whitelist/status | Get the status of whitelist feature (enabled/disabled) of a device type.
|
|
15
|
+
[**upload_csv**](WhitelistingApi.md#upload_csv) | **POST** /devicetypes/{dtid}/whitelist | Upload a CSV file related to the Device Type.
|
|
16
|
+
|
|
17
|
+
|
|
18
|
+
# **delete_vdid**
|
|
19
|
+
> WhitelistEnvelope delete_vdid(dtid, vdid)
|
|
20
|
+
|
|
21
|
+
Delete a vdid from the devicetype whitelist.
|
|
22
|
+
|
|
23
|
+
Delete a vdid from the devicetype whitelist.
|
|
24
|
+
|
|
25
|
+
### Example
|
|
26
|
+
```ruby
|
|
27
|
+
# load the gem
|
|
28
|
+
require 'artikcloud'
|
|
29
|
+
# setup authorization
|
|
30
|
+
ArtikCloud.configure do |config|
|
|
31
|
+
# Configure OAuth2 access token for authorization: artikcloud_oauth
|
|
32
|
+
config.access_token = 'YOUR ACCESS TOKEN'
|
|
33
|
+
end
|
|
34
|
+
|
|
35
|
+
api_instance = ArtikCloud::WhitelistingApi.new
|
|
36
|
+
|
|
37
|
+
dtid = "dtid_example" # String | Device Type ID.
|
|
38
|
+
|
|
39
|
+
vdid = "vdid_example" # String | Vendor Device ID.
|
|
40
|
+
|
|
41
|
+
|
|
42
|
+
begin
|
|
43
|
+
#Delete a vdid from the devicetype whitelist.
|
|
44
|
+
result = api_instance.delete_vdid(dtid, vdid)
|
|
45
|
+
p result
|
|
46
|
+
rescue ArtikCloud::ApiError => e
|
|
47
|
+
puts "Exception when calling WhitelistingApi->delete_vdid: #{e}"
|
|
48
|
+
end
|
|
49
|
+
```
|
|
50
|
+
|
|
51
|
+
### Parameters
|
|
52
|
+
|
|
53
|
+
Name | Type | Description | Notes
|
|
54
|
+
------------- | ------------- | ------------- | -------------
|
|
55
|
+
**dtid** | **String**| Device Type ID. |
|
|
56
|
+
**vdid** | **String**| Vendor Device ID. |
|
|
57
|
+
|
|
58
|
+
### Return type
|
|
59
|
+
|
|
60
|
+
[**WhitelistEnvelope**](WhitelistEnvelope.md)
|
|
61
|
+
|
|
62
|
+
### Authorization
|
|
63
|
+
|
|
64
|
+
[artikcloud_oauth](../README.md#artikcloud_oauth)
|
|
65
|
+
|
|
66
|
+
### HTTP request headers
|
|
67
|
+
|
|
68
|
+
- **Content-Type**: Not defined
|
|
69
|
+
- **Accept**: application/json
|
|
70
|
+
|
|
71
|
+
|
|
72
|
+
|
|
73
|
+
# **delete_whitelist_certificate**
|
|
74
|
+
> WhitelistEnvelope delete_whitelist_certificate(dtid, cid)
|
|
75
|
+
|
|
76
|
+
Delete a whitelist certificate associated with a devicetype.
|
|
77
|
+
|
|
78
|
+
Delete a whitelist certificate associated with a devicetype.
|
|
79
|
+
|
|
80
|
+
### Example
|
|
81
|
+
```ruby
|
|
82
|
+
# load the gem
|
|
83
|
+
require 'artikcloud'
|
|
84
|
+
# setup authorization
|
|
85
|
+
ArtikCloud.configure do |config|
|
|
86
|
+
# Configure OAuth2 access token for authorization: artikcloud_oauth
|
|
87
|
+
config.access_token = 'YOUR ACCESS TOKEN'
|
|
88
|
+
end
|
|
89
|
+
|
|
90
|
+
api_instance = ArtikCloud::WhitelistingApi.new
|
|
91
|
+
|
|
92
|
+
dtid = "dtid_example" # String | Device Type ID.
|
|
93
|
+
|
|
94
|
+
cid = "cid_example" # String | Certificate ID.
|
|
95
|
+
|
|
96
|
+
|
|
97
|
+
begin
|
|
98
|
+
#Delete a whitelist certificate associated with a devicetype.
|
|
99
|
+
result = api_instance.delete_whitelist_certificate(dtid, cid)
|
|
100
|
+
p result
|
|
101
|
+
rescue ArtikCloud::ApiError => e
|
|
102
|
+
puts "Exception when calling WhitelistingApi->delete_whitelist_certificate: #{e}"
|
|
103
|
+
end
|
|
104
|
+
```
|
|
105
|
+
|
|
106
|
+
### Parameters
|
|
107
|
+
|
|
108
|
+
Name | Type | Description | Notes
|
|
109
|
+
------------- | ------------- | ------------- | -------------
|
|
110
|
+
**dtid** | **String**| Device Type ID. |
|
|
111
|
+
**cid** | **String**| Certificate ID. |
|
|
112
|
+
|
|
113
|
+
### Return type
|
|
114
|
+
|
|
115
|
+
[**WhitelistEnvelope**](WhitelistEnvelope.md)
|
|
116
|
+
|
|
117
|
+
### Authorization
|
|
118
|
+
|
|
119
|
+
[artikcloud_oauth](../README.md#artikcloud_oauth)
|
|
120
|
+
|
|
121
|
+
### HTTP request headers
|
|
122
|
+
|
|
123
|
+
- **Content-Type**: Not defined
|
|
124
|
+
- **Accept**: application/json
|
|
125
|
+
|
|
126
|
+
|
|
127
|
+
|
|
128
|
+
# **enable_whitelist**
|
|
129
|
+
> WhitelistEnvelope enable_whitelist(dtid, device_type_update_info)
|
|
130
|
+
|
|
131
|
+
Enable or disble whitelist feature of a device type
|
|
132
|
+
|
|
133
|
+
Enable or disble whitelist feature of a device type
|
|
134
|
+
|
|
135
|
+
### Example
|
|
136
|
+
```ruby
|
|
137
|
+
# load the gem
|
|
138
|
+
require 'artikcloud'
|
|
139
|
+
# setup authorization
|
|
140
|
+
ArtikCloud.configure do |config|
|
|
141
|
+
# Configure OAuth2 access token for authorization: artikcloud_oauth
|
|
142
|
+
config.access_token = 'YOUR ACCESS TOKEN'
|
|
143
|
+
end
|
|
144
|
+
|
|
145
|
+
api_instance = ArtikCloud::WhitelistingApi.new
|
|
146
|
+
|
|
147
|
+
dtid = "dtid_example" # String | Device Type ID.
|
|
148
|
+
|
|
149
|
+
device_type_update_info = ArtikCloud::DeviceTypeUpdateInput.new # DeviceTypeUpdateInput | Device type update input.
|
|
150
|
+
|
|
151
|
+
|
|
152
|
+
begin
|
|
153
|
+
#Enable or disble whitelist feature of a device type
|
|
154
|
+
result = api_instance.enable_whitelist(dtid, device_type_update_info)
|
|
155
|
+
p result
|
|
156
|
+
rescue ArtikCloud::ApiError => e
|
|
157
|
+
puts "Exception when calling WhitelistingApi->enable_whitelist: #{e}"
|
|
158
|
+
end
|
|
159
|
+
```
|
|
160
|
+
|
|
161
|
+
### Parameters
|
|
162
|
+
|
|
163
|
+
Name | Type | Description | Notes
|
|
164
|
+
------------- | ------------- | ------------- | -------------
|
|
165
|
+
**dtid** | **String**| Device Type ID. |
|
|
166
|
+
**device_type_update_info** | [**DeviceTypeUpdateInput**](DeviceTypeUpdateInput.md)| Device type update input. |
|
|
167
|
+
|
|
168
|
+
### Return type
|
|
169
|
+
|
|
170
|
+
[**WhitelistEnvelope**](WhitelistEnvelope.md)
|
|
171
|
+
|
|
172
|
+
### Authorization
|
|
173
|
+
|
|
174
|
+
[artikcloud_oauth](../README.md#artikcloud_oauth)
|
|
175
|
+
|
|
176
|
+
### HTTP request headers
|
|
177
|
+
|
|
178
|
+
- **Content-Type**: application/json
|
|
179
|
+
- **Accept**: application/json
|
|
180
|
+
|
|
181
|
+
|
|
182
|
+
|
|
183
|
+
# **get_rejected_row_list**
|
|
184
|
+
> RejectedCSVRowsEnvelope get_rejected_row_list(dtid, upload_id, opts)
|
|
185
|
+
|
|
186
|
+
Get the list of rejected rows for an uploaded CSV file.
|
|
187
|
+
|
|
188
|
+
Get the list of rejected rows for an uploaded CSV file.
|
|
189
|
+
|
|
190
|
+
### Example
|
|
191
|
+
```ruby
|
|
192
|
+
# load the gem
|
|
193
|
+
require 'artikcloud'
|
|
194
|
+
# setup authorization
|
|
195
|
+
ArtikCloud.configure do |config|
|
|
196
|
+
# Configure OAuth2 access token for authorization: artikcloud_oauth
|
|
197
|
+
config.access_token = 'YOUR ACCESS TOKEN'
|
|
198
|
+
end
|
|
199
|
+
|
|
200
|
+
api_instance = ArtikCloud::WhitelistingApi.new
|
|
201
|
+
|
|
202
|
+
dtid = "dtid_example" # String | Device type id related to the uploaded CSV file.
|
|
203
|
+
|
|
204
|
+
upload_id = "upload_id_example" # String | Upload id related to the uploaded CSV file.
|
|
205
|
+
|
|
206
|
+
opts = {
|
|
207
|
+
count: 56, # Integer | Max results count.
|
|
208
|
+
offset: 56 # Integer | Result starting offset.
|
|
209
|
+
}
|
|
210
|
+
|
|
211
|
+
begin
|
|
212
|
+
#Get the list of rejected rows for an uploaded CSV file.
|
|
213
|
+
result = api_instance.get_rejected_row_list(dtid, upload_id, opts)
|
|
214
|
+
p result
|
|
215
|
+
rescue ArtikCloud::ApiError => e
|
|
216
|
+
puts "Exception when calling WhitelistingApi->get_rejected_row_list: #{e}"
|
|
217
|
+
end
|
|
218
|
+
```
|
|
219
|
+
|
|
220
|
+
### Parameters
|
|
221
|
+
|
|
222
|
+
Name | Type | Description | Notes
|
|
223
|
+
------------- | ------------- | ------------- | -------------
|
|
224
|
+
**dtid** | **String**| Device type id related to the uploaded CSV file. |
|
|
225
|
+
**upload_id** | **String**| Upload id related to the uploaded CSV file. |
|
|
226
|
+
**count** | **Integer**| Max results count. | [optional]
|
|
227
|
+
**offset** | **Integer**| Result starting offset. | [optional]
|
|
228
|
+
|
|
229
|
+
### Return type
|
|
230
|
+
|
|
231
|
+
[**RejectedCSVRowsEnvelope**](RejectedCSVRowsEnvelope.md)
|
|
232
|
+
|
|
233
|
+
### Authorization
|
|
234
|
+
|
|
235
|
+
[artikcloud_oauth](../README.md#artikcloud_oauth)
|
|
236
|
+
|
|
237
|
+
### HTTP request headers
|
|
238
|
+
|
|
239
|
+
- **Content-Type**: Not defined
|
|
240
|
+
- **Accept**: application/json
|
|
241
|
+
|
|
242
|
+
|
|
243
|
+
|
|
244
|
+
# **get_upload_status**
|
|
245
|
+
> UploadStatusEnvelope get_upload_status(dtid, upload_id)
|
|
246
|
+
|
|
247
|
+
Get the status of a uploaded CSV file.
|
|
248
|
+
|
|
249
|
+
Get the status of a uploaded CSV file.
|
|
250
|
+
|
|
251
|
+
### Example
|
|
252
|
+
```ruby
|
|
253
|
+
# load the gem
|
|
254
|
+
require 'artikcloud'
|
|
255
|
+
# setup authorization
|
|
256
|
+
ArtikCloud.configure do |config|
|
|
257
|
+
# Configure OAuth2 access token for authorization: artikcloud_oauth
|
|
258
|
+
config.access_token = 'YOUR ACCESS TOKEN'
|
|
259
|
+
end
|
|
260
|
+
|
|
261
|
+
api_instance = ArtikCloud::WhitelistingApi.new
|
|
262
|
+
|
|
263
|
+
dtid = "dtid_example" # String | Device type id related to the uploaded CSV file.
|
|
264
|
+
|
|
265
|
+
upload_id = "upload_id_example" # String | Upload id related to the uploaded CSV file.
|
|
266
|
+
|
|
267
|
+
|
|
268
|
+
begin
|
|
269
|
+
#Get the status of a uploaded CSV file.
|
|
270
|
+
result = api_instance.get_upload_status(dtid, upload_id)
|
|
271
|
+
p result
|
|
272
|
+
rescue ArtikCloud::ApiError => e
|
|
273
|
+
puts "Exception when calling WhitelistingApi->get_upload_status: #{e}"
|
|
274
|
+
end
|
|
275
|
+
```
|
|
276
|
+
|
|
277
|
+
### Parameters
|
|
278
|
+
|
|
279
|
+
Name | Type | Description | Notes
|
|
280
|
+
------------- | ------------- | ------------- | -------------
|
|
281
|
+
**dtid** | **String**| Device type id related to the uploaded CSV file. |
|
|
282
|
+
**upload_id** | **String**| Upload id related to the uploaded CSV file. |
|
|
283
|
+
|
|
284
|
+
### Return type
|
|
285
|
+
|
|
286
|
+
[**UploadStatusEnvelope**](UploadStatusEnvelope.md)
|
|
287
|
+
|
|
288
|
+
### Authorization
|
|
289
|
+
|
|
290
|
+
[artikcloud_oauth](../README.md#artikcloud_oauth)
|
|
291
|
+
|
|
292
|
+
### HTTP request headers
|
|
293
|
+
|
|
294
|
+
- **Content-Type**: Not defined
|
|
295
|
+
- **Accept**: application/json
|
|
296
|
+
|
|
297
|
+
|
|
298
|
+
|
|
299
|
+
# **get_whitelist**
|
|
300
|
+
> WhitelistResultEnvelope get_whitelist(dtid, opts)
|
|
301
|
+
|
|
302
|
+
Get whitelisted vdids of a device type.
|
|
303
|
+
|
|
304
|
+
Get whitelisted vdids of a device type.
|
|
305
|
+
|
|
306
|
+
### Example
|
|
307
|
+
```ruby
|
|
308
|
+
# load the gem
|
|
309
|
+
require 'artikcloud'
|
|
310
|
+
# setup authorization
|
|
311
|
+
ArtikCloud.configure do |config|
|
|
312
|
+
# Configure OAuth2 access token for authorization: artikcloud_oauth
|
|
313
|
+
config.access_token = 'YOUR ACCESS TOKEN'
|
|
314
|
+
end
|
|
315
|
+
|
|
316
|
+
api_instance = ArtikCloud::WhitelistingApi.new
|
|
317
|
+
|
|
318
|
+
dtid = "dtid_example" # String | Device Type ID.
|
|
319
|
+
|
|
320
|
+
opts = {
|
|
321
|
+
count: 56, # Integer | Max results count.
|
|
322
|
+
offset: 56 # Integer | Result starting offset.
|
|
323
|
+
}
|
|
324
|
+
|
|
325
|
+
begin
|
|
326
|
+
#Get whitelisted vdids of a device type.
|
|
327
|
+
result = api_instance.get_whitelist(dtid, opts)
|
|
328
|
+
p result
|
|
329
|
+
rescue ArtikCloud::ApiError => e
|
|
330
|
+
puts "Exception when calling WhitelistingApi->get_whitelist: #{e}"
|
|
331
|
+
end
|
|
332
|
+
```
|
|
333
|
+
|
|
334
|
+
### Parameters
|
|
335
|
+
|
|
336
|
+
Name | Type | Description | Notes
|
|
337
|
+
------------- | ------------- | ------------- | -------------
|
|
338
|
+
**dtid** | **String**| Device Type ID. |
|
|
339
|
+
**count** | **Integer**| Max results count. | [optional]
|
|
340
|
+
**offset** | **Integer**| Result starting offset. | [optional]
|
|
341
|
+
|
|
342
|
+
### Return type
|
|
343
|
+
|
|
344
|
+
[**WhitelistResultEnvelope**](WhitelistResultEnvelope.md)
|
|
345
|
+
|
|
346
|
+
### Authorization
|
|
347
|
+
|
|
348
|
+
[artikcloud_oauth](../README.md#artikcloud_oauth)
|
|
349
|
+
|
|
350
|
+
### HTTP request headers
|
|
351
|
+
|
|
352
|
+
- **Content-Type**: Not defined
|
|
353
|
+
- **Accept**: application/json
|
|
354
|
+
|
|
355
|
+
|
|
356
|
+
|
|
357
|
+
# **get_whitelist_certificate**
|
|
358
|
+
> CertificateEnvelope get_whitelist_certificate(dtid)
|
|
359
|
+
|
|
360
|
+
Get whitelist certificate of device type.
|
|
361
|
+
|
|
362
|
+
Get whitelist certificate of device type.
|
|
363
|
+
|
|
364
|
+
### Example
|
|
365
|
+
```ruby
|
|
366
|
+
# load the gem
|
|
367
|
+
require 'artikcloud'
|
|
368
|
+
# setup authorization
|
|
369
|
+
ArtikCloud.configure do |config|
|
|
370
|
+
# Configure OAuth2 access token for authorization: artikcloud_oauth
|
|
371
|
+
config.access_token = 'YOUR ACCESS TOKEN'
|
|
372
|
+
end
|
|
373
|
+
|
|
374
|
+
api_instance = ArtikCloud::WhitelistingApi.new
|
|
375
|
+
|
|
376
|
+
dtid = "dtid_example" # String | Device Type ID.
|
|
377
|
+
|
|
378
|
+
|
|
379
|
+
begin
|
|
380
|
+
#Get whitelist certificate of device type.
|
|
381
|
+
result = api_instance.get_whitelist_certificate(dtid)
|
|
382
|
+
p result
|
|
383
|
+
rescue ArtikCloud::ApiError => e
|
|
384
|
+
puts "Exception when calling WhitelistingApi->get_whitelist_certificate: #{e}"
|
|
385
|
+
end
|
|
386
|
+
```
|
|
387
|
+
|
|
388
|
+
### Parameters
|
|
389
|
+
|
|
390
|
+
Name | Type | Description | Notes
|
|
391
|
+
------------- | ------------- | ------------- | -------------
|
|
392
|
+
**dtid** | **String**| Device Type ID. |
|
|
393
|
+
|
|
394
|
+
### Return type
|
|
395
|
+
|
|
396
|
+
[**CertificateEnvelope**](CertificateEnvelope.md)
|
|
397
|
+
|
|
398
|
+
### Authorization
|
|
399
|
+
|
|
400
|
+
[artikcloud_oauth](../README.md#artikcloud_oauth)
|
|
401
|
+
|
|
402
|
+
### HTTP request headers
|
|
403
|
+
|
|
404
|
+
- **Content-Type**: Not defined
|
|
405
|
+
- **Accept**: application/json
|
|
406
|
+
|
|
407
|
+
|
|
408
|
+
|
|
409
|
+
# **get_whitelist_status**
|
|
410
|
+
> WhitelistEnvelope get_whitelist_status(dtid)
|
|
411
|
+
|
|
412
|
+
Get the status of whitelist feature (enabled/disabled) of a device type.
|
|
413
|
+
|
|
414
|
+
Get the status of whitelist feature (enabled/disabled) of a device type.
|
|
415
|
+
|
|
416
|
+
### Example
|
|
417
|
+
```ruby
|
|
418
|
+
# load the gem
|
|
419
|
+
require 'artikcloud'
|
|
420
|
+
# setup authorization
|
|
421
|
+
ArtikCloud.configure do |config|
|
|
422
|
+
# Configure OAuth2 access token for authorization: artikcloud_oauth
|
|
423
|
+
config.access_token = 'YOUR ACCESS TOKEN'
|
|
424
|
+
end
|
|
425
|
+
|
|
426
|
+
api_instance = ArtikCloud::WhitelistingApi.new
|
|
427
|
+
|
|
428
|
+
dtid = "dtid_example" # String | Device Type ID.
|
|
429
|
+
|
|
430
|
+
|
|
431
|
+
begin
|
|
432
|
+
#Get the status of whitelist feature (enabled/disabled) of a device type.
|
|
433
|
+
result = api_instance.get_whitelist_status(dtid)
|
|
434
|
+
p result
|
|
435
|
+
rescue ArtikCloud::ApiError => e
|
|
436
|
+
puts "Exception when calling WhitelistingApi->get_whitelist_status: #{e}"
|
|
437
|
+
end
|
|
438
|
+
```
|
|
439
|
+
|
|
440
|
+
### Parameters
|
|
441
|
+
|
|
442
|
+
Name | Type | Description | Notes
|
|
443
|
+
------------- | ------------- | ------------- | -------------
|
|
444
|
+
**dtid** | **String**| Device Type ID. |
|
|
445
|
+
|
|
446
|
+
### Return type
|
|
447
|
+
|
|
448
|
+
[**WhitelistEnvelope**](WhitelistEnvelope.md)
|
|
449
|
+
|
|
450
|
+
### Authorization
|
|
451
|
+
|
|
452
|
+
[artikcloud_oauth](../README.md#artikcloud_oauth)
|
|
453
|
+
|
|
454
|
+
### HTTP request headers
|
|
455
|
+
|
|
456
|
+
- **Content-Type**: Not defined
|
|
457
|
+
- **Accept**: application/json
|
|
458
|
+
|
|
459
|
+
|
|
460
|
+
|
|
461
|
+
# **upload_csv**
|
|
462
|
+
> UploadIdEnvelope upload_csv(dtid, file)
|
|
463
|
+
|
|
464
|
+
Upload a CSV file related to the Device Type.
|
|
465
|
+
|
|
466
|
+
Upload a CSV file related to the Device Type.
|
|
467
|
+
|
|
468
|
+
### Example
|
|
469
|
+
```ruby
|
|
470
|
+
# load the gem
|
|
471
|
+
require 'artikcloud'
|
|
472
|
+
# setup authorization
|
|
473
|
+
ArtikCloud.configure do |config|
|
|
474
|
+
# Configure OAuth2 access token for authorization: artikcloud_oauth
|
|
475
|
+
config.access_token = 'YOUR ACCESS TOKEN'
|
|
476
|
+
end
|
|
477
|
+
|
|
478
|
+
api_instance = ArtikCloud::WhitelistingApi.new
|
|
479
|
+
|
|
480
|
+
dtid = "dtid_example" # String | Device Type ID.
|
|
481
|
+
|
|
482
|
+
file = "B" # String | Device Type ID.
|
|
483
|
+
|
|
484
|
+
|
|
485
|
+
begin
|
|
486
|
+
#Upload a CSV file related to the Device Type.
|
|
487
|
+
result = api_instance.upload_csv(dtid, file)
|
|
488
|
+
p result
|
|
489
|
+
rescue ArtikCloud::ApiError => e
|
|
490
|
+
puts "Exception when calling WhitelistingApi->upload_csv: #{e}"
|
|
491
|
+
end
|
|
492
|
+
```
|
|
493
|
+
|
|
494
|
+
### Parameters
|
|
495
|
+
|
|
496
|
+
Name | Type | Description | Notes
|
|
497
|
+
------------- | ------------- | ------------- | -------------
|
|
498
|
+
**dtid** | **String**| Device Type ID. |
|
|
499
|
+
**file** | **String**| Device Type ID. |
|
|
500
|
+
|
|
501
|
+
### Return type
|
|
502
|
+
|
|
503
|
+
[**UploadIdEnvelope**](UploadIdEnvelope.md)
|
|
504
|
+
|
|
505
|
+
### Authorization
|
|
506
|
+
|
|
507
|
+
[artikcloud_oauth](../README.md#artikcloud_oauth)
|
|
508
|
+
|
|
509
|
+
### HTTP request headers
|
|
510
|
+
|
|
511
|
+
- **Content-Type**: Not defined
|
|
512
|
+
- **Accept**: application/json
|
|
513
|
+
|
|
514
|
+
|
|
515
|
+
|