sdksio-verizon-apis-sdk 1.4.0 → 1.5.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/README.md +99 -86
- data/lib/verizon/client.rb +19 -16
- data/lib/verizon/configuration.rb +34 -83
- data/lib/verizon/controllers/account_devices_controller.rb +2 -2
- data/lib/verizon/controllers/account_requests_controller.rb +1 -1
- data/lib/verizon/controllers/account_subscriptions_controller.rb +1 -1
- data/lib/verizon/controllers/accounts_controller.rb +3 -3
- data/lib/verizon/controllers/anomaly_settings_controller.rb +3 -3
- data/lib/verizon/controllers/anomaly_triggers_controller.rb +5 -5
- data/lib/verizon/controllers/anomaly_triggers_v2_controller.rb +3 -3
- data/lib/verizon/controllers/billing_controller.rb +4 -4
- data/lib/verizon/controllers/campaigns_v2_controller.rb +7 -7
- data/lib/verizon/controllers/campaigns_v3_controller.rb +5 -5
- data/lib/verizon/controllers/client_logging_controller.rb +6 -6
- data/lib/verizon/controllers/cloud_connector_devices_controller.rb +6 -6
- data/lib/verizon/controllers/cloud_connector_subscriptions_controller.rb +3 -3
- data/lib/verizon/controllers/configuration_files_controller.rb +2 -2
- data/lib/verizon/controllers/connectivity_callbacks_controller.rb +3 -3
- data/lib/verizon/controllers/device_actions_controller.rb +3 -3
- data/lib/verizon/controllers/device_diagnostics_controller.rb +2 -2
- data/lib/verizon/controllers/device_groups_controller.rb +5 -5
- data/lib/verizon/controllers/device_location_callbacks_controller.rb +3 -3
- data/lib/verizon/controllers/device_management_controller.rb +29 -29
- data/lib/verizon/controllers/device_monitoring_controller.rb +7 -10
- data/lib/verizon/controllers/device_profile_management_controller.rb +4 -4
- data/lib/verizon/controllers/device_reports_controller.rb +3 -3
- data/lib/verizon/controllers/device_service_management_controller.rb +2 -2
- data/lib/verizon/controllers/device_sms_messaging_controller.rb +4 -4
- data/lib/verizon/controllers/devices_location_subscriptions_controller.rb +2 -2
- data/lib/verizon/controllers/devices_locations_controller.rb +7 -7
- data/lib/verizon/controllers/diagnostics_callbacks_controller.rb +3 -3
- data/lib/verizon/controllers/diagnostics_factory_reset_controller.rb +1 -1
- data/lib/verizon/controllers/diagnostics_history_controller.rb +1 -1
- data/lib/verizon/controllers/diagnostics_observations_controller.rb +2 -2
- data/lib/verizon/controllers/diagnostics_settings_controller.rb +1 -1
- data/lib/verizon/controllers/diagnostics_subscriptions_controller.rb +1 -1
- data/lib/verizon/controllers/euicc_device_profile_management_controller.rb +5 -5
- data/lib/verizon/controllers/exclusions_controller.rb +3 -3
- data/lib/verizon/controllers/firmware_v1_controller.rb +5 -5
- data/lib/verizon/controllers/firmware_v3_controller.rb +3 -3
- data/lib/verizon/controllers/fixed_wireless_qualification_controller.rb +1 -1
- data/lib/verizon/controllers/global_reporting_controller.rb +2 -2
- data/lib/verizon/controllers/hyper_precise_location_callbacks_controller.rb +3 -3
- data/lib/verizon/controllers/m_5g_edge_platforms_controller.rb +2 -2
- data/lib/verizon/controllers/m_v2_triggers_controller.rb +61 -0
- data/lib/verizon/controllers/managing_esim_profiles_controller.rb +6 -6
- data/lib/verizon/controllers/mec_controller.rb +7 -7
- data/lib/verizon/controllers/oauth_authorization_controller.rb +3 -3
- data/lib/verizon/controllers/performance_metrics_controller.rb +1 -1
- data/lib/verizon/controllers/promotion_period_information_controller.rb +4 -4
- data/lib/verizon/controllers/retrieve_the_triggers_controller.rb +4 -4
- data/lib/verizon/controllers/server_logging_controller.rb +1 -1
- data/lib/verizon/controllers/service_endpoints_controller.rb +6 -6
- data/lib/verizon/controllers/service_plans_controller.rb +1 -1
- data/lib/verizon/controllers/service_profiles_controller.rb +5 -5
- data/lib/verizon/controllers/session_management_controller.rb +3 -3
- data/lib/verizon/controllers/sim_actions_controller.rb +2 -2
- data/lib/verizon/controllers/sim_secure_for_io_t_licenses_controller.rb +2 -2
- data/lib/verizon/controllers/sms_controller.rb +3 -3
- data/lib/verizon/controllers/software_management_callbacks_v1_controller.rb +3 -3
- data/lib/verizon/controllers/software_management_callbacks_v2_controller.rb +4 -4
- data/lib/verizon/controllers/software_management_callbacks_v3_controller.rb +4 -4
- data/lib/verizon/controllers/software_management_licenses_v1_controller.rb +5 -5
- data/lib/verizon/controllers/software_management_licenses_v2_controller.rb +6 -6
- data/lib/verizon/controllers/software_management_licenses_v3_controller.rb +3 -3
- data/lib/verizon/controllers/software_management_reports_v1_controller.rb +3 -3
- data/lib/verizon/controllers/software_management_reports_v2_controller.rb +5 -5
- data/lib/verizon/controllers/software_management_reports_v3_controller.rb +3 -3
- data/lib/verizon/controllers/software_management_subscriptions_v1_controller.rb +2 -2
- data/lib/verizon/controllers/software_management_subscriptions_v2_controller.rb +1 -1
- data/lib/verizon/controllers/software_management_subscriptions_v3_controller.rb +1 -1
- data/lib/verizon/controllers/targets_controller.rb +4 -4
- data/lib/verizon/controllers/thing_space_quality_of_service_api_actions_controller.rb +2 -2
- data/lib/verizon/controllers/update_triggers_controller.rb +1 -1
- data/lib/verizon/controllers/usage_trigger_management_controller.rb +3 -3
- data/lib/verizon/controllers/wireless_network_performance_controller.rb +5 -5
- data/lib/verizon/exceptions/hyper_precise_location_result_exception.rb +5 -0
- data/lib/verizon/exceptions/rules_engine_rest_error_response_exception.rb +42 -0
- data/lib/verizon/http/auth/{oauth_2.rb → thingspace_oauth.rb} +18 -19
- data/lib/verizon/http/auth/vz_m2m_token.rb +42 -0
- data/lib/verizon/models/account_group_share.rb +55 -0
- data/lib/verizon/models/account_group_share_individual.rb +71 -0
- data/lib/verizon/models/action_account_group_share.rb +50 -0
- data/lib/verizon/models/aggregate_usage_item.rb +13 -2
- data/lib/verizon/models/change_plan.rb +69 -0
- data/lib/verizon/models/condition_account_group_share.rb +50 -0
- data/lib/verizon/models/create_trigger_request_options.rb +2 -2
- data/lib/verizon/models/create_trigger_v2_request.rb +113 -0
- data/lib/verizon/models/device_id_search.rb +6 -7
- data/lib/verizon/models/filter_criteria_account_group_share.rb +51 -0
- data/lib/verizon/models/notification.rb +14 -17
- data/lib/verizon/models/{oauth_scope_enum.rb → oauth_scope_thingspace_oauth_enum.rb} +18 -3
- data/lib/verizon/models/price_plan_trigger.rb +51 -0
- data/lib/verizon/models/request_body_for_usage.rb +12 -2
- data/lib/verizon/models/{usage_request_body.rb → request_body_for_usage1.rb} +6 -16
- data/lib/verizon/models/session_report.rb +15 -2
- data/lib/verizon/models/share_plan.rb +73 -0
- data/lib/verizon/models/sms_numbers.rb +60 -0
- data/lib/verizon/models/trigger_notification.rb +179 -0
- data/lib/verizon/models/trigger_type1.rb +2 -2
- data/lib/verizon/models/trigger_type2.rb +2 -2
- data/lib/verizon/models/trigger_type3.rb +2 -2
- data/lib/verizon/models/trigger_v2_response.rb +50 -0
- data/lib/verizon/models/triggers_list_options.rb +2 -2
- data/lib/verizon/models/update_trigger_request_options.rb +2 -2
- data/lib/verizon/models/update_trigger_v2_request.rb +123 -0
- data/lib/verizon.rb +20 -4
- metadata +21 -5
@@ -5,25 +5,25 @@
|
|
5
5
|
|
6
6
|
module Verizon
|
7
7
|
# Utility class for OAuth 2 authorization and token management.
|
8
|
-
class
|
8
|
+
class ThingspaceOauth < CoreLibrary::HeaderAuth
|
9
9
|
include CoreLibrary
|
10
10
|
# Display error message on occurrence of authentication failure.
|
11
11
|
# @returns [String] The oAuth error message.
|
12
12
|
def error_message
|
13
|
-
'
|
13
|
+
'ThingspaceOauth: OAuthToken is undefined or expired.'
|
14
14
|
end
|
15
15
|
|
16
16
|
# Initialization constructor.
|
17
|
-
def initialize(
|
17
|
+
def initialize(thingspace_oauth_credentials, config)
|
18
18
|
auth_params = {}
|
19
|
-
@_oauth_client_id =
|
20
|
-
|
21
|
-
@_oauth_client_secret =
|
22
|
-
|
23
|
-
@_oauth_token =
|
24
|
-
|
25
|
-
@_oauth_scopes =
|
26
|
-
|
19
|
+
@_oauth_client_id = thingspace_oauth_credentials.oauth_client_id unless
|
20
|
+
thingspace_oauth_credentials.nil? || thingspace_oauth_credentials.oauth_client_id.nil?
|
21
|
+
@_oauth_client_secret = thingspace_oauth_credentials.oauth_client_secret unless
|
22
|
+
thingspace_oauth_credentials.nil? || thingspace_oauth_credentials.oauth_client_secret.nil?
|
23
|
+
@_oauth_token = thingspace_oauth_credentials.oauth_token unless
|
24
|
+
thingspace_oauth_credentials.nil? || thingspace_oauth_credentials.oauth_token.nil?
|
25
|
+
@_oauth_scopes = thingspace_oauth_credentials.oauth_scopes unless
|
26
|
+
thingspace_oauth_credentials.nil? || thingspace_oauth_credentials.oauth_scopes.nil?
|
27
27
|
@_o_auth_api = OauthAuthorizationController.new(config)
|
28
28
|
auth_params['Authorization'] = "Bearer #{@_oauth_token.access_token}" unless @_oauth_token.nil?
|
29
29
|
|
@@ -46,7 +46,7 @@ module Verizon
|
|
46
46
|
# @param [Hash] additional_params Any additional form parameters.
|
47
47
|
# @return [OAuthToken] The oAuth token instance.
|
48
48
|
def fetch_token(additional_params: nil)
|
49
|
-
token = @_o_auth_api.
|
49
|
+
token = @_o_auth_api.request_token_thingspace_oauth(
|
50
50
|
build_basic_auth_header,
|
51
51
|
scope: !@_oauth_scopes.nil? ? Array(@_oauth_scopes).compact.join(' ') : @_oauth_scopes,
|
52
52
|
_field_parameters: additional_params
|
@@ -65,8 +65,8 @@ module Verizon
|
|
65
65
|
end
|
66
66
|
end
|
67
67
|
|
68
|
-
# Data class for
|
69
|
-
class
|
68
|
+
# Data class for ThingspaceOauthCredentials.
|
69
|
+
class ThingspaceOauthCredentials
|
70
70
|
attr_reader :oauth_client_id, :oauth_client_secret, :oauth_token,
|
71
71
|
:oauth_scopes
|
72
72
|
|
@@ -88,11 +88,10 @@ module Verizon
|
|
88
88
|
oauth_token ||= self.oauth_token
|
89
89
|
oauth_scopes ||= self.oauth_scopes
|
90
90
|
|
91
|
-
|
92
|
-
|
93
|
-
|
94
|
-
|
95
|
-
)
|
91
|
+
ThingspaceOauthCredentials.new(oauth_client_id: oauth_client_id,
|
92
|
+
oauth_client_secret: oauth_client_secret,
|
93
|
+
oauth_token: oauth_token,
|
94
|
+
oauth_scopes: oauth_scopes)
|
96
95
|
end
|
97
96
|
end
|
98
97
|
end
|
@@ -0,0 +1,42 @@
|
|
1
|
+
# verizon
|
2
|
+
#
|
3
|
+
# This file was automatically generated by APIMATIC v2.0
|
4
|
+
# ( https://apimatic.io ).
|
5
|
+
|
6
|
+
module Verizon
|
7
|
+
# Utility class for custom header authorization.
|
8
|
+
class VzM2mToken < CoreLibrary::HeaderAuth
|
9
|
+
# Display error message on occurrence of authentication failure.
|
10
|
+
# @returns [String] The oAuth error message.
|
11
|
+
def error_message
|
12
|
+
'VZM2MToken: vz_m2m_token is undefined.'
|
13
|
+
end
|
14
|
+
|
15
|
+
# Initialization constructor.
|
16
|
+
def initialize(vz_m2m_token_credentials)
|
17
|
+
auth_params = {}
|
18
|
+
auth_params['VZ-M2M-Token'] = vz_m2m_token_credentials.vz_m2m_token unless
|
19
|
+
vz_m2m_token_credentials.nil? || vz_m2m_token_credentials.vz_m2m_token.nil?
|
20
|
+
|
21
|
+
super auth_params
|
22
|
+
end
|
23
|
+
end
|
24
|
+
|
25
|
+
# Data class for VZM2MTokenCredentials.
|
26
|
+
# Data class for VZM2MTokenCredentials.
|
27
|
+
class VZM2MTokenCredentials
|
28
|
+
attr_reader :vz_m2m_token
|
29
|
+
|
30
|
+
def initialize(vz_m2m_token:)
|
31
|
+
raise ArgumentError, 'vz_m2m_token cannot be nil' if vz_m2m_token.nil?
|
32
|
+
|
33
|
+
@vz_m2m_token = vz_m2m_token
|
34
|
+
end
|
35
|
+
|
36
|
+
def clone_with(vz_m2m_token: nil)
|
37
|
+
vz_m2m_token ||= self.vz_m2m_token
|
38
|
+
|
39
|
+
VZM2MTokenCredentials.new(vz_m2m_token: vz_m2m_token)
|
40
|
+
end
|
41
|
+
end
|
42
|
+
end
|
@@ -0,0 +1,55 @@
|
|
1
|
+
# verizon
|
2
|
+
#
|
3
|
+
# This file was automatically generated by APIMATIC v2.0
|
4
|
+
# ( https://apimatic.io ).
|
5
|
+
|
6
|
+
module Verizon
|
7
|
+
# AccountGroupShare Model.
|
8
|
+
class AccountGroupShare < BaseModel
|
9
|
+
SKIP = Object.new
|
10
|
+
private_constant :SKIP
|
11
|
+
|
12
|
+
# TODO: Write general description for this method
|
13
|
+
# @return [AccountGroupShareIndividual]
|
14
|
+
attr_accessor :account_group_share_individual
|
15
|
+
|
16
|
+
# A mapping from model property names to API property names.
|
17
|
+
def self.names
|
18
|
+
@_hash = {} if @_hash.nil?
|
19
|
+
@_hash['account_group_share_individual'] = 'accountGroupShareIndividual'
|
20
|
+
@_hash
|
21
|
+
end
|
22
|
+
|
23
|
+
# An array for optional fields
|
24
|
+
def self.optionals
|
25
|
+
%w[
|
26
|
+
account_group_share_individual
|
27
|
+
]
|
28
|
+
end
|
29
|
+
|
30
|
+
# An array for nullable fields
|
31
|
+
def self.nullables
|
32
|
+
[]
|
33
|
+
end
|
34
|
+
|
35
|
+
def initialize(account_group_share_individual = SKIP)
|
36
|
+
unless account_group_share_individual == SKIP
|
37
|
+
@account_group_share_individual =
|
38
|
+
account_group_share_individual
|
39
|
+
end
|
40
|
+
end
|
41
|
+
|
42
|
+
# Creates an instance of the object from a hash.
|
43
|
+
def self.from_hash(hash)
|
44
|
+
return nil unless hash
|
45
|
+
|
46
|
+
# Extract variables from the hash.
|
47
|
+
if hash['accountGroupShareIndividual']
|
48
|
+
account_group_share_individual = AccountGroupShareIndividual.from_hash(hash['accountGroupShareIndividual'])
|
49
|
+
end
|
50
|
+
|
51
|
+
# Create object from extracted values.
|
52
|
+
AccountGroupShare.new(account_group_share_individual)
|
53
|
+
end
|
54
|
+
end
|
55
|
+
end
|
@@ -0,0 +1,71 @@
|
|
1
|
+
# verizon
|
2
|
+
#
|
3
|
+
# This file was automatically generated by APIMATIC v2.0
|
4
|
+
# ( https://apimatic.io ).
|
5
|
+
|
6
|
+
module Verizon
|
7
|
+
# AccountGroupShareIndividual Model.
|
8
|
+
class AccountGroupShareIndividual < BaseModel
|
9
|
+
SKIP = Object.new
|
10
|
+
private_constant :SKIP
|
11
|
+
|
12
|
+
# TODO: Write general description for this method
|
13
|
+
# @return [FilterCriteriaAccountGroupShare]
|
14
|
+
attr_accessor :filter_criteria
|
15
|
+
|
16
|
+
# TODO: Write general description for this method
|
17
|
+
# @return [ConditionAccountGroupShare]
|
18
|
+
attr_accessor :condition
|
19
|
+
|
20
|
+
# TODO: Write general description for this method
|
21
|
+
# @return [ActionAccountGroupShare]
|
22
|
+
attr_accessor :action
|
23
|
+
|
24
|
+
# A mapping from model property names to API property names.
|
25
|
+
def self.names
|
26
|
+
@_hash = {} if @_hash.nil?
|
27
|
+
@_hash['filter_criteria'] = 'filterCriteria'
|
28
|
+
@_hash['condition'] = 'condition'
|
29
|
+
@_hash['action'] = 'action'
|
30
|
+
@_hash
|
31
|
+
end
|
32
|
+
|
33
|
+
# An array for optional fields
|
34
|
+
def self.optionals
|
35
|
+
%w[
|
36
|
+
filter_criteria
|
37
|
+
condition
|
38
|
+
action
|
39
|
+
]
|
40
|
+
end
|
41
|
+
|
42
|
+
# An array for nullable fields
|
43
|
+
def self.nullables
|
44
|
+
[]
|
45
|
+
end
|
46
|
+
|
47
|
+
def initialize(filter_criteria = SKIP,
|
48
|
+
condition = SKIP,
|
49
|
+
action = SKIP)
|
50
|
+
@filter_criteria = filter_criteria unless filter_criteria == SKIP
|
51
|
+
@condition = condition unless condition == SKIP
|
52
|
+
@action = action unless action == SKIP
|
53
|
+
end
|
54
|
+
|
55
|
+
# Creates an instance of the object from a hash.
|
56
|
+
def self.from_hash(hash)
|
57
|
+
return nil unless hash
|
58
|
+
|
59
|
+
# Extract variables from the hash.
|
60
|
+
filter_criteria = FilterCriteriaAccountGroupShare.from_hash(hash['filterCriteria']) if
|
61
|
+
hash['filterCriteria']
|
62
|
+
condition = ConditionAccountGroupShare.from_hash(hash['condition']) if hash['condition']
|
63
|
+
action = ActionAccountGroupShare.from_hash(hash['action']) if hash['action']
|
64
|
+
|
65
|
+
# Create object from extracted values.
|
66
|
+
AccountGroupShareIndividual.new(filter_criteria,
|
67
|
+
condition,
|
68
|
+
action)
|
69
|
+
end
|
70
|
+
end
|
71
|
+
end
|
@@ -0,0 +1,50 @@
|
|
1
|
+
# verizon
|
2
|
+
#
|
3
|
+
# This file was automatically generated by APIMATIC v2.0
|
4
|
+
# ( https://apimatic.io ).
|
5
|
+
|
6
|
+
module Verizon
|
7
|
+
# ActionAccountGroupShare Model.
|
8
|
+
class ActionAccountGroupShare < BaseModel
|
9
|
+
SKIP = Object.new
|
10
|
+
private_constant :SKIP
|
11
|
+
|
12
|
+
# TODO: Write general description for this method
|
13
|
+
# @return [ChangePlan]
|
14
|
+
attr_accessor :change_plan
|
15
|
+
|
16
|
+
# A mapping from model property names to API property names.
|
17
|
+
def self.names
|
18
|
+
@_hash = {} if @_hash.nil?
|
19
|
+
@_hash['change_plan'] = 'changePlan'
|
20
|
+
@_hash
|
21
|
+
end
|
22
|
+
|
23
|
+
# An array for optional fields
|
24
|
+
def self.optionals
|
25
|
+
%w[
|
26
|
+
change_plan
|
27
|
+
]
|
28
|
+
end
|
29
|
+
|
30
|
+
# An array for nullable fields
|
31
|
+
def self.nullables
|
32
|
+
[]
|
33
|
+
end
|
34
|
+
|
35
|
+
def initialize(change_plan = SKIP)
|
36
|
+
@change_plan = change_plan unless change_plan == SKIP
|
37
|
+
end
|
38
|
+
|
39
|
+
# Creates an instance of the object from a hash.
|
40
|
+
def self.from_hash(hash)
|
41
|
+
return nil unless hash
|
42
|
+
|
43
|
+
# Extract variables from the hash.
|
44
|
+
change_plan = ChangePlan.from_hash(hash['changePlan']) if hash['changePlan']
|
45
|
+
|
46
|
+
# Create object from extracted values.
|
47
|
+
ActionAccountGroupShare.new(change_plan)
|
48
|
+
end
|
49
|
+
end
|
50
|
+
end
|
@@ -23,12 +23,18 @@ module Verizon
|
|
23
23
|
# @return [Integer]
|
24
24
|
attr_accessor :bytes_transferred
|
25
25
|
|
26
|
+
# The amount of data transferred by the device reporting usage, measured in
|
27
|
+
# Bytes.
|
28
|
+
# @return [Object]
|
29
|
+
attr_accessor :example
|
30
|
+
|
26
31
|
# A mapping from model property names to API property names.
|
27
32
|
def self.names
|
28
33
|
@_hash = {} if @_hash.nil?
|
29
34
|
@_hash['imei'] = 'imei'
|
30
35
|
@_hash['number_of_sessions'] = 'numberOfSessions'
|
31
36
|
@_hash['bytes_transferred'] = 'bytesTransferred'
|
37
|
+
@_hash['example'] = 'example'
|
32
38
|
@_hash
|
33
39
|
end
|
34
40
|
|
@@ -38,6 +44,7 @@ module Verizon
|
|
38
44
|
imei
|
39
45
|
number_of_sessions
|
40
46
|
bytes_transferred
|
47
|
+
example
|
41
48
|
]
|
42
49
|
end
|
43
50
|
|
@@ -48,10 +55,12 @@ module Verizon
|
|
48
55
|
|
49
56
|
def initialize(imei = SKIP,
|
50
57
|
number_of_sessions = SKIP,
|
51
|
-
bytes_transferred = SKIP
|
58
|
+
bytes_transferred = SKIP,
|
59
|
+
example = SKIP)
|
52
60
|
@imei = imei unless imei == SKIP
|
53
61
|
@number_of_sessions = number_of_sessions unless number_of_sessions == SKIP
|
54
62
|
@bytes_transferred = bytes_transferred unless bytes_transferred == SKIP
|
63
|
+
@example = example unless example == SKIP
|
55
64
|
end
|
56
65
|
|
57
66
|
# Creates an instance of the object from a hash.
|
@@ -64,11 +73,13 @@ module Verizon
|
|
64
73
|
hash.key?('numberOfSessions') ? hash['numberOfSessions'] : SKIP
|
65
74
|
bytes_transferred =
|
66
75
|
hash.key?('bytesTransferred') ? hash['bytesTransferred'] : SKIP
|
76
|
+
example = hash.key?('example') ? hash['example'] : SKIP
|
67
77
|
|
68
78
|
# Create object from extracted values.
|
69
79
|
AggregateUsageItem.new(imei,
|
70
80
|
number_of_sessions,
|
71
|
-
bytes_transferred
|
81
|
+
bytes_transferred,
|
82
|
+
example)
|
72
83
|
end
|
73
84
|
end
|
74
85
|
end
|
@@ -0,0 +1,69 @@
|
|
1
|
+
# verizon
|
2
|
+
#
|
3
|
+
# This file was automatically generated by APIMATIC v2.0
|
4
|
+
# ( https://apimatic.io ).
|
5
|
+
|
6
|
+
module Verizon
|
7
|
+
# ChangePlan Model.
|
8
|
+
class ChangePlan < BaseModel
|
9
|
+
SKIP = Object.new
|
10
|
+
private_constant :SKIP
|
11
|
+
|
12
|
+
# TODO: Write general description for this method
|
13
|
+
# @return [String]
|
14
|
+
attr_accessor :trigger_date
|
15
|
+
|
16
|
+
# TODO: Write general description for this method
|
17
|
+
# @return [Array[SharePlan]]
|
18
|
+
attr_accessor :share_plan
|
19
|
+
|
20
|
+
# A mapping from model property names to API property names.
|
21
|
+
def self.names
|
22
|
+
@_hash = {} if @_hash.nil?
|
23
|
+
@_hash['trigger_date'] = 'triggerDate'
|
24
|
+
@_hash['share_plan'] = 'sharePlan'
|
25
|
+
@_hash
|
26
|
+
end
|
27
|
+
|
28
|
+
# An array for optional fields
|
29
|
+
def self.optionals
|
30
|
+
%w[
|
31
|
+
trigger_date
|
32
|
+
share_plan
|
33
|
+
]
|
34
|
+
end
|
35
|
+
|
36
|
+
# An array for nullable fields
|
37
|
+
def self.nullables
|
38
|
+
[]
|
39
|
+
end
|
40
|
+
|
41
|
+
def initialize(trigger_date = SKIP,
|
42
|
+
share_plan = SKIP)
|
43
|
+
@trigger_date = trigger_date unless trigger_date == SKIP
|
44
|
+
@share_plan = share_plan unless share_plan == SKIP
|
45
|
+
end
|
46
|
+
|
47
|
+
# Creates an instance of the object from a hash.
|
48
|
+
def self.from_hash(hash)
|
49
|
+
return nil unless hash
|
50
|
+
|
51
|
+
# Extract variables from the hash.
|
52
|
+
trigger_date = hash.key?('triggerDate') ? hash['triggerDate'] : SKIP
|
53
|
+
# Parameter is an array, so we need to iterate through it
|
54
|
+
share_plan = nil
|
55
|
+
unless hash['sharePlan'].nil?
|
56
|
+
share_plan = []
|
57
|
+
hash['sharePlan'].each do |structure|
|
58
|
+
share_plan << (SharePlan.from_hash(structure) if structure)
|
59
|
+
end
|
60
|
+
end
|
61
|
+
|
62
|
+
share_plan = SKIP unless hash.key?('sharePlan')
|
63
|
+
|
64
|
+
# Create object from extracted values.
|
65
|
+
ChangePlan.new(trigger_date,
|
66
|
+
share_plan)
|
67
|
+
end
|
68
|
+
end
|
69
|
+
end
|
@@ -0,0 +1,50 @@
|
|
1
|
+
# verizon
|
2
|
+
#
|
3
|
+
# This file was automatically generated by APIMATIC v2.0
|
4
|
+
# ( https://apimatic.io ).
|
5
|
+
|
6
|
+
module Verizon
|
7
|
+
# ConditionAccountGroupShare Model.
|
8
|
+
class ConditionAccountGroupShare < BaseModel
|
9
|
+
SKIP = Object.new
|
10
|
+
private_constant :SKIP
|
11
|
+
|
12
|
+
# TODO: Write general description for this method
|
13
|
+
# @return [String]
|
14
|
+
attr_accessor :action
|
15
|
+
|
16
|
+
# A mapping from model property names to API property names.
|
17
|
+
def self.names
|
18
|
+
@_hash = {} if @_hash.nil?
|
19
|
+
@_hash['action'] = 'action'
|
20
|
+
@_hash
|
21
|
+
end
|
22
|
+
|
23
|
+
# An array for optional fields
|
24
|
+
def self.optionals
|
25
|
+
%w[
|
26
|
+
action
|
27
|
+
]
|
28
|
+
end
|
29
|
+
|
30
|
+
# An array for nullable fields
|
31
|
+
def self.nullables
|
32
|
+
[]
|
33
|
+
end
|
34
|
+
|
35
|
+
def initialize(action = SKIP)
|
36
|
+
@action = action unless action == SKIP
|
37
|
+
end
|
38
|
+
|
39
|
+
# Creates an instance of the object from a hash.
|
40
|
+
def self.from_hash(hash)
|
41
|
+
return nil unless hash
|
42
|
+
|
43
|
+
# Extract variables from the hash.
|
44
|
+
action = hash.key?('action') ? hash['action'] : SKIP
|
45
|
+
|
46
|
+
# Create object from extracted values.
|
47
|
+
ConditionAccountGroupShare.new(action)
|
48
|
+
end
|
49
|
+
end
|
50
|
+
end
|
@@ -28,7 +28,7 @@ module Verizon
|
|
28
28
|
attr_accessor :anomaly_trigger_request
|
29
29
|
|
30
30
|
# The notification details of the trigger.
|
31
|
-
# @return [
|
31
|
+
# @return [TriggerNotification]
|
32
32
|
attr_accessor :notification
|
33
33
|
|
34
34
|
# Indicates anomaly detection is active<br />True - Anomaly detection is
|
@@ -90,7 +90,7 @@ module Verizon
|
|
90
90
|
account_name = hash.key?('accountName') ? hash['accountName'] : SKIP
|
91
91
|
anomaly_trigger_request = AnomalyTriggerRequest.from_hash(hash['anomalyTriggerRequest']) if
|
92
92
|
hash['anomalyTriggerRequest']
|
93
|
-
notification =
|
93
|
+
notification = TriggerNotification.from_hash(hash['notification']) if hash['notification']
|
94
94
|
active = hash.key?('active') ? hash['active'] : SKIP
|
95
95
|
|
96
96
|
# Create object from extracted values.
|
@@ -0,0 +1,113 @@
|
|
1
|
+
# verizon
|
2
|
+
#
|
3
|
+
# This file was automatically generated by APIMATIC v2.0
|
4
|
+
# ( https://apimatic.io ).
|
5
|
+
|
6
|
+
module Verizon
|
7
|
+
# Create Trigger Request
|
8
|
+
class CreateTriggerV2Request < BaseModel
|
9
|
+
SKIP = Object.new
|
10
|
+
private_constant :SKIP
|
11
|
+
|
12
|
+
# TODO: Write general description for this method
|
13
|
+
# @return [String]
|
14
|
+
attr_accessor :trigger_name
|
15
|
+
|
16
|
+
# TODO: Write general description for this method
|
17
|
+
# @return [String]
|
18
|
+
attr_accessor :ecpd_id
|
19
|
+
|
20
|
+
# TODO: Write general description for this method
|
21
|
+
# @return [String]
|
22
|
+
attr_accessor :device_group_name
|
23
|
+
|
24
|
+
# TODO: Write general description for this method
|
25
|
+
# @return [String]
|
26
|
+
attr_accessor :trigger_category
|
27
|
+
|
28
|
+
# TODO: Write general description for this method
|
29
|
+
# @return [PricePlanTrigger]
|
30
|
+
attr_accessor :price_plan_trigger
|
31
|
+
|
32
|
+
# TODO: Write general description for this method
|
33
|
+
# @return [Notification]
|
34
|
+
attr_accessor :notification
|
35
|
+
|
36
|
+
# TODO: Write general description for this method
|
37
|
+
# @return [TrueClass | FalseClass]
|
38
|
+
attr_accessor :active
|
39
|
+
|
40
|
+
# A mapping from model property names to API property names.
|
41
|
+
def self.names
|
42
|
+
@_hash = {} if @_hash.nil?
|
43
|
+
@_hash['trigger_name'] = 'triggerName'
|
44
|
+
@_hash['ecpd_id'] = 'ecpdId'
|
45
|
+
@_hash['device_group_name'] = 'deviceGroupName'
|
46
|
+
@_hash['trigger_category'] = 'triggerCategory'
|
47
|
+
@_hash['price_plan_trigger'] = 'pricePlanTrigger'
|
48
|
+
@_hash['notification'] = 'notification'
|
49
|
+
@_hash['active'] = 'active'
|
50
|
+
@_hash
|
51
|
+
end
|
52
|
+
|
53
|
+
# An array for optional fields
|
54
|
+
def self.optionals
|
55
|
+
%w[
|
56
|
+
trigger_name
|
57
|
+
ecpd_id
|
58
|
+
device_group_name
|
59
|
+
trigger_category
|
60
|
+
price_plan_trigger
|
61
|
+
notification
|
62
|
+
active
|
63
|
+
]
|
64
|
+
end
|
65
|
+
|
66
|
+
# An array for nullable fields
|
67
|
+
def self.nullables
|
68
|
+
[]
|
69
|
+
end
|
70
|
+
|
71
|
+
def initialize(trigger_name = SKIP,
|
72
|
+
ecpd_id = SKIP,
|
73
|
+
device_group_name = SKIP,
|
74
|
+
trigger_category = SKIP,
|
75
|
+
price_plan_trigger = SKIP,
|
76
|
+
notification = SKIP,
|
77
|
+
active = SKIP)
|
78
|
+
@trigger_name = trigger_name unless trigger_name == SKIP
|
79
|
+
@ecpd_id = ecpd_id unless ecpd_id == SKIP
|
80
|
+
@device_group_name = device_group_name unless device_group_name == SKIP
|
81
|
+
@trigger_category = trigger_category unless trigger_category == SKIP
|
82
|
+
@price_plan_trigger = price_plan_trigger unless price_plan_trigger == SKIP
|
83
|
+
@notification = notification unless notification == SKIP
|
84
|
+
@active = active unless active == SKIP
|
85
|
+
end
|
86
|
+
|
87
|
+
# Creates an instance of the object from a hash.
|
88
|
+
def self.from_hash(hash)
|
89
|
+
return nil unless hash
|
90
|
+
|
91
|
+
# Extract variables from the hash.
|
92
|
+
trigger_name = hash.key?('triggerName') ? hash['triggerName'] : SKIP
|
93
|
+
ecpd_id = hash.key?('ecpdId') ? hash['ecpdId'] : SKIP
|
94
|
+
device_group_name =
|
95
|
+
hash.key?('deviceGroupName') ? hash['deviceGroupName'] : SKIP
|
96
|
+
trigger_category =
|
97
|
+
hash.key?('triggerCategory') ? hash['triggerCategory'] : SKIP
|
98
|
+
price_plan_trigger = PricePlanTrigger.from_hash(hash['pricePlanTrigger']) if
|
99
|
+
hash['pricePlanTrigger']
|
100
|
+
notification = Notification.from_hash(hash['notification']) if hash['notification']
|
101
|
+
active = hash.key?('active') ? hash['active'] : SKIP
|
102
|
+
|
103
|
+
# Create object from extracted values.
|
104
|
+
CreateTriggerV2Request.new(trigger_name,
|
105
|
+
ecpd_id,
|
106
|
+
device_group_name,
|
107
|
+
trigger_category,
|
108
|
+
price_plan_trigger,
|
109
|
+
notification,
|
110
|
+
active)
|
111
|
+
end
|
112
|
+
end
|
113
|
+
end
|
@@ -40,7 +40,6 @@ module Verizon
|
|
40
40
|
# An array for optional fields
|
41
41
|
def self.optionals
|
42
42
|
%w[
|
43
|
-
contains
|
44
43
|
startswith
|
45
44
|
endswith
|
46
45
|
]
|
@@ -51,11 +50,11 @@ module Verizon
|
|
51
50
|
[]
|
52
51
|
end
|
53
52
|
|
54
|
-
def initialize(
|
55
|
-
|
53
|
+
def initialize(contains = nil,
|
54
|
+
kind = nil,
|
56
55
|
startswith = SKIP,
|
57
56
|
endswith = SKIP)
|
58
|
-
@contains = contains
|
57
|
+
@contains = contains
|
59
58
|
@startswith = startswith unless startswith == SKIP
|
60
59
|
@endswith = endswith unless endswith == SKIP
|
61
60
|
@kind = kind
|
@@ -66,14 +65,14 @@ module Verizon
|
|
66
65
|
return nil unless hash
|
67
66
|
|
68
67
|
# Extract variables from the hash.
|
68
|
+
contains = hash.key?('contains') ? hash['contains'] : nil
|
69
69
|
kind = hash.key?('kind') ? hash['kind'] : nil
|
70
|
-
contains = hash.key?('contains') ? hash['contains'] : SKIP
|
71
70
|
startswith = hash.key?('startswith') ? hash['startswith'] : SKIP
|
72
71
|
endswith = hash.key?('endswith') ? hash['endswith'] : SKIP
|
73
72
|
|
74
73
|
# Create object from extracted values.
|
75
|
-
DeviceIdSearch.new(
|
76
|
-
|
74
|
+
DeviceIdSearch.new(contains,
|
75
|
+
kind,
|
77
76
|
startswith,
|
78
77
|
endswith)
|
79
78
|
end
|
@@ -0,0 +1,51 @@
|
|
1
|
+
# verizon
|
2
|
+
#
|
3
|
+
# This file was automatically generated by APIMATIC v2.0
|
4
|
+
# ( https://apimatic.io ).
|
5
|
+
|
6
|
+
module Verizon
|
7
|
+
# FilterCriteriaAccountGroupShare Model.
|
8
|
+
class FilterCriteriaAccountGroupShare < BaseModel
|
9
|
+
SKIP = Object.new
|
10
|
+
private_constant :SKIP
|
11
|
+
|
12
|
+
# TODO: Write general description for this method
|
13
|
+
# @return [Integer]
|
14
|
+
attr_accessor :rate_plan_group_id
|
15
|
+
|
16
|
+
# A mapping from model property names to API property names.
|
17
|
+
def self.names
|
18
|
+
@_hash = {} if @_hash.nil?
|
19
|
+
@_hash['rate_plan_group_id'] = 'ratePlanGroupId'
|
20
|
+
@_hash
|
21
|
+
end
|
22
|
+
|
23
|
+
# An array for optional fields
|
24
|
+
def self.optionals
|
25
|
+
%w[
|
26
|
+
rate_plan_group_id
|
27
|
+
]
|
28
|
+
end
|
29
|
+
|
30
|
+
# An array for nullable fields
|
31
|
+
def self.nullables
|
32
|
+
[]
|
33
|
+
end
|
34
|
+
|
35
|
+
def initialize(rate_plan_group_id = SKIP)
|
36
|
+
@rate_plan_group_id = rate_plan_group_id unless rate_plan_group_id == SKIP
|
37
|
+
end
|
38
|
+
|
39
|
+
# Creates an instance of the object from a hash.
|
40
|
+
def self.from_hash(hash)
|
41
|
+
return nil unless hash
|
42
|
+
|
43
|
+
# Extract variables from the hash.
|
44
|
+
rate_plan_group_id =
|
45
|
+
hash.key?('ratePlanGroupId') ? hash['ratePlanGroupId'] : SKIP
|
46
|
+
|
47
|
+
# Create object from extracted values.
|
48
|
+
FilterCriteriaAccountGroupShare.new(rate_plan_group_id)
|
49
|
+
end
|
50
|
+
end
|
51
|
+
end
|