test-sdk-raza 1.0.1

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.
Files changed (49) hide show
  1. checksums.yaml +7 -0
  2. data/LICENSE +28 -0
  3. data/README.md +116 -0
  4. data/lib/api_endpoints_for5_g_business_internet5_g_bi/api_helper.rb +10 -0
  5. data/lib/api_endpoints_for5_g_business_internet5_g_bi/apis/base_api.rb +67 -0
  6. data/lib/api_endpoints_for5_g_business_internet5_g_bi/apis/m5_gbi_device_actions_api.rb +91 -0
  7. data/lib/api_endpoints_for5_g_business_internet5_g_bi/apis/oauth_authorization_api.rb +44 -0
  8. data/lib/api_endpoints_for5_g_business_internet5_g_bi/client.rb +80 -0
  9. data/lib/api_endpoints_for5_g_business_internet5_g_bi/configuration.rb +116 -0
  10. data/lib/api_endpoints_for5_g_business_internet5_g_bi/exceptions/api_exception.rb +21 -0
  11. data/lib/api_endpoints_for5_g_business_internet5_g_bi/exceptions/m5_gbi_rest_error_response_exception.rb +52 -0
  12. data/lib/api_endpoints_for5_g_business_internet5_g_bi/exceptions/oauth_provider_exception.rb +64 -0
  13. data/lib/api_endpoints_for5_g_business_internet5_g_bi/http/api_response.rb +19 -0
  14. data/lib/api_endpoints_for5_g_business_internet5_g_bi/http/auth/thingspace_oauth.rb +133 -0
  15. data/lib/api_endpoints_for5_g_business_internet5_g_bi/http/auth/vz_m2_m_session_token.rb +42 -0
  16. data/lib/api_endpoints_for5_g_business_internet5_g_bi/http/http_call_back.rb +10 -0
  17. data/lib/api_endpoints_for5_g_business_internet5_g_bi/http/http_method_enum.rb +10 -0
  18. data/lib/api_endpoints_for5_g_business_internet5_g_bi/http/http_request.rb +10 -0
  19. data/lib/api_endpoints_for5_g_business_internet5_g_bi/http/http_response.rb +10 -0
  20. data/lib/api_endpoints_for5_g_business_internet5_g_bi/http/proxy_settings.rb +13 -0
  21. data/lib/api_endpoints_for5_g_business_internet5_g_bi/logging/configuration/api_logging_configuration.rb +114 -0
  22. data/lib/api_endpoints_for5_g_business_internet5_g_bi/logging/sdk_logger.rb +17 -0
  23. data/lib/api_endpoints_for5_g_business_internet5_g_bi/models/base_model.rb +110 -0
  24. data/lib/api_endpoints_for5_g_business_internet5_g_bi/models/group_name.rb +85 -0
  25. data/lib/api_endpoints_for5_g_business_internet5_g_bi/models/m5_gbi_address.rb +154 -0
  26. data/lib/api_endpoints_for5_g_business_internet5_g_bi/models/m5_gbi_carrier_information.rb +86 -0
  27. data/lib/api_endpoints_for5_g_business_internet5_g_bi/models/m5_gbi_customer_name.rb +125 -0
  28. data/lib/api_endpoints_for5_g_business_internet5_g_bi/models/m5_gbi_request_response.rb +76 -0
  29. data/lib/api_endpoints_for5_g_business_internet5_g_bi/models/m5_gbiaccount_nameobject.rb +228 -0
  30. data/lib/api_endpoints_for5_g_business_internet5_g_bi/models/m5_gbiactivate_request.rb +146 -0
  31. data/lib/api_endpoints_for5_g_business_internet5_g_bi/models/m5_gbiaddress_andcustomerinfo.rb +87 -0
  32. data/lib/api_endpoints_for5_g_business_internet5_g_bi/models/m5_gbiaddress_andcustomerinfo2.rb +87 -0
  33. data/lib/api_endpoints_for5_g_business_internet5_g_bi/models/m5_gbiattribute1.rb +84 -0
  34. data/lib/api_endpoints_for5_g_business_internet5_g_bi/models/m5_gbiattribute2.rb +95 -0
  35. data/lib/api_endpoints_for5_g_business_internet5_g_bi/models/m5_gbichange_request.rb +126 -0
  36. data/lib/api_endpoints_for5_g_business_internet5_g_bi/models/m5_gbidevice_detailsresponse.rb +95 -0
  37. data/lib/api_endpoints_for5_g_business_internet5_g_bi/models/m5_gbidevice_id.rb +76 -0
  38. data/lib/api_endpoints_for5_g_business_internet5_g_bi/models/m5_gbidevice_id1.rb +95 -0
  39. data/lib/api_endpoints_for5_g_business_internet5_g_bi/models/m5_gbidevice_idarray.rb +88 -0
  40. data/lib/api_endpoints_for5_g_business_internet5_g_bi/models/m5_gbidevice_idarray2.rb +95 -0
  41. data/lib/api_endpoints_for5_g_business_internet5_g_bi/models/m5_gbikey_value1.rb +95 -0
  42. data/lib/api_endpoints_for5_g_business_internet5_g_bi/models/m5_gbiprimary_placeofuse.rb +96 -0
  43. data/lib/api_endpoints_for5_g_business_internet5_g_bi/models/oauth_provider_error.rb +45 -0
  44. data/lib/api_endpoints_for5_g_business_internet5_g_bi/models/oauth_token.rb +96 -0
  45. data/lib/api_endpoints_for5_g_business_internet5_g_bi/utilities/date_time_helper.rb +11 -0
  46. data/lib/api_endpoints_for5_g_business_internet5_g_bi/utilities/file_wrapper.rb +28 -0
  47. data/lib/api_endpoints_for5_g_business_internet5_g_bi/utilities/union_type_lookup.rb +85 -0
  48. data/lib/api_endpoints_for5_g_business_internet5_g_bi.rb +110 -0
  49. metadata +132 -0
@@ -0,0 +1,146 @@
1
+ # api_endpoints_for5_g_business_internet5_g_bi
2
+ #
3
+ # This file was automatically
4
+ # generated by APIMATIC v3.0 ( https://www.apimatic.io ).
5
+
6
+ module ApiEndpointsFor5GBusinessInternet5GBi
7
+ # M5GbiactivateRequest Model.
8
+ class M5GbiactivateRequest < BaseModel
9
+ SKIP = Object.new
10
+ private_constant :SKIP
11
+
12
+ # TODO: Write general description for this method
13
+ # @return [String]
14
+ attr_accessor :account_name
15
+
16
+ # TODO: Write general description for this method
17
+ # @return [String]
18
+ attr_accessor :service_plan
19
+
20
+ # TODO: Write general description for this method
21
+ # @return [Array[Object]]
22
+ attr_accessor :device_list_with_service_address
23
+
24
+ # TODO: Write general description for this method
25
+ # @return [String]
26
+ attr_accessor :public_ip_restriction
27
+
28
+ # TODO: Write general description for this method
29
+ # @return [String]
30
+ attr_accessor :carrier_name
31
+
32
+ # TODO: Write general description for this method
33
+ # @return [String]
34
+ attr_accessor :mdn_zip_code
35
+
36
+ # A mapping from model property names to API property names.
37
+ def self.names
38
+ @_hash = {} if @_hash.nil?
39
+ @_hash['account_name'] = 'accountName'
40
+ @_hash['service_plan'] = 'servicePlan'
41
+ @_hash['device_list_with_service_address'] =
42
+ 'deviceListWithServiceAddress'
43
+ @_hash['public_ip_restriction'] = 'publicIpRestriction'
44
+ @_hash['carrier_name'] = 'carrierName'
45
+ @_hash['mdn_zip_code'] = 'mdnZipCode'
46
+ @_hash
47
+ end
48
+
49
+ # An array for optional fields
50
+ def self.optionals
51
+ %w[
52
+ account_name
53
+ service_plan
54
+ device_list_with_service_address
55
+ public_ip_restriction
56
+ carrier_name
57
+ mdn_zip_code
58
+ ]
59
+ end
60
+
61
+ # An array for nullable fields
62
+ def self.nullables
63
+ []
64
+ end
65
+
66
+ def initialize(account_name: SKIP, service_plan: SKIP,
67
+ device_list_with_service_address: SKIP,
68
+ public_ip_restriction: SKIP, carrier_name: SKIP,
69
+ mdn_zip_code: SKIP, additional_properties: nil)
70
+ # Add additional model properties to the instance
71
+ additional_properties = {} if additional_properties.nil?
72
+
73
+ @account_name = account_name unless account_name == SKIP
74
+ @service_plan = service_plan unless service_plan == SKIP
75
+ unless device_list_with_service_address == SKIP
76
+ @device_list_with_service_address =
77
+ device_list_with_service_address
78
+ end
79
+ @public_ip_restriction = public_ip_restriction unless public_ip_restriction == SKIP
80
+ @carrier_name = carrier_name unless carrier_name == SKIP
81
+ @mdn_zip_code = mdn_zip_code unless mdn_zip_code == SKIP
82
+ @additional_properties = additional_properties
83
+ end
84
+
85
+ # Creates an instance of the object from a hash.
86
+ def self.from_hash(hash)
87
+ return nil unless hash
88
+
89
+ # Extract variables from the hash.
90
+ account_name = hash.key?('accountName') ? hash['accountName'] : SKIP
91
+ service_plan = hash.key?('servicePlan') ? hash['servicePlan'] : SKIP
92
+ device_list_with_service_address = hash.key?('deviceListWithServiceAddress') ? APIHelper.deserialize_union_type(
93
+ UnionTypeLookUp.get(:M5GbiactivateRequestDeviceListWithServiceAddress), hash['deviceListWithServiceAddress']
94
+ ) : SKIP
95
+ public_ip_restriction =
96
+ hash.key?('publicIpRestriction') ? hash['publicIpRestriction'] : SKIP
97
+ carrier_name = hash.key?('carrierName') ? hash['carrierName'] : SKIP
98
+ mdn_zip_code = hash.key?('mdnZipCode') ? hash['mdnZipCode'] : SKIP
99
+
100
+ # Create a new hash for additional properties, removing known properties.
101
+ new_hash = hash.reject { |k, _| names.value?(k) }
102
+
103
+ additional_properties = APIHelper.get_additional_properties(
104
+ new_hash, proc { |value| value }
105
+ )
106
+
107
+ # Create object from extracted values.
108
+ M5GbiactivateRequest.new(account_name: account_name,
109
+ service_plan: service_plan,
110
+ device_list_with_service_address: device_list_with_service_address,
111
+ public_ip_restriction: public_ip_restriction,
112
+ carrier_name: carrier_name,
113
+ mdn_zip_code: mdn_zip_code,
114
+ additional_properties: additional_properties)
115
+ end
116
+
117
+ # Validates an instance of the object from a given value.
118
+ # @param [M5GbiactivateRequest | Hash] The value against the validation is performed.
119
+ def self.validate(value)
120
+ return true if value.instance_of? self
121
+
122
+ return false unless value.instance_of? Hash
123
+
124
+ true
125
+ end
126
+
127
+ # Provides a human-readable string representation of the object.
128
+ def to_s
129
+ class_name = self.class.name.split('::').last
130
+ "<#{class_name} account_name: #{@account_name}, service_plan: #{@service_plan},"\
131
+ " device_list_with_service_address: #{@device_list_with_service_address},"\
132
+ " public_ip_restriction: #{@public_ip_restriction}, carrier_name: #{@carrier_name},"\
133
+ " mdn_zip_code: #{@mdn_zip_code}, additional_properties: #{@additional_properties}>"
134
+ end
135
+
136
+ # Provides a debugging-friendly string with detailed object information.
137
+ def inspect
138
+ class_name = self.class.name.split('::').last
139
+ "<#{class_name} account_name: #{@account_name.inspect}, service_plan:"\
140
+ " #{@service_plan.inspect}, device_list_with_service_address:"\
141
+ " #{@device_list_with_service_address.inspect}, public_ip_restriction:"\
142
+ " #{@public_ip_restriction.inspect}, carrier_name: #{@carrier_name.inspect}, mdn_zip_code:"\
143
+ " #{@mdn_zip_code.inspect}, additional_properties: #{@additional_properties}>"
144
+ end
145
+ end
146
+ end
@@ -0,0 +1,87 @@
1
+ # api_endpoints_for5_g_business_internet5_g_bi
2
+ #
3
+ # This file was automatically
4
+ # generated by APIMATIC v3.0 ( https://www.apimatic.io ).
5
+
6
+ module ApiEndpointsFor5GBusinessInternet5GBi
7
+ # M5GbiaddressAndcustomerinfo Model.
8
+ class M5GbiaddressAndcustomerinfo < BaseModel
9
+ SKIP = Object.new
10
+ private_constant :SKIP
11
+
12
+ # TODO: Write general description for this method
13
+ # @return [M5GbiprimaryPlaceofuse]
14
+ attr_accessor :primary_placeofuse
15
+
16
+ # A mapping from model property names to API property names.
17
+ def self.names
18
+ @_hash = {} if @_hash.nil?
19
+ @_hash['primary_placeofuse'] = 'primaryPlaceofuse'
20
+ @_hash
21
+ end
22
+
23
+ # An array for optional fields
24
+ def self.optionals
25
+ %w[
26
+ primary_placeofuse
27
+ ]
28
+ end
29
+
30
+ # An array for nullable fields
31
+ def self.nullables
32
+ []
33
+ end
34
+
35
+ def initialize(primary_placeofuse: SKIP, additional_properties: nil)
36
+ # Add additional model properties to the instance
37
+ additional_properties = {} if additional_properties.nil?
38
+
39
+ @primary_placeofuse = primary_placeofuse unless primary_placeofuse == SKIP
40
+ @additional_properties = additional_properties
41
+ end
42
+
43
+ # Creates an instance of the object from a hash.
44
+ def self.from_hash(hash)
45
+ return nil unless hash
46
+
47
+ # Extract variables from the hash.
48
+ primary_placeofuse = M5GbiprimaryPlaceofuse.from_hash(hash['primaryPlaceofuse']) if
49
+ hash['primaryPlaceofuse']
50
+
51
+ # Create a new hash for additional properties, removing known properties.
52
+ new_hash = hash.reject { |k, _| names.value?(k) }
53
+
54
+ additional_properties = APIHelper.get_additional_properties(
55
+ new_hash, proc { |value| value }
56
+ )
57
+
58
+ # Create object from extracted values.
59
+ M5GbiaddressAndcustomerinfo.new(primary_placeofuse: primary_placeofuse,
60
+ additional_properties: additional_properties)
61
+ end
62
+
63
+ # Validates an instance of the object from a given value.
64
+ # @param [M5GbiaddressAndcustomerinfo | Hash] The value against the validation is performed.
65
+ def self.validate(value)
66
+ return true if value.instance_of? self
67
+
68
+ return false unless value.instance_of? Hash
69
+
70
+ true
71
+ end
72
+
73
+ # Provides a human-readable string representation of the object.
74
+ def to_s
75
+ class_name = self.class.name.split('::').last
76
+ "<#{class_name} primary_placeofuse: #{@primary_placeofuse}, additional_properties:"\
77
+ " #{@additional_properties}>"
78
+ end
79
+
80
+ # Provides a debugging-friendly string with detailed object information.
81
+ def inspect
82
+ class_name = self.class.name.split('::').last
83
+ "<#{class_name} primary_placeofuse: #{@primary_placeofuse.inspect}, additional_properties:"\
84
+ " #{@additional_properties}>"
85
+ end
86
+ end
87
+ end
@@ -0,0 +1,87 @@
1
+ # api_endpoints_for5_g_business_internet5_g_bi
2
+ #
3
+ # This file was automatically
4
+ # generated by APIMATIC v3.0 ( https://www.apimatic.io ).
5
+
6
+ module ApiEndpointsFor5GBusinessInternet5GBi
7
+ # M5GbiaddressAndcustomerinfo2 Model.
8
+ class M5GbiaddressAndcustomerinfo2 < BaseModel
9
+ SKIP = Object.new
10
+ private_constant :SKIP
11
+
12
+ # TODO: Write general description for this method
13
+ # @return [M5GbiaddressAndcustomerinfo]
14
+ attr_accessor :primary_placeofuse
15
+
16
+ # A mapping from model property names to API property names.
17
+ def self.names
18
+ @_hash = {} if @_hash.nil?
19
+ @_hash['primary_placeofuse'] = 'primaryPlaceofuse'
20
+ @_hash
21
+ end
22
+
23
+ # An array for optional fields
24
+ def self.optionals
25
+ %w[
26
+ primary_placeofuse
27
+ ]
28
+ end
29
+
30
+ # An array for nullable fields
31
+ def self.nullables
32
+ []
33
+ end
34
+
35
+ def initialize(primary_placeofuse: SKIP, additional_properties: nil)
36
+ # Add additional model properties to the instance
37
+ additional_properties = {} if additional_properties.nil?
38
+
39
+ @primary_placeofuse = primary_placeofuse unless primary_placeofuse == SKIP
40
+ @additional_properties = additional_properties
41
+ end
42
+
43
+ # Creates an instance of the object from a hash.
44
+ def self.from_hash(hash)
45
+ return nil unless hash
46
+
47
+ # Extract variables from the hash.
48
+ primary_placeofuse = M5GbiaddressAndcustomerinfo.from_hash(hash['primaryPlaceofuse']) if
49
+ hash['primaryPlaceofuse']
50
+
51
+ # Create a new hash for additional properties, removing known properties.
52
+ new_hash = hash.reject { |k, _| names.value?(k) }
53
+
54
+ additional_properties = APIHelper.get_additional_properties(
55
+ new_hash, proc { |value| value }
56
+ )
57
+
58
+ # Create object from extracted values.
59
+ M5GbiaddressAndcustomerinfo2.new(primary_placeofuse: primary_placeofuse,
60
+ additional_properties: additional_properties)
61
+ end
62
+
63
+ # Validates an instance of the object from a given value.
64
+ # @param [M5GbiaddressAndcustomerinfo2 | Hash] The value against the validation is performed.
65
+ def self.validate(value)
66
+ return true if value.instance_of? self
67
+
68
+ return false unless value.instance_of? Hash
69
+
70
+ true
71
+ end
72
+
73
+ # Provides a human-readable string representation of the object.
74
+ def to_s
75
+ class_name = self.class.name.split('::').last
76
+ "<#{class_name} primary_placeofuse: #{@primary_placeofuse}, additional_properties:"\
77
+ " #{@additional_properties}>"
78
+ end
79
+
80
+ # Provides a debugging-friendly string with detailed object information.
81
+ def inspect
82
+ class_name = self.class.name.split('::').last
83
+ "<#{class_name} primary_placeofuse: #{@primary_placeofuse.inspect}, additional_properties:"\
84
+ " #{@additional_properties}>"
85
+ end
86
+ end
87
+ end
@@ -0,0 +1,84 @@
1
+ # api_endpoints_for5_g_business_internet5_g_bi
2
+ #
3
+ # This file was automatically
4
+ # generated by APIMATIC v3.0 ( https://www.apimatic.io ).
5
+
6
+ module ApiEndpointsFor5GBusinessInternet5GBi
7
+ # M5Gbiattribute1 Model.
8
+ class M5Gbiattribute1 < BaseModel
9
+ SKIP = Object.new
10
+ private_constant :SKIP
11
+
12
+ # TODO: Write general description for this method
13
+ # @return [String]
14
+ attr_accessor :key
15
+
16
+ # A mapping from model property names to API property names.
17
+ def self.names
18
+ @_hash = {} if @_hash.nil?
19
+ @_hash['key'] = 'key'
20
+ @_hash
21
+ end
22
+
23
+ # An array for optional fields
24
+ def self.optionals
25
+ %w[
26
+ key
27
+ ]
28
+ end
29
+
30
+ # An array for nullable fields
31
+ def self.nullables
32
+ []
33
+ end
34
+
35
+ def initialize(key: SKIP, additional_properties: nil)
36
+ # Add additional model properties to the instance
37
+ additional_properties = {} if additional_properties.nil?
38
+
39
+ @key = key unless key == SKIP
40
+ @additional_properties = additional_properties
41
+ end
42
+
43
+ # Creates an instance of the object from a hash.
44
+ def self.from_hash(hash)
45
+ return nil unless hash
46
+
47
+ # Extract variables from the hash.
48
+ key = hash.key?('key') ? hash['key'] : SKIP
49
+
50
+ # Create a new hash for additional properties, removing known properties.
51
+ new_hash = hash.reject { |k, _| names.value?(k) }
52
+
53
+ additional_properties = APIHelper.get_additional_properties(
54
+ new_hash, proc { |value| value }
55
+ )
56
+
57
+ # Create object from extracted values.
58
+ M5Gbiattribute1.new(key: key,
59
+ additional_properties: additional_properties)
60
+ end
61
+
62
+ # Validates an instance of the object from a given value.
63
+ # @param [M5Gbiattribute1 | Hash] The value against the validation is performed.
64
+ def self.validate(value)
65
+ return true if value.instance_of? self
66
+
67
+ return false unless value.instance_of? Hash
68
+
69
+ true
70
+ end
71
+
72
+ # Provides a human-readable string representation of the object.
73
+ def to_s
74
+ class_name = self.class.name.split('::').last
75
+ "<#{class_name} key: #{@key}, additional_properties: #{@additional_properties}>"
76
+ end
77
+
78
+ # Provides a debugging-friendly string with detailed object information.
79
+ def inspect
80
+ class_name = self.class.name.split('::').last
81
+ "<#{class_name} key: #{@key.inspect}, additional_properties: #{@additional_properties}>"
82
+ end
83
+ end
84
+ end
@@ -0,0 +1,95 @@
1
+ # api_endpoints_for5_g_business_internet5_g_bi
2
+ #
3
+ # This file was automatically
4
+ # generated by APIMATIC v3.0 ( https://www.apimatic.io ).
5
+
6
+ module ApiEndpointsFor5GBusinessInternet5GBi
7
+ # M5Gbiattribute2 Model.
8
+ class M5Gbiattribute2 < BaseModel
9
+ SKIP = Object.new
10
+ private_constant :SKIP
11
+
12
+ # TODO: Write general description for this method
13
+ # @return [String]
14
+ attr_accessor :key
15
+
16
+ # TODO: Write general description for this method
17
+ # @return [String]
18
+ attr_accessor :value
19
+
20
+ # A mapping from model property names to API property names.
21
+ def self.names
22
+ @_hash = {} if @_hash.nil?
23
+ @_hash['key'] = 'key'
24
+ @_hash['value'] = 'value'
25
+ @_hash
26
+ end
27
+
28
+ # An array for optional fields
29
+ def self.optionals
30
+ %w[
31
+ key
32
+ value
33
+ ]
34
+ end
35
+
36
+ # An array for nullable fields
37
+ def self.nullables
38
+ []
39
+ end
40
+
41
+ def initialize(key: SKIP, value: SKIP, additional_properties: nil)
42
+ # Add additional model properties to the instance
43
+ additional_properties = {} if additional_properties.nil?
44
+
45
+ @key = key unless key == SKIP
46
+ @value = value unless value == SKIP
47
+ @additional_properties = additional_properties
48
+ end
49
+
50
+ # Creates an instance of the object from a hash.
51
+ def self.from_hash(hash)
52
+ return nil unless hash
53
+
54
+ # Extract variables from the hash.
55
+ key = hash.key?('key') ? hash['key'] : SKIP
56
+ value = hash.key?('value') ? hash['value'] : SKIP
57
+
58
+ # Create a new hash for additional properties, removing known properties.
59
+ new_hash = hash.reject { |k, _| names.value?(k) }
60
+
61
+ additional_properties = APIHelper.get_additional_properties(
62
+ new_hash, proc { |value| value }
63
+ )
64
+
65
+ # Create object from extracted values.
66
+ M5Gbiattribute2.new(key: key,
67
+ value: value,
68
+ additional_properties: additional_properties)
69
+ end
70
+
71
+ # Validates an instance of the object from a given value.
72
+ # @param [M5Gbiattribute2 | Hash] The value against the validation is performed.
73
+ def self.validate(value)
74
+ return true if value.instance_of? self
75
+
76
+ return false unless value.instance_of? Hash
77
+
78
+ true
79
+ end
80
+
81
+ # Provides a human-readable string representation of the object.
82
+ def to_s
83
+ class_name = self.class.name.split('::').last
84
+ "<#{class_name} key: #{@key}, value: #{@value}, additional_properties:"\
85
+ " #{@additional_properties}>"
86
+ end
87
+
88
+ # Provides a debugging-friendly string with detailed object information.
89
+ def inspect
90
+ class_name = self.class.name.split('::').last
91
+ "<#{class_name} key: #{@key.inspect}, value: #{@value.inspect}, additional_properties:"\
92
+ " #{@additional_properties}>"
93
+ end
94
+ end
95
+ end
@@ -0,0 +1,126 @@
1
+ # api_endpoints_for5_g_business_internet5_g_bi
2
+ #
3
+ # This file was automatically
4
+ # generated by APIMATIC v3.0 ( https://www.apimatic.io ).
5
+
6
+ module ApiEndpointsFor5GBusinessInternet5GBi
7
+ # M5GbichangeRequest Model.
8
+ class M5GbichangeRequest < BaseModel
9
+ SKIP = Object.new
10
+ private_constant :SKIP
11
+
12
+ # TODO: Write general description for this method
13
+ # @return [String]
14
+ attr_accessor :account_name
15
+
16
+ # TODO: Write general description for this method
17
+ # @return [String]
18
+ attr_accessor :service_plan
19
+
20
+ # TODO: Write general description for this method
21
+ # @return [Array[Object]]
22
+ attr_accessor :device_list_with_service_address
23
+
24
+ # TODO: Write general description for this method
25
+ # @return [String]
26
+ attr_accessor :current_service_plan
27
+
28
+ # A mapping from model property names to API property names.
29
+ def self.names
30
+ @_hash = {} if @_hash.nil?
31
+ @_hash['account_name'] = 'accountName'
32
+ @_hash['service_plan'] = 'servicePlan'
33
+ @_hash['device_list_with_service_address'] =
34
+ 'deviceListWithServiceAddress'
35
+ @_hash['current_service_plan'] = 'currentServicePlan'
36
+ @_hash
37
+ end
38
+
39
+ # An array for optional fields
40
+ def self.optionals
41
+ %w[
42
+ account_name
43
+ service_plan
44
+ device_list_with_service_address
45
+ current_service_plan
46
+ ]
47
+ end
48
+
49
+ # An array for nullable fields
50
+ def self.nullables
51
+ []
52
+ end
53
+
54
+ def initialize(account_name: SKIP, service_plan: SKIP,
55
+ device_list_with_service_address: SKIP,
56
+ current_service_plan: SKIP, additional_properties: nil)
57
+ # Add additional model properties to the instance
58
+ additional_properties = {} if additional_properties.nil?
59
+
60
+ @account_name = account_name unless account_name == SKIP
61
+ @service_plan = service_plan unless service_plan == SKIP
62
+ unless device_list_with_service_address == SKIP
63
+ @device_list_with_service_address =
64
+ device_list_with_service_address
65
+ end
66
+ @current_service_plan = current_service_plan unless current_service_plan == SKIP
67
+ @additional_properties = additional_properties
68
+ end
69
+
70
+ # Creates an instance of the object from a hash.
71
+ def self.from_hash(hash)
72
+ return nil unless hash
73
+
74
+ # Extract variables from the hash.
75
+ account_name = hash.key?('accountName') ? hash['accountName'] : SKIP
76
+ service_plan = hash.key?('servicePlan') ? hash['servicePlan'] : SKIP
77
+ device_list_with_service_address = hash.key?('deviceListWithServiceAddress') ? APIHelper.deserialize_union_type(
78
+ UnionTypeLookUp.get(:M5GbichangeRequestDeviceListWithServiceAddress), hash['deviceListWithServiceAddress']
79
+ ) : SKIP
80
+ current_service_plan =
81
+ hash.key?('currentServicePlan') ? hash['currentServicePlan'] : SKIP
82
+
83
+ # Create a new hash for additional properties, removing known properties.
84
+ new_hash = hash.reject { |k, _| names.value?(k) }
85
+
86
+ additional_properties = APIHelper.get_additional_properties(
87
+ new_hash, proc { |value| value }
88
+ )
89
+
90
+ # Create object from extracted values.
91
+ M5GbichangeRequest.new(account_name: account_name,
92
+ service_plan: service_plan,
93
+ device_list_with_service_address: device_list_with_service_address,
94
+ current_service_plan: current_service_plan,
95
+ additional_properties: additional_properties)
96
+ end
97
+
98
+ # Validates an instance of the object from a given value.
99
+ # @param [M5GbichangeRequest | Hash] The value against the validation is performed.
100
+ def self.validate(value)
101
+ return true if value.instance_of? self
102
+
103
+ return false unless value.instance_of? Hash
104
+
105
+ true
106
+ end
107
+
108
+ # Provides a human-readable string representation of the object.
109
+ def to_s
110
+ class_name = self.class.name.split('::').last
111
+ "<#{class_name} account_name: #{@account_name}, service_plan: #{@service_plan},"\
112
+ " device_list_with_service_address: #{@device_list_with_service_address},"\
113
+ " current_service_plan: #{@current_service_plan}, additional_properties:"\
114
+ " #{@additional_properties}>"
115
+ end
116
+
117
+ # Provides a debugging-friendly string with detailed object information.
118
+ def inspect
119
+ class_name = self.class.name.split('::').last
120
+ "<#{class_name} account_name: #{@account_name.inspect}, service_plan:"\
121
+ " #{@service_plan.inspect}, device_list_with_service_address:"\
122
+ " #{@device_list_with_service_address.inspect}, current_service_plan:"\
123
+ " #{@current_service_plan.inspect}, additional_properties: #{@additional_properties}>"
124
+ end
125
+ end
126
+ end