artikcloud 2.0.8 → 2.1.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/Gemfile +5 -2
- data/LICENSE +1 -1
- data/README.md +39 -4
- data/Rakefile +8 -0
- data/artikcloud.gemspec +5 -16
- data/docs/Device.md +2 -0
- data/docs/DeviceShareInfo.md +8 -0
- data/docs/DeviceSharing.md +11 -0
- data/docs/DeviceSharingArray.md +8 -0
- data/docs/DeviceSharingEnvelope.md +11 -0
- data/docs/DeviceSharingId.md +8 -0
- data/docs/DeviceStatus.md +9 -0
- data/docs/DeviceStatusBatch.md +11 -0
- data/docs/DeviceStatusData.md +12 -0
- data/docs/DeviceStatusPut.md +8 -0
- data/docs/DeviceStatusPutData.md +8 -0
- data/docs/DevicessharesApi.md +235 -0
- data/docs/DevicestatusApi.md +183 -0
- data/docs/NotifMessage.md +15 -0
- data/docs/NotifMessageArray.md +8 -0
- data/docs/NotifMessagesResponse.md +12 -0
- data/docs/Subscription.md +24 -0
- data/docs/SubscriptionArray.md +8 -0
- data/docs/SubscriptionEnvelope.md +8 -0
- data/docs/SubscriptionInfo.md +20 -0
- data/docs/SubscriptionsApi.md +342 -0
- data/docs/SubscriptionsEnvelope.md +11 -0
- data/docs/TaskParameters.md +2 -0
- data/docs/UpdateParameters.md +8 -0
- data/docs/UsersApi.md +67 -1
- data/docs/ValidationCallbackInfo.md +9 -0
- data/git_push.sh +0 -12
- data/lib/artikcloud.rb +24 -13
- data/lib/artikcloud/api/device_types_api.rb +7 -55
- data/lib/artikcloud/api/devices_api.rb +12 -66
- data/lib/artikcloud/api/devices_management_api.rb +16 -118
- data/lib/artikcloud/api/devicesshares_api.rb +244 -0
- data/lib/artikcloud/api/devicestatus_api.rb +190 -0
- data/lib/artikcloud/api/export_api.rb +5 -41
- data/lib/artikcloud/api/messages_api.rb +10 -76
- data/lib/artikcloud/api/registrations_api.rb +4 -34
- data/lib/artikcloud/api/rules_api.rb +5 -41
- data/lib/artikcloud/api/subscriptions_api.rb +346 -0
- data/lib/artikcloud/api/tags_api.rb +4 -34
- data/lib/artikcloud/api/tokens_api.rb +5 -33
- data/lib/artikcloud/api/users_api.rb +79 -67
- data/lib/artikcloud/api_client.rb +17 -20
- data/lib/artikcloud/api_error.rb +8 -18
- data/lib/artikcloud/configuration.rb +1 -13
- data/lib/artikcloud/models/ack_envelope.rb +4 -16
- data/lib/artikcloud/models/acknowledgement.rb +4 -16
- data/lib/artikcloud/models/action.rb +4 -16
- data/lib/artikcloud/models/action_array.rb +4 -16
- data/lib/artikcloud/models/action_details.rb +4 -16
- data/lib/artikcloud/models/action_details_array.rb +4 -16
- data/lib/artikcloud/models/action_in.rb +4 -16
- data/lib/artikcloud/models/action_out.rb +4 -16
- data/lib/artikcloud/models/actions.rb +4 -16
- data/lib/artikcloud/models/aggregate_data.rb +4 -16
- data/lib/artikcloud/models/aggregates_histogram_data.rb +4 -16
- data/lib/artikcloud/models/aggregates_histogram_response.rb +4 -16
- data/lib/artikcloud/models/aggregates_response.rb +4 -16
- data/lib/artikcloud/models/app_properties.rb +8 -16
- data/lib/artikcloud/models/check_token_message.rb +4 -16
- data/lib/artikcloud/models/check_token_response.rb +4 -16
- data/lib/artikcloud/models/device.rb +28 -20
- data/lib/artikcloud/models/device_array.rb +4 -16
- data/lib/artikcloud/models/device_envelope.rb +8 -16
- data/lib/artikcloud/models/device_reg_complete_request.rb +4 -16
- data/lib/artikcloud/models/device_reg_confirm_user_request.rb +4 -16
- data/lib/artikcloud/models/device_reg_confirm_user_response.rb +4 -16
- data/lib/artikcloud/models/device_reg_confirm_user_response_envelope.rb +4 -16
- data/lib/artikcloud/models/device_reg_status_response.rb +4 -16
- data/lib/artikcloud/models/device_reg_status_response_envelope.rb +4 -16
- data/lib/artikcloud/models/device_share_info.rb +188 -0
- data/lib/artikcloud/models/device_sharing.rb +218 -0
- data/lib/artikcloud/models/device_sharing_array.rb +189 -0
- data/lib/artikcloud/models/device_sharing_envelope.rb +214 -0
- data/lib/artikcloud/models/device_sharing_id.rb +188 -0
- data/lib/artikcloud/models/device_status.rb +196 -0
- data/lib/artikcloud/models/device_status_batch.rb +216 -0
- data/lib/artikcloud/models/device_status_data.rb +225 -0
- data/lib/artikcloud/models/device_status_put.rb +187 -0
- data/lib/artikcloud/models/device_status_put_data.rb +187 -0
- data/lib/artikcloud/models/device_task.rb +4 -16
- data/lib/artikcloud/models/device_task_update_request.rb +4 -16
- data/lib/artikcloud/models/device_task_update_response.rb +4 -16
- data/lib/artikcloud/models/device_token.rb +20 -16
- data/lib/artikcloud/models/device_token_envelope.rb +8 -16
- data/lib/artikcloud/models/device_type.rb +4 -16
- data/lib/artikcloud/models/device_type_array.rb +4 -16
- data/lib/artikcloud/models/device_type_envelope.rb +8 -16
- data/lib/artikcloud/models/device_type_info.rb +4 -16
- data/lib/artikcloud/models/device_type_info_envelope.rb +4 -16
- data/lib/artikcloud/models/device_types_envelope.rb +16 -16
- data/lib/artikcloud/models/device_types_info.rb +4 -16
- data/lib/artikcloud/models/device_types_info_envelope.rb +4 -16
- data/lib/artikcloud/models/devices_envelope.rb +16 -16
- data/lib/artikcloud/models/error_envelope.rb +4 -16
- data/lib/artikcloud/models/event_feed_data.rb +4 -16
- data/lib/artikcloud/models/export_data.rb +4 -16
- data/lib/artikcloud/models/export_data_array.rb +4 -16
- data/lib/artikcloud/models/export_history_response.rb +4 -16
- data/lib/artikcloud/models/export_normalized_messages_response.rb +4 -16
- data/lib/artikcloud/models/export_request.rb +4 -16
- data/lib/artikcloud/models/export_request_data.rb +4 -16
- data/lib/artikcloud/models/export_request_info.rb +4 -16
- data/lib/artikcloud/models/export_request_response.rb +4 -16
- data/lib/artikcloud/models/export_response.rb +4 -16
- data/lib/artikcloud/models/export_status_response.rb +4 -16
- data/lib/artikcloud/models/field_path.rb +4 -16
- data/lib/artikcloud/models/field_presence.rb +8 -16
- data/lib/artikcloud/models/field_presence_envelope.rb +32 -16
- data/lib/artikcloud/models/fields_actions.rb +4 -16
- data/lib/artikcloud/models/manifest_properties.rb +8 -16
- data/lib/artikcloud/models/manifest_properties_envelope.rb +8 -16
- data/lib/artikcloud/models/manifest_versions.rb +8 -16
- data/lib/artikcloud/models/manifest_versions_envelope.rb +8 -16
- data/lib/artikcloud/models/message.rb +4 -16
- data/lib/artikcloud/models/message_action.rb +4 -16
- data/lib/artikcloud/models/message_id.rb +4 -16
- data/lib/artikcloud/models/message_id_envelope.rb +4 -16
- data/lib/artikcloud/models/message_in.rb +4 -16
- data/lib/artikcloud/models/message_out.rb +4 -16
- data/lib/artikcloud/models/metadata_envelope.rb +4 -16
- data/lib/artikcloud/models/metadata_properties_envelope.rb +4 -16
- data/lib/artikcloud/models/metadata_query_envelope.rb +4 -16
- data/lib/artikcloud/models/non_empty_string.rb +4 -16
- data/lib/artikcloud/models/normalized_action.rb +36 -16
- data/lib/artikcloud/models/normalized_actions_envelope.rb +16 -16
- data/lib/artikcloud/models/normalized_message.rb +36 -16
- data/lib/artikcloud/models/normalized_messages_envelope.rb +16 -16
- data/lib/artikcloud/models/notif_message.rb +252 -0
- data/lib/artikcloud/models/notif_message_array.rb +189 -0
- data/lib/artikcloud/models/notif_messages_response.rb +223 -0
- data/lib/artikcloud/models/output_rule.rb +4 -16
- data/lib/artikcloud/models/presence_envelope.rb +4 -16
- data/lib/artikcloud/models/presence_model.rb +4 -16
- data/lib/artikcloud/models/properties_envelope.rb +8 -16
- data/lib/artikcloud/models/refresh_token_response.rb +4 -16
- data/lib/artikcloud/models/register_message.rb +4 -16
- data/lib/artikcloud/models/rule_array.rb +4 -16
- data/lib/artikcloud/models/rule_creation_info.rb +4 -16
- data/lib/artikcloud/models/rule_envelope.rb +4 -16
- data/lib/artikcloud/models/rule_error.rb +4 -16
- data/lib/artikcloud/models/rule_update_info.rb +4 -16
- data/lib/artikcloud/models/rule_warning_output.rb +4 -16
- data/lib/artikcloud/models/rules_envelope.rb +4 -16
- data/lib/artikcloud/models/snapshot_response.rb +4 -16
- data/lib/artikcloud/models/snapshot_responses.rb +4 -16
- data/lib/artikcloud/models/snapshots_response_envelope.rb +4 -16
- data/lib/artikcloud/models/subscription.rb +348 -0
- data/lib/artikcloud/models/subscription_array.rb +189 -0
- data/lib/artikcloud/models/subscription_envelope.rb +187 -0
- data/lib/artikcloud/models/subscription_info.rb +308 -0
- data/lib/artikcloud/models/subscriptions_envelope.rb +214 -0
- data/lib/artikcloud/models/tag.rb +4 -16
- data/lib/artikcloud/models/tag_array.rb +4 -16
- data/lib/artikcloud/models/tags_envelope.rb +4 -16
- data/lib/artikcloud/models/task.rb +4 -16
- data/lib/artikcloud/models/task_by_did.rb +4 -16
- data/lib/artikcloud/models/task_by_did_list.rb +4 -16
- data/lib/artikcloud/models/task_by_did_list_envelope.rb +4 -16
- data/lib/artikcloud/models/task_envelope.rb +4 -16
- data/lib/artikcloud/models/task_history.rb +4 -16
- data/lib/artikcloud/models/task_history_list.rb +4 -16
- data/lib/artikcloud/models/task_list.rb +4 -16
- data/lib/artikcloud/models/task_list_envelope.rb +4 -16
- data/lib/artikcloud/models/task_parameters.rb +25 -17
- data/lib/artikcloud/models/task_request.rb +4 -16
- data/lib/artikcloud/models/task_status.rb +4 -16
- data/lib/artikcloud/models/task_status_counts.rb +4 -16
- data/lib/artikcloud/models/task_statuses.rb +4 -16
- data/lib/artikcloud/models/task_statuses_envelope.rb +4 -16
- data/lib/artikcloud/models/task_statuses_history_envelope.rb +4 -16
- data/lib/artikcloud/models/task_update_request.rb +4 -16
- data/lib/artikcloud/models/task_update_response.rb +4 -16
- data/lib/artikcloud/models/tasks_status_counts.rb +4 -16
- data/lib/artikcloud/models/token.rb +4 -16
- data/lib/artikcloud/models/token_info.rb +4 -16
- data/lib/artikcloud/models/token_info_success_response.rb +4 -16
- data/lib/artikcloud/models/token_request.rb +4 -16
- data/lib/artikcloud/models/token_response.rb +4 -16
- data/lib/artikcloud/models/unregister_device_response.rb +4 -16
- data/lib/artikcloud/models/unregister_device_response_envelope.rb +4 -16
- data/lib/artikcloud/models/update_parameters.rb +188 -0
- data/lib/artikcloud/models/user.rb +28 -16
- data/lib/artikcloud/models/user_envelope.rb +8 -16
- data/lib/artikcloud/models/validation_callback_info.rb +198 -0
- data/lib/artikcloud/models/web_socket_error.rb +4 -16
- data/lib/artikcloud/version.rb +2 -14
- data/pom.xml +1 -1
- data/spec/api/devicesshares_api_spec.rb +87 -0
- data/spec/api/devicestatus_api_spec.rb +75 -0
- data/spec/api/subscriptions_api_spec.rb +112 -0
- metadata +58 -26
|
@@ -0,0 +1,183 @@
|
|
|
1
|
+
# ArtikCloud::DevicestatusApi
|
|
2
|
+
|
|
3
|
+
All URIs are relative to *https://api.artik.cloud/v1.1*
|
|
4
|
+
|
|
5
|
+
Method | HTTP request | Description
|
|
6
|
+
------------- | ------------- | -------------
|
|
7
|
+
[**get_device_status**](DevicestatusApi.md#get_device_status) | **GET** /devices/{deviceId}/status | Get Device Status
|
|
8
|
+
[**get_devices_status**](DevicestatusApi.md#get_devices_status) | **GET** /devices/status | Get Devices Status
|
|
9
|
+
[**put_device_status**](DevicestatusApi.md#put_device_status) | **PUT** /devices/{deviceId}/status | Update Device Status
|
|
10
|
+
|
|
11
|
+
|
|
12
|
+
# **get_device_status**
|
|
13
|
+
> DeviceStatus get_device_status(device_id, opts)
|
|
14
|
+
|
|
15
|
+
Get Device Status
|
|
16
|
+
|
|
17
|
+
Get Device Status
|
|
18
|
+
|
|
19
|
+
### Example
|
|
20
|
+
```ruby
|
|
21
|
+
# load the gem
|
|
22
|
+
require 'artikcloud'
|
|
23
|
+
# setup authorization
|
|
24
|
+
ArtikCloud.configure do |config|
|
|
25
|
+
# Configure OAuth2 access token for authorization: artikcloud_oauth
|
|
26
|
+
config.access_token = 'YOUR ACCESS TOKEN'
|
|
27
|
+
end
|
|
28
|
+
|
|
29
|
+
api_instance = ArtikCloud::DevicestatusApi.new
|
|
30
|
+
|
|
31
|
+
device_id = "device_id_example" # String | Device ID.
|
|
32
|
+
|
|
33
|
+
opts = {
|
|
34
|
+
include_snapshot: true, # BOOLEAN | Include device snapshot into the response
|
|
35
|
+
include_snapshot_timestamp: true # BOOLEAN | Include device snapshot timestamp into the response
|
|
36
|
+
}
|
|
37
|
+
|
|
38
|
+
begin
|
|
39
|
+
#Get Device Status
|
|
40
|
+
result = api_instance.get_device_status(device_id, opts)
|
|
41
|
+
p result
|
|
42
|
+
rescue ArtikCloud::ApiError => e
|
|
43
|
+
puts "Exception when calling DevicestatusApi->get_device_status: #{e}"
|
|
44
|
+
end
|
|
45
|
+
```
|
|
46
|
+
|
|
47
|
+
### Parameters
|
|
48
|
+
|
|
49
|
+
Name | Type | Description | Notes
|
|
50
|
+
------------- | ------------- | ------------- | -------------
|
|
51
|
+
**device_id** | **String**| Device ID. |
|
|
52
|
+
**include_snapshot** | **BOOLEAN**| Include device snapshot into the response | [optional]
|
|
53
|
+
**include_snapshot_timestamp** | **BOOLEAN**| Include device snapshot timestamp into the response | [optional]
|
|
54
|
+
|
|
55
|
+
### Return type
|
|
56
|
+
|
|
57
|
+
[**DeviceStatus**](DeviceStatus.md)
|
|
58
|
+
|
|
59
|
+
### Authorization
|
|
60
|
+
|
|
61
|
+
[artikcloud_oauth](../README.md#artikcloud_oauth)
|
|
62
|
+
|
|
63
|
+
### HTTP request headers
|
|
64
|
+
|
|
65
|
+
- **Content-Type**: Not defined
|
|
66
|
+
- **Accept**: application/json
|
|
67
|
+
|
|
68
|
+
|
|
69
|
+
|
|
70
|
+
# **get_devices_status**
|
|
71
|
+
> DeviceStatusBatch get_devices_status(dids, opts)
|
|
72
|
+
|
|
73
|
+
Get Devices Status
|
|
74
|
+
|
|
75
|
+
Get Devices Status
|
|
76
|
+
|
|
77
|
+
### Example
|
|
78
|
+
```ruby
|
|
79
|
+
# load the gem
|
|
80
|
+
require 'artikcloud'
|
|
81
|
+
# setup authorization
|
|
82
|
+
ArtikCloud.configure do |config|
|
|
83
|
+
# Configure OAuth2 access token for authorization: artikcloud_oauth
|
|
84
|
+
config.access_token = 'YOUR ACCESS TOKEN'
|
|
85
|
+
end
|
|
86
|
+
|
|
87
|
+
api_instance = ArtikCloud::DevicestatusApi.new
|
|
88
|
+
|
|
89
|
+
dids = "dids_example" # String | List of device ids (comma-separated) for which the statuses are requested.
|
|
90
|
+
|
|
91
|
+
opts = {
|
|
92
|
+
include_snapshot: true, # BOOLEAN | Include device snapshot into the response
|
|
93
|
+
include_snapshot_timestamp: true # BOOLEAN | Include device snapshot timestamp into the response
|
|
94
|
+
}
|
|
95
|
+
|
|
96
|
+
begin
|
|
97
|
+
#Get Devices Status
|
|
98
|
+
result = api_instance.get_devices_status(dids, opts)
|
|
99
|
+
p result
|
|
100
|
+
rescue ArtikCloud::ApiError => e
|
|
101
|
+
puts "Exception when calling DevicestatusApi->get_devices_status: #{e}"
|
|
102
|
+
end
|
|
103
|
+
```
|
|
104
|
+
|
|
105
|
+
### Parameters
|
|
106
|
+
|
|
107
|
+
Name | Type | Description | Notes
|
|
108
|
+
------------- | ------------- | ------------- | -------------
|
|
109
|
+
**dids** | **String**| List of device ids (comma-separated) for which the statuses are requested. |
|
|
110
|
+
**include_snapshot** | **BOOLEAN**| Include device snapshot into the response | [optional]
|
|
111
|
+
**include_snapshot_timestamp** | **BOOLEAN**| Include device snapshot timestamp into the response | [optional]
|
|
112
|
+
|
|
113
|
+
### Return type
|
|
114
|
+
|
|
115
|
+
[**DeviceStatusBatch**](DeviceStatusBatch.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
|
+
# **put_device_status**
|
|
129
|
+
> DeviceStatus put_device_status(device_id, opts)
|
|
130
|
+
|
|
131
|
+
Update Device Status
|
|
132
|
+
|
|
133
|
+
Update Device Status
|
|
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::DevicestatusApi.new
|
|
146
|
+
|
|
147
|
+
device_id = "device_id_example" # String | Device ID.
|
|
148
|
+
|
|
149
|
+
opts = {
|
|
150
|
+
body: ArtikCloud::DeviceStatusPut.new # DeviceStatusPut | Body
|
|
151
|
+
}
|
|
152
|
+
|
|
153
|
+
begin
|
|
154
|
+
#Update Device Status
|
|
155
|
+
result = api_instance.put_device_status(device_id, opts)
|
|
156
|
+
p result
|
|
157
|
+
rescue ArtikCloud::ApiError => e
|
|
158
|
+
puts "Exception when calling DevicestatusApi->put_device_status: #{e}"
|
|
159
|
+
end
|
|
160
|
+
```
|
|
161
|
+
|
|
162
|
+
### Parameters
|
|
163
|
+
|
|
164
|
+
Name | Type | Description | Notes
|
|
165
|
+
------------- | ------------- | ------------- | -------------
|
|
166
|
+
**device_id** | **String**| Device ID. |
|
|
167
|
+
**body** | [**DeviceStatusPut**](DeviceStatusPut.md)| Body | [optional]
|
|
168
|
+
|
|
169
|
+
### Return type
|
|
170
|
+
|
|
171
|
+
[**DeviceStatus**](DeviceStatus.md)
|
|
172
|
+
|
|
173
|
+
### Authorization
|
|
174
|
+
|
|
175
|
+
[artikcloud_oauth](../README.md#artikcloud_oauth)
|
|
176
|
+
|
|
177
|
+
### HTTP request headers
|
|
178
|
+
|
|
179
|
+
- **Content-Type**: Not defined
|
|
180
|
+
- **Accept**: application/json
|
|
181
|
+
|
|
182
|
+
|
|
183
|
+
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
# ArtikCloud::NotifMessage
|
|
2
|
+
|
|
3
|
+
## Properties
|
|
4
|
+
Name | Type | Description | Notes
|
|
5
|
+
------------ | ------------- | ------------- | -------------
|
|
6
|
+
**uid** | **String** | | [optional]
|
|
7
|
+
**cts** | **Integer** | | [optional]
|
|
8
|
+
**data** | **Hash<String, Object>** | | [optional]
|
|
9
|
+
**mid** | **String** | | [optional]
|
|
10
|
+
**sdid** | **String** | | [optional]
|
|
11
|
+
**mv** | **String** | | [optional]
|
|
12
|
+
**sdtid** | **String** | | [optional]
|
|
13
|
+
**ts** | **Integer** | | [optional]
|
|
14
|
+
|
|
15
|
+
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
# ArtikCloud::NotifMessagesResponse
|
|
2
|
+
|
|
3
|
+
## Properties
|
|
4
|
+
Name | Type | Description | Notes
|
|
5
|
+
------------ | ------------- | ------------- | -------------
|
|
6
|
+
**total** | **Integer** | | [optional]
|
|
7
|
+
**offset** | **Integer** | | [optional]
|
|
8
|
+
**data** | [**NotifMessageArray**](NotifMessageArray.md) | | [optional]
|
|
9
|
+
**count** | **Integer** | | [optional]
|
|
10
|
+
**order** | **String** | | [optional]
|
|
11
|
+
|
|
12
|
+
|
|
@@ -0,0 +1,24 @@
|
|
|
1
|
+
# ArtikCloud::Subscription
|
|
2
|
+
|
|
3
|
+
## Properties
|
|
4
|
+
Name | Type | Description | Notes
|
|
5
|
+
------------ | ------------- | ------------- | -------------
|
|
6
|
+
**aws_region** | **String** | AWS region (if subscriptionType is awsKinesis | [optional]
|
|
7
|
+
**include_shared_devices** | **BOOLEAN** | Include Shared Devices | [optional]
|
|
8
|
+
**description** | **String** | Description | [optional]
|
|
9
|
+
**aws_key** | **String** | AWS key (if subscriptionType is awsKinesis | [optional]
|
|
10
|
+
**aws_secret** | **String** | AWS secret (if subscriptionType is awsKinesis | [optional]
|
|
11
|
+
**created_on** | **Integer** | Creation timestamp | [optional]
|
|
12
|
+
**aws_kinesis_stream_name** | **String** | AWS Kinesis stream name (if subscriptionType is awsKinesis | [optional]
|
|
13
|
+
**uid** | **String** | User ID | [optional]
|
|
14
|
+
**message_type** | **String** | Message type | [optional]
|
|
15
|
+
**ddid** | **String** | Destination device ID | [optional]
|
|
16
|
+
**subscription_type** | **String** | Subscription type (either httpCallback or awsKinesis, default to httpCallback) | [optional]
|
|
17
|
+
**name** | **String** | Name | [optional]
|
|
18
|
+
**sdid** | **String** | Source device ID | [optional]
|
|
19
|
+
**callback_url** | **String** | Callback URL | [optional]
|
|
20
|
+
**id** | **String** | Subscription ID | [optional]
|
|
21
|
+
**aid** | **String** | Application ID | [optional]
|
|
22
|
+
**sdtid** | **String** | Source device type ID | [optional]
|
|
23
|
+
|
|
24
|
+
|
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
# ArtikCloud::SubscriptionInfo
|
|
2
|
+
|
|
3
|
+
## Properties
|
|
4
|
+
Name | Type | Description | Notes
|
|
5
|
+
------------ | ------------- | ------------- | -------------
|
|
6
|
+
**aws_region** | **String** | AWS region (if subscriptionType is awsKinesis | [optional]
|
|
7
|
+
**description** | **String** | Description | [optional]
|
|
8
|
+
**aws_key** | **String** | AWS key (if subscriptionType is awsKinesis | [optional]
|
|
9
|
+
**aws_secret** | **String** | AWS secret (if subscriptionType is awsKinesis | [optional]
|
|
10
|
+
**aws_kinesis_stream_name** | **String** | AWS Kinesis stream name (if subscriptionType is awsKinesis | [optional]
|
|
11
|
+
**uid** | **String** | User ID | [optional]
|
|
12
|
+
**message_type** | **String** | Message type | [optional]
|
|
13
|
+
**ddid** | **String** | Destination device ID | [optional]
|
|
14
|
+
**subscription_type** | **String** | Subscription type (either httpCallback or awsKinesis, default to httpCallback) | [optional]
|
|
15
|
+
**name** | **String** | Name | [optional]
|
|
16
|
+
**sdid** | **String** | Source device ID | [optional]
|
|
17
|
+
**callback_url** | **String** | Callback URL | [optional]
|
|
18
|
+
**sdtid** | **String** | Source device type ID | [optional]
|
|
19
|
+
|
|
20
|
+
|
|
@@ -0,0 +1,342 @@
|
|
|
1
|
+
# ArtikCloud::SubscriptionsApi
|
|
2
|
+
|
|
3
|
+
All URIs are relative to *https://api.artik.cloud/v1.1*
|
|
4
|
+
|
|
5
|
+
Method | HTTP request | Description
|
|
6
|
+
------------- | ------------- | -------------
|
|
7
|
+
[**create_subscription**](SubscriptionsApi.md#create_subscription) | **POST** /subscriptions | Create Subscription
|
|
8
|
+
[**delete_subscription**](SubscriptionsApi.md#delete_subscription) | **DELETE** /subscriptions/{subId} | Delete Subscription
|
|
9
|
+
[**get_all_subscriptions**](SubscriptionsApi.md#get_all_subscriptions) | **GET** /subscriptions | Get All Subscriptions
|
|
10
|
+
[**get_messages**](SubscriptionsApi.md#get_messages) | **GET** /notifications/{notifId}/messages | Get Messages
|
|
11
|
+
[**get_subscription**](SubscriptionsApi.md#get_subscription) | **GET** /subscriptions/{subId} | Get Subscription
|
|
12
|
+
[**validate_subscription**](SubscriptionsApi.md#validate_subscription) | **POST** /subscriptions/{subId}/validate | Validate Subscription
|
|
13
|
+
|
|
14
|
+
|
|
15
|
+
# **create_subscription**
|
|
16
|
+
> SubscriptionEnvelope create_subscription(subscription_info)
|
|
17
|
+
|
|
18
|
+
Create Subscription
|
|
19
|
+
|
|
20
|
+
Create Subscription
|
|
21
|
+
|
|
22
|
+
### Example
|
|
23
|
+
```ruby
|
|
24
|
+
# load the gem
|
|
25
|
+
require 'artikcloud'
|
|
26
|
+
# setup authorization
|
|
27
|
+
ArtikCloud.configure do |config|
|
|
28
|
+
# Configure OAuth2 access token for authorization: artikcloud_oauth
|
|
29
|
+
config.access_token = 'YOUR ACCESS TOKEN'
|
|
30
|
+
end
|
|
31
|
+
|
|
32
|
+
api_instance = ArtikCloud::SubscriptionsApi.new
|
|
33
|
+
|
|
34
|
+
subscription_info = ArtikCloud::SubscriptionInfo.new # SubscriptionInfo | Subscription details
|
|
35
|
+
|
|
36
|
+
|
|
37
|
+
begin
|
|
38
|
+
#Create Subscription
|
|
39
|
+
result = api_instance.create_subscription(subscription_info)
|
|
40
|
+
p result
|
|
41
|
+
rescue ArtikCloud::ApiError => e
|
|
42
|
+
puts "Exception when calling SubscriptionsApi->create_subscription: #{e}"
|
|
43
|
+
end
|
|
44
|
+
```
|
|
45
|
+
|
|
46
|
+
### Parameters
|
|
47
|
+
|
|
48
|
+
Name | Type | Description | Notes
|
|
49
|
+
------------- | ------------- | ------------- | -------------
|
|
50
|
+
**subscription_info** | [**SubscriptionInfo**](SubscriptionInfo.md)| Subscription details |
|
|
51
|
+
|
|
52
|
+
### Return type
|
|
53
|
+
|
|
54
|
+
[**SubscriptionEnvelope**](SubscriptionEnvelope.md)
|
|
55
|
+
|
|
56
|
+
### Authorization
|
|
57
|
+
|
|
58
|
+
[artikcloud_oauth](../README.md#artikcloud_oauth)
|
|
59
|
+
|
|
60
|
+
### HTTP request headers
|
|
61
|
+
|
|
62
|
+
- **Content-Type**: Not defined
|
|
63
|
+
- **Accept**: application/json
|
|
64
|
+
|
|
65
|
+
|
|
66
|
+
|
|
67
|
+
# **delete_subscription**
|
|
68
|
+
> SubscriptionEnvelope delete_subscription(sub_id)
|
|
69
|
+
|
|
70
|
+
Delete Subscription
|
|
71
|
+
|
|
72
|
+
Delete Subscription
|
|
73
|
+
|
|
74
|
+
### Example
|
|
75
|
+
```ruby
|
|
76
|
+
# load the gem
|
|
77
|
+
require 'artikcloud'
|
|
78
|
+
# setup authorization
|
|
79
|
+
ArtikCloud.configure do |config|
|
|
80
|
+
# Configure OAuth2 access token for authorization: artikcloud_oauth
|
|
81
|
+
config.access_token = 'YOUR ACCESS TOKEN'
|
|
82
|
+
end
|
|
83
|
+
|
|
84
|
+
api_instance = ArtikCloud::SubscriptionsApi.new
|
|
85
|
+
|
|
86
|
+
sub_id = "sub_id_example" # String | Subscription ID.
|
|
87
|
+
|
|
88
|
+
|
|
89
|
+
begin
|
|
90
|
+
#Delete Subscription
|
|
91
|
+
result = api_instance.delete_subscription(sub_id)
|
|
92
|
+
p result
|
|
93
|
+
rescue ArtikCloud::ApiError => e
|
|
94
|
+
puts "Exception when calling SubscriptionsApi->delete_subscription: #{e}"
|
|
95
|
+
end
|
|
96
|
+
```
|
|
97
|
+
|
|
98
|
+
### Parameters
|
|
99
|
+
|
|
100
|
+
Name | Type | Description | Notes
|
|
101
|
+
------------- | ------------- | ------------- | -------------
|
|
102
|
+
**sub_id** | **String**| Subscription ID. |
|
|
103
|
+
|
|
104
|
+
### Return type
|
|
105
|
+
|
|
106
|
+
[**SubscriptionEnvelope**](SubscriptionEnvelope.md)
|
|
107
|
+
|
|
108
|
+
### Authorization
|
|
109
|
+
|
|
110
|
+
[artikcloud_oauth](../README.md#artikcloud_oauth)
|
|
111
|
+
|
|
112
|
+
### HTTP request headers
|
|
113
|
+
|
|
114
|
+
- **Content-Type**: Not defined
|
|
115
|
+
- **Accept**: application/json
|
|
116
|
+
|
|
117
|
+
|
|
118
|
+
|
|
119
|
+
# **get_all_subscriptions**
|
|
120
|
+
> SubscriptionsEnvelope get_all_subscriptions(opts)
|
|
121
|
+
|
|
122
|
+
Get All Subscriptions
|
|
123
|
+
|
|
124
|
+
Get All Subscriptions
|
|
125
|
+
|
|
126
|
+
### Example
|
|
127
|
+
```ruby
|
|
128
|
+
# load the gem
|
|
129
|
+
require 'artikcloud'
|
|
130
|
+
# setup authorization
|
|
131
|
+
ArtikCloud.configure do |config|
|
|
132
|
+
# Configure OAuth2 access token for authorization: artikcloud_oauth
|
|
133
|
+
config.access_token = 'YOUR ACCESS TOKEN'
|
|
134
|
+
end
|
|
135
|
+
|
|
136
|
+
api_instance = ArtikCloud::SubscriptionsApi.new
|
|
137
|
+
|
|
138
|
+
opts = {
|
|
139
|
+
uid: "uid_example", # String | User ID
|
|
140
|
+
offset: 56, # Integer | Offset for pagination.
|
|
141
|
+
count: 56 # Integer | Desired count of items in the result set.
|
|
142
|
+
}
|
|
143
|
+
|
|
144
|
+
begin
|
|
145
|
+
#Get All Subscriptions
|
|
146
|
+
result = api_instance.get_all_subscriptions(opts)
|
|
147
|
+
p result
|
|
148
|
+
rescue ArtikCloud::ApiError => e
|
|
149
|
+
puts "Exception when calling SubscriptionsApi->get_all_subscriptions: #{e}"
|
|
150
|
+
end
|
|
151
|
+
```
|
|
152
|
+
|
|
153
|
+
### Parameters
|
|
154
|
+
|
|
155
|
+
Name | Type | Description | Notes
|
|
156
|
+
------------- | ------------- | ------------- | -------------
|
|
157
|
+
**uid** | **String**| User ID | [optional]
|
|
158
|
+
**offset** | **Integer**| Offset for pagination. | [optional]
|
|
159
|
+
**count** | **Integer**| Desired count of items in the result set. | [optional]
|
|
160
|
+
|
|
161
|
+
### Return type
|
|
162
|
+
|
|
163
|
+
[**SubscriptionsEnvelope**](SubscriptionsEnvelope.md)
|
|
164
|
+
|
|
165
|
+
### Authorization
|
|
166
|
+
|
|
167
|
+
[artikcloud_oauth](../README.md#artikcloud_oauth)
|
|
168
|
+
|
|
169
|
+
### HTTP request headers
|
|
170
|
+
|
|
171
|
+
- **Content-Type**: Not defined
|
|
172
|
+
- **Accept**: application/json
|
|
173
|
+
|
|
174
|
+
|
|
175
|
+
|
|
176
|
+
# **get_messages**
|
|
177
|
+
> NotifMessagesResponse get_messages(notif_id, opts)
|
|
178
|
+
|
|
179
|
+
Get Messages
|
|
180
|
+
|
|
181
|
+
Get Messages
|
|
182
|
+
|
|
183
|
+
### Example
|
|
184
|
+
```ruby
|
|
185
|
+
# load the gem
|
|
186
|
+
require 'artikcloud'
|
|
187
|
+
# setup authorization
|
|
188
|
+
ArtikCloud.configure do |config|
|
|
189
|
+
# Configure OAuth2 access token for authorization: artikcloud_oauth
|
|
190
|
+
config.access_token = 'YOUR ACCESS TOKEN'
|
|
191
|
+
end
|
|
192
|
+
|
|
193
|
+
api_instance = ArtikCloud::SubscriptionsApi.new
|
|
194
|
+
|
|
195
|
+
notif_id = "notif_id_example" # String | Notification ID.
|
|
196
|
+
|
|
197
|
+
opts = {
|
|
198
|
+
offset: 56, # Integer | Offset for pagination.
|
|
199
|
+
count: 56, # Integer | Desired count of items in the result set.
|
|
200
|
+
order: "order_example" # String | Sort order of results by ts. Either 'asc' or 'desc'.
|
|
201
|
+
}
|
|
202
|
+
|
|
203
|
+
begin
|
|
204
|
+
#Get Messages
|
|
205
|
+
result = api_instance.get_messages(notif_id, opts)
|
|
206
|
+
p result
|
|
207
|
+
rescue ArtikCloud::ApiError => e
|
|
208
|
+
puts "Exception when calling SubscriptionsApi->get_messages: #{e}"
|
|
209
|
+
end
|
|
210
|
+
```
|
|
211
|
+
|
|
212
|
+
### Parameters
|
|
213
|
+
|
|
214
|
+
Name | Type | Description | Notes
|
|
215
|
+
------------- | ------------- | ------------- | -------------
|
|
216
|
+
**notif_id** | **String**| Notification ID. |
|
|
217
|
+
**offset** | **Integer**| Offset for pagination. | [optional]
|
|
218
|
+
**count** | **Integer**| Desired count of items in the result set. | [optional]
|
|
219
|
+
**order** | **String**| Sort order of results by ts. Either 'asc' or 'desc'. | [optional]
|
|
220
|
+
|
|
221
|
+
### Return type
|
|
222
|
+
|
|
223
|
+
[**NotifMessagesResponse**](NotifMessagesResponse.md)
|
|
224
|
+
|
|
225
|
+
### Authorization
|
|
226
|
+
|
|
227
|
+
[artikcloud_oauth](../README.md#artikcloud_oauth)
|
|
228
|
+
|
|
229
|
+
### HTTP request headers
|
|
230
|
+
|
|
231
|
+
- **Content-Type**: Not defined
|
|
232
|
+
- **Accept**: application/json
|
|
233
|
+
|
|
234
|
+
|
|
235
|
+
|
|
236
|
+
# **get_subscription**
|
|
237
|
+
> SubscriptionEnvelope get_subscription(sub_id)
|
|
238
|
+
|
|
239
|
+
Get Subscription
|
|
240
|
+
|
|
241
|
+
Get Subscription
|
|
242
|
+
|
|
243
|
+
### Example
|
|
244
|
+
```ruby
|
|
245
|
+
# load the gem
|
|
246
|
+
require 'artikcloud'
|
|
247
|
+
# setup authorization
|
|
248
|
+
ArtikCloud.configure do |config|
|
|
249
|
+
# Configure OAuth2 access token for authorization: artikcloud_oauth
|
|
250
|
+
config.access_token = 'YOUR ACCESS TOKEN'
|
|
251
|
+
end
|
|
252
|
+
|
|
253
|
+
api_instance = ArtikCloud::SubscriptionsApi.new
|
|
254
|
+
|
|
255
|
+
sub_id = "sub_id_example" # String | Subscription ID.
|
|
256
|
+
|
|
257
|
+
|
|
258
|
+
begin
|
|
259
|
+
#Get Subscription
|
|
260
|
+
result = api_instance.get_subscription(sub_id)
|
|
261
|
+
p result
|
|
262
|
+
rescue ArtikCloud::ApiError => e
|
|
263
|
+
puts "Exception when calling SubscriptionsApi->get_subscription: #{e}"
|
|
264
|
+
end
|
|
265
|
+
```
|
|
266
|
+
|
|
267
|
+
### Parameters
|
|
268
|
+
|
|
269
|
+
Name | Type | Description | Notes
|
|
270
|
+
------------- | ------------- | ------------- | -------------
|
|
271
|
+
**sub_id** | **String**| Subscription ID. |
|
|
272
|
+
|
|
273
|
+
### Return type
|
|
274
|
+
|
|
275
|
+
[**SubscriptionEnvelope**](SubscriptionEnvelope.md)
|
|
276
|
+
|
|
277
|
+
### Authorization
|
|
278
|
+
|
|
279
|
+
[artikcloud_oauth](../README.md#artikcloud_oauth)
|
|
280
|
+
|
|
281
|
+
### HTTP request headers
|
|
282
|
+
|
|
283
|
+
- **Content-Type**: Not defined
|
|
284
|
+
- **Accept**: application/json
|
|
285
|
+
|
|
286
|
+
|
|
287
|
+
|
|
288
|
+
# **validate_subscription**
|
|
289
|
+
> SubscriptionEnvelope validate_subscription(sub_id, validation_callback_request)
|
|
290
|
+
|
|
291
|
+
Validate Subscription
|
|
292
|
+
|
|
293
|
+
Validate Subscription
|
|
294
|
+
|
|
295
|
+
### Example
|
|
296
|
+
```ruby
|
|
297
|
+
# load the gem
|
|
298
|
+
require 'artikcloud'
|
|
299
|
+
# setup authorization
|
|
300
|
+
ArtikCloud.configure do |config|
|
|
301
|
+
# Configure OAuth2 access token for authorization: artikcloud_oauth
|
|
302
|
+
config.access_token = 'YOUR ACCESS TOKEN'
|
|
303
|
+
end
|
|
304
|
+
|
|
305
|
+
api_instance = ArtikCloud::SubscriptionsApi.new
|
|
306
|
+
|
|
307
|
+
sub_id = "sub_id_example" # String | Subscription ID.
|
|
308
|
+
|
|
309
|
+
validation_callback_request = ArtikCloud::ValidationCallbackInfo.new # ValidationCallbackInfo | Subscription validation callback request
|
|
310
|
+
|
|
311
|
+
|
|
312
|
+
begin
|
|
313
|
+
#Validate Subscription
|
|
314
|
+
result = api_instance.validate_subscription(sub_id, validation_callback_request)
|
|
315
|
+
p result
|
|
316
|
+
rescue ArtikCloud::ApiError => e
|
|
317
|
+
puts "Exception when calling SubscriptionsApi->validate_subscription: #{e}"
|
|
318
|
+
end
|
|
319
|
+
```
|
|
320
|
+
|
|
321
|
+
### Parameters
|
|
322
|
+
|
|
323
|
+
Name | Type | Description | Notes
|
|
324
|
+
------------- | ------------- | ------------- | -------------
|
|
325
|
+
**sub_id** | **String**| Subscription ID. |
|
|
326
|
+
**validation_callback_request** | [**ValidationCallbackInfo**](ValidationCallbackInfo.md)| Subscription validation callback request |
|
|
327
|
+
|
|
328
|
+
### Return type
|
|
329
|
+
|
|
330
|
+
[**SubscriptionEnvelope**](SubscriptionEnvelope.md)
|
|
331
|
+
|
|
332
|
+
### Authorization
|
|
333
|
+
|
|
334
|
+
[artikcloud_oauth](../README.md#artikcloud_oauth)
|
|
335
|
+
|
|
336
|
+
### HTTP request headers
|
|
337
|
+
|
|
338
|
+
- **Content-Type**: Not defined
|
|
339
|
+
- **Accept**: application/json
|
|
340
|
+
|
|
341
|
+
|
|
342
|
+
|