rcs 2.0.2 → 2.0.4
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/lib/rcs/brands/client.rb +52 -90
- data/lib/rcs/brands/types/{brand_contact.rb → upsert_brand_schema_contact.rb} +20 -18
- data/lib/rcs/brands/types/upsert_brand_schema_entity_type.rb +16 -0
- data/lib/rcs/brands/types/upsert_brand_schema_sector.rb +28 -0
- data/lib/rcs/brands/types/upsert_brand_schema_type.rb +16 -0
- data/lib/rcs/campaigns/dlc/client.rb +12 -12
- data/lib/rcs/campaigns/dlc/types/{upsert_dlc_campaign_help_keywords.rb → dlc_campaign_help_keywords.rb} +5 -5
- data/lib/rcs/campaigns/dlc/types/{upsert_dlc_campaign_keywords.rb → dlc_campaign_keywords.rb} +20 -20
- data/lib/rcs/campaigns/dlc/types/{upsert_dlc_campaign_links.rb → dlc_campaign_links.rb} +5 -5
- data/lib/rcs/campaigns/dlc/types/{upsert_dlc_campaign_opt_in_keywords.rb → dlc_campaign_opt_in_keywords.rb} +5 -5
- data/lib/rcs/campaigns/dlc/types/{upsert_dlc_campaign_opt_out_keywords.rb → dlc_campaign_opt_out_keywords.rb} +5 -5
- data/lib/rcs/campaigns/dlc/types/{upsert_dlc_campaign_options.rb → dlc_campaign_options.rb} +5 -5
- data/lib/rcs/campaigns/dlc/types/{upsert_dlc_campaign_use_case.rb → dlc_campaign_use_case.rb} +5 -5
- data/lib/rcs/campaigns/rcs/client.rb +144 -51
- data/lib/rcs/campaigns/rcs/types/{upsert_rcs_agent.rb → rcs_agent.rb} +15 -9
- data/lib/rcs/campaigns/rcs/types/rcs_autofill_response.rb +122 -43
- data/lib/rcs/campaigns/rcs/types/{upsert_rcs_opt_out.rb → rcs_campaign_help_keywords.rb} +20 -19
- data/lib/rcs/campaigns/rcs/types/rcs_campaign_keywords.rb +98 -0
- data/lib/rcs/campaigns/rcs/types/rcs_campaign_opt_in_keywords.rb +87 -0
- data/lib/rcs/campaigns/rcs/types/rcs_campaign_opt_out_keywords.rb +83 -0
- data/lib/rcs/campaigns/rcs/types/rcs_campaign_traffic.rb +76 -0
- data/lib/rcs/campaigns/rcs/types/{upsert_rcs_links.rb → rcs_links.rb} +5 -5
- data/lib/rcs/campaigns/rcs/types/{upsert_rcs_use_case.rb → rcs_use_case.rb} +7 -7
- data/lib/rcs/campaigns/toll_free/client.rb +53 -10
- data/lib/rcs/campaigns/toll_free/types/toll_free_autofill_response.rb +54 -12
- data/lib/rcs/campaigns/toll_free/types/toll_free_campaign_help_keywords.rb +66 -0
- data/lib/rcs/campaigns/toll_free/types/toll_free_campaign_keywords.rb +86 -0
- data/lib/rcs/campaigns/toll_free/types/toll_free_campaign_links.rb +74 -0
- data/lib/rcs/campaigns/toll_free/types/{upsert_toll_free_schema_opt_in.rb → toll_free_campaign_opt_in.rb} +5 -5
- data/lib/rcs/campaigns/toll_free/types/toll_free_campaign_opt_in_keywords.rb +78 -0
- data/lib/rcs/campaigns/toll_free/types/toll_free_campaign_options.rb +64 -0
- data/lib/rcs/campaigns/toll_free/types/{upsert_toll_free_schema_use_case.rb → toll_free_campaign_use_case.rb} +5 -5
- data/lib/rcs/messages/blast/client.rb +419 -0
- data/lib/rcs/messages/blast/types/blast_mms_options.rb +82 -0
- data/lib/rcs/messages/blast/types/blast_mms_response.rb +60 -0
- data/lib/rcs/messages/blast/types/blast_rcs_options.rb +118 -0
- data/lib/rcs/messages/blast/types/blast_rcs_request_options_standalone_card.rb +82 -0
- data/lib/rcs/messages/blast/types/blast_rcs_request_options_standalone_card_image_alignment.rb +16 -0
- data/lib/rcs/messages/blast/types/blast_rcs_request_options_standalone_card_orientation.rb +15 -0
- data/lib/rcs/messages/blast/types/blast_rcs_response.rb +60 -0
- data/lib/rcs/messages/blast/types/blast_sms_options.rb +70 -0
- data/lib/rcs/messages/blast/types/blast_sms_response.rb +60 -0
- data/lib/rcs/messages/mms/client.rb +6 -6
- data/lib/rcs/messages/mms/types/mms_send_response.rb +4 -4
- data/lib/rcs/messages/rcs/client.rb +7 -7
- data/lib/rcs/messages/rcs/types/{rcs_send_response.rb → send_rich_message_response.rb} +11 -11
- data/lib/rcs/messages/schedule/client.rb +103 -0
- data/lib/rcs/messages/sms/client.rb +6 -6
- data/lib/rcs/messages/sms/types/sms_send_response.rb +4 -4
- data/lib/rcs/types/{rcs_base.rb → base_rich_message.rb} +10 -10
- data/lib/rcs/types/blast_details.rb +110 -0
- data/lib/rcs/types/company_entity_type_enum.rb +14 -0
- data/lib/rcs/types/dlc_campaign_with_extended_brand_and_status.rb +30 -2
- data/lib/rcs/types/dlc_with_extended_brand_and_status_mno_brand_tier.rb +15 -0
- data/lib/rcs/types/dlc_with_extended_brand_and_status_mno_tcr_tier.rb +22 -0
- data/lib/rcs/types/extended_brand.rb +10 -1
- data/lib/rcs/types/extended_brand_with_vetting.rb +10 -1
- data/lib/rcs/types/extended_rcs_campaign.rb +122 -51
- data/lib/rcs/types/message_schedule.rb +52 -24
- data/lib/rcs/types/message_status_enum.rb +1 -0
- data/lib/rcs/types/optional_brand_info.rb +10 -1
- data/lib/rcs/types/rcs_campaign.rb +122 -43
- data/lib/rcs/types/rcs_campaign_schema_extra_keywords.rb +94 -0
- data/lib/rcs/types/{rcs_campaign_schema_extra_opt_out.rb → rcs_campaign_schema_extra_keywords_help.rb} +18 -17
- data/lib/rcs/types/rcs_campaign_schema_extra_keywords_opt_in.rb +73 -0
- data/lib/rcs/types/rcs_campaign_schema_extra_keywords_opt_out.rb +73 -0
- data/lib/rcs/types/rcs_campaign_schema_extra_traffic.rb +72 -0
- data/lib/rcs/types/rcs_campaign_schema_extra_use_case.rb +2 -2
- data/lib/rcs/types/rcs_campaign_schema_keywords.rb +94 -0
- data/lib/rcs/types/{rcs_campaign_schema_opt_out.rb → rcs_campaign_schema_keywords_help.rb} +18 -17
- data/lib/rcs/types/rcs_campaign_schema_keywords_opt_in.rb +73 -0
- data/lib/rcs/types/rcs_campaign_schema_keywords_opt_out.rb +73 -0
- data/lib/rcs/types/rcs_campaign_schema_traffic.rb +72 -0
- data/lib/rcs/types/rcs_campaign_schema_use_case.rb +2 -2
- data/lib/rcs/types/rcs_cards_content_cards_item.rb +4 -2
- data/lib/rcs/types/rcs_content.rb +4 -4
- data/lib/rcs/types/rcs_messaging_type_enum.rb +17 -0
- data/lib/rcs/types/rcs_validate_content.rb +8 -8
- data/lib/rcs/types/rcs_validation_result.rb +9 -2
- data/lib/rcs/types/{rcs_cards_cards_item.rb → rich_card.rb} +9 -7
- data/lib/rcs/types/{rcs_cards.rb → rich_cards.rb} +9 -9
- data/lib/rcs/types/rich_cards_message.rb +9 -9
- data/lib/rcs/types/rich_media_message.rb +5 -5
- data/lib/rcs/types/{send_rcs_card_options_standalone_card.rb → rich_standalone_card_options.rb} +9 -7
- data/lib/rcs/types/{rcs_text_content.rb → rich_text.rb} +5 -5
- data/lib/rcs/types/rich_text_message.rb +5 -5
- data/lib/rcs/types/schedule_cancel_result.rb +58 -0
- data/lib/rcs/types/scheduled_blast_details.rb +76 -0
- data/lib/rcs/types/scheduled_blast_response_config.rb +89 -0
- data/lib/rcs/types/{scheduled_messaage.rb → scheduled_message.rb} +5 -5
- data/lib/rcs/types/{send_rcs_card_options.rb → send_rich_cards_options.rb} +18 -14
- data/lib/rcs/types/{rcs_base_options.rb → send_rich_message_options.rb} +5 -5
- data/lib/rcs/types/{sent_rcs_details.rb → sent_rich_message.rb} +5 -5
- data/lib/rcs/types/toll_free_campaign.rb +54 -12
- data/lib/rcs/types/toll_free_campaign_schema_keywords.rb +82 -0
- data/lib/rcs/types/toll_free_campaign_schema_keywords_help.rb +62 -0
- data/lib/rcs/types/toll_free_campaign_schema_keywords_opt_in.rb +74 -0
- data/lib/rcs/types/toll_free_campaign_schema_links.rb +70 -0
- data/lib/rcs/types/{upsert_toll_free_campaign_opt_in.rb → toll_free_campaign_schema_opt_in.rb} +5 -5
- data/lib/rcs/types/toll_free_campaign_schema_options.rb +60 -0
- data/lib/rcs/types/{upsert_toll_free_campaign_use_case.rb → toll_free_campaign_schema_use_case.rb} +5 -5
- data/lib/rcs/types/toll_free_campaign_with_extended_brand_and_status.rb +54 -12
- data/lib/requests.rb +2 -2
- data/lib/types_export.rb +70 -34
- metadata +74 -36
- data/lib/rcs/campaigns/rcs/types/upsert_rcs_opt_in.rb +0 -75
- data/lib/rcs/types/options.rb +0 -111
- data/lib/rcs/types/rcs_campaign_opt_in_method_enum.rb +0 -15
- data/lib/rcs/types/rcs_campaign_schema_extra_opt_in.rb +0 -71
- data/lib/rcs/types/rcs_campaign_schema_opt_in.rb +0 -71
- data/lib/rcs/types/upsert_contact.rb +0 -84
|
@@ -0,0 +1,74 @@
|
|
|
1
|
+
# frozen_string_literal: true
|
|
2
|
+
|
|
3
|
+
require "ostruct"
|
|
4
|
+
require "json"
|
|
5
|
+
|
|
6
|
+
module Pinnacle
|
|
7
|
+
module Campaigns
|
|
8
|
+
module TollFree
|
|
9
|
+
module Types
|
|
10
|
+
# Legal documentation links.
|
|
11
|
+
class TollFreeCampaignLinks
|
|
12
|
+
# @return [String] Privacy policy URL.
|
|
13
|
+
attr_reader :privacy_policy
|
|
14
|
+
# @return [String] Terms of service URL.
|
|
15
|
+
attr_reader :terms_of_service
|
|
16
|
+
# @return [OpenStruct] Additional properties unmapped to the current class definition
|
|
17
|
+
attr_reader :additional_properties
|
|
18
|
+
# @return [Object]
|
|
19
|
+
attr_reader :_field_set
|
|
20
|
+
protected :_field_set
|
|
21
|
+
|
|
22
|
+
OMIT = Object.new
|
|
23
|
+
|
|
24
|
+
# @param privacy_policy [String] Privacy policy URL.
|
|
25
|
+
# @param terms_of_service [String] Terms of service URL.
|
|
26
|
+
# @param additional_properties [OpenStruct] Additional properties unmapped to the current class definition
|
|
27
|
+
# @return [Pinnacle::Campaigns::TollFree::Types::TollFreeCampaignLinks]
|
|
28
|
+
def initialize(privacy_policy: OMIT, terms_of_service: OMIT, additional_properties: nil)
|
|
29
|
+
@privacy_policy = privacy_policy if privacy_policy != OMIT
|
|
30
|
+
@terms_of_service = terms_of_service if terms_of_service != OMIT
|
|
31
|
+
@additional_properties = additional_properties
|
|
32
|
+
@_field_set = { "privacyPolicy": privacy_policy, "termsOfService": terms_of_service }.reject do |_k, v|
|
|
33
|
+
v == OMIT
|
|
34
|
+
end
|
|
35
|
+
end
|
|
36
|
+
|
|
37
|
+
# Deserialize a JSON object to an instance of TollFreeCampaignLinks
|
|
38
|
+
#
|
|
39
|
+
# @param json_object [String]
|
|
40
|
+
# @return [Pinnacle::Campaigns::TollFree::Types::TollFreeCampaignLinks]
|
|
41
|
+
def self.from_json(json_object:)
|
|
42
|
+
struct = JSON.parse(json_object, object_class: OpenStruct)
|
|
43
|
+
parsed_json = JSON.parse(json_object)
|
|
44
|
+
privacy_policy = parsed_json["privacyPolicy"]
|
|
45
|
+
terms_of_service = parsed_json["termsOfService"]
|
|
46
|
+
new(
|
|
47
|
+
privacy_policy: privacy_policy,
|
|
48
|
+
terms_of_service: terms_of_service,
|
|
49
|
+
additional_properties: struct
|
|
50
|
+
)
|
|
51
|
+
end
|
|
52
|
+
|
|
53
|
+
# Serialize an instance of TollFreeCampaignLinks to a JSON object
|
|
54
|
+
#
|
|
55
|
+
# @return [String]
|
|
56
|
+
def to_json(*_args)
|
|
57
|
+
@_field_set&.to_json
|
|
58
|
+
end
|
|
59
|
+
|
|
60
|
+
# Leveraged for Union-type generation, validate_raw attempts to parse the given
|
|
61
|
+
# hash and check each fields type against the current object's property
|
|
62
|
+
# definitions.
|
|
63
|
+
#
|
|
64
|
+
# @param obj [Object]
|
|
65
|
+
# @return [Void]
|
|
66
|
+
def self.validate_raw(obj:)
|
|
67
|
+
obj.privacy_policy&.is_a?(String) != false || raise("Passed value for field obj.privacy_policy is not the expected type, validation failed.")
|
|
68
|
+
obj.terms_of_service&.is_a?(String) != false || raise("Passed value for field obj.terms_of_service is not the expected type, validation failed.")
|
|
69
|
+
end
|
|
70
|
+
end
|
|
71
|
+
end
|
|
72
|
+
end
|
|
73
|
+
end
|
|
74
|
+
end
|
|
@@ -9,7 +9,7 @@ module Pinnacle
|
|
|
9
9
|
module TollFree
|
|
10
10
|
module Types
|
|
11
11
|
# Opt-in keyword settings.
|
|
12
|
-
class
|
|
12
|
+
class TollFreeCampaignOptIn
|
|
13
13
|
# @return [Pinnacle::Types::OptInMethodEnum]
|
|
14
14
|
attr_reader :method_
|
|
15
15
|
# @return [String] Url to opt in.
|
|
@@ -28,7 +28,7 @@ module Pinnacle
|
|
|
28
28
|
# @param url [String] Url to opt in.
|
|
29
29
|
# @param workflow_description [String] Explain how users find the opt-in.
|
|
30
30
|
# @param additional_properties [OpenStruct] Additional properties unmapped to the current class definition
|
|
31
|
-
# @return [Pinnacle::Campaigns::TollFree::Types::
|
|
31
|
+
# @return [Pinnacle::Campaigns::TollFree::Types::TollFreeCampaignOptIn]
|
|
32
32
|
def initialize(method_: OMIT, url: OMIT, workflow_description: OMIT, additional_properties: nil)
|
|
33
33
|
@method_ = method_ if method_ != OMIT
|
|
34
34
|
@url = url if url != OMIT
|
|
@@ -43,10 +43,10 @@ module Pinnacle
|
|
|
43
43
|
end
|
|
44
44
|
end
|
|
45
45
|
|
|
46
|
-
# Deserialize a JSON object to an instance of
|
|
46
|
+
# Deserialize a JSON object to an instance of TollFreeCampaignOptIn
|
|
47
47
|
#
|
|
48
48
|
# @param json_object [String]
|
|
49
|
-
# @return [Pinnacle::Campaigns::TollFree::Types::
|
|
49
|
+
# @return [Pinnacle::Campaigns::TollFree::Types::TollFreeCampaignOptIn]
|
|
50
50
|
def self.from_json(json_object:)
|
|
51
51
|
struct = JSON.parse(json_object, object_class: OpenStruct)
|
|
52
52
|
parsed_json = JSON.parse(json_object)
|
|
@@ -61,7 +61,7 @@ module Pinnacle
|
|
|
61
61
|
)
|
|
62
62
|
end
|
|
63
63
|
|
|
64
|
-
# Serialize an instance of
|
|
64
|
+
# Serialize an instance of TollFreeCampaignOptIn to a JSON object
|
|
65
65
|
#
|
|
66
66
|
# @return [String]
|
|
67
67
|
def to_json(*_args)
|
|
@@ -0,0 +1,78 @@
|
|
|
1
|
+
# frozen_string_literal: true
|
|
2
|
+
|
|
3
|
+
require "ostruct"
|
|
4
|
+
require "json"
|
|
5
|
+
|
|
6
|
+
module Pinnacle
|
|
7
|
+
module Campaigns
|
|
8
|
+
module TollFree
|
|
9
|
+
module Types
|
|
10
|
+
# Opt-in keyword settings.
|
|
11
|
+
class TollFreeCampaignOptInKeywords
|
|
12
|
+
# @return [String] Message sent when a user opt-in. Must include brand name, confirmation of
|
|
13
|
+
# subscription, and disclosures (STOP and HELP instructions, message and data
|
|
14
|
+
# rates).
|
|
15
|
+
attr_reader :message
|
|
16
|
+
# @return [Array<String>] Keywords that trigger opt-in response.
|
|
17
|
+
attr_reader :keywords
|
|
18
|
+
# @return [OpenStruct] Additional properties unmapped to the current class definition
|
|
19
|
+
attr_reader :additional_properties
|
|
20
|
+
# @return [Object]
|
|
21
|
+
attr_reader :_field_set
|
|
22
|
+
protected :_field_set
|
|
23
|
+
|
|
24
|
+
OMIT = Object.new
|
|
25
|
+
|
|
26
|
+
# @param message [String] Message sent when a user opt-in. Must include brand name, confirmation of
|
|
27
|
+
# subscription, and disclosures (STOP and HELP instructions, message and data
|
|
28
|
+
# rates).
|
|
29
|
+
# @param keywords [Array<String>] Keywords that trigger opt-in response.
|
|
30
|
+
# @param additional_properties [OpenStruct] Additional properties unmapped to the current class definition
|
|
31
|
+
# @return [Pinnacle::Campaigns::TollFree::Types::TollFreeCampaignOptInKeywords]
|
|
32
|
+
def initialize(message: OMIT, keywords: OMIT, additional_properties: nil)
|
|
33
|
+
@message = message if message != OMIT
|
|
34
|
+
@keywords = keywords if keywords != OMIT
|
|
35
|
+
@additional_properties = additional_properties
|
|
36
|
+
@_field_set = { "message": message, "keywords": keywords }.reject do |_k, v|
|
|
37
|
+
v == OMIT
|
|
38
|
+
end
|
|
39
|
+
end
|
|
40
|
+
|
|
41
|
+
# Deserialize a JSON object to an instance of TollFreeCampaignOptInKeywords
|
|
42
|
+
#
|
|
43
|
+
# @param json_object [String]
|
|
44
|
+
# @return [Pinnacle::Campaigns::TollFree::Types::TollFreeCampaignOptInKeywords]
|
|
45
|
+
def self.from_json(json_object:)
|
|
46
|
+
struct = JSON.parse(json_object, object_class: OpenStruct)
|
|
47
|
+
parsed_json = JSON.parse(json_object)
|
|
48
|
+
message = parsed_json["message"]
|
|
49
|
+
keywords = parsed_json["keywords"]
|
|
50
|
+
new(
|
|
51
|
+
message: message,
|
|
52
|
+
keywords: keywords,
|
|
53
|
+
additional_properties: struct
|
|
54
|
+
)
|
|
55
|
+
end
|
|
56
|
+
|
|
57
|
+
# Serialize an instance of TollFreeCampaignOptInKeywords to a JSON object
|
|
58
|
+
#
|
|
59
|
+
# @return [String]
|
|
60
|
+
def to_json(*_args)
|
|
61
|
+
@_field_set&.to_json
|
|
62
|
+
end
|
|
63
|
+
|
|
64
|
+
# Leveraged for Union-type generation, validate_raw attempts to parse the given
|
|
65
|
+
# hash and check each fields type against the current object's property
|
|
66
|
+
# definitions.
|
|
67
|
+
#
|
|
68
|
+
# @param obj [Object]
|
|
69
|
+
# @return [Void]
|
|
70
|
+
def self.validate_raw(obj:)
|
|
71
|
+
obj.message&.is_a?(String) != false || raise("Passed value for field obj.message is not the expected type, validation failed.")
|
|
72
|
+
obj.keywords&.is_a?(Array) != false || raise("Passed value for field obj.keywords is not the expected type, validation failed.")
|
|
73
|
+
end
|
|
74
|
+
end
|
|
75
|
+
end
|
|
76
|
+
end
|
|
77
|
+
end
|
|
78
|
+
end
|
|
@@ -0,0 +1,64 @@
|
|
|
1
|
+
# frozen_string_literal: true
|
|
2
|
+
|
|
3
|
+
require "ostruct"
|
|
4
|
+
require "json"
|
|
5
|
+
|
|
6
|
+
module Pinnacle
|
|
7
|
+
module Campaigns
|
|
8
|
+
module TollFree
|
|
9
|
+
module Types
|
|
10
|
+
# Campaign configuration options.
|
|
11
|
+
class TollFreeCampaignOptions
|
|
12
|
+
# @return [Boolean] Whether the campaign is age-gated.
|
|
13
|
+
attr_reader :age_gated
|
|
14
|
+
# @return [OpenStruct] Additional properties unmapped to the current class definition
|
|
15
|
+
attr_reader :additional_properties
|
|
16
|
+
# @return [Object]
|
|
17
|
+
attr_reader :_field_set
|
|
18
|
+
protected :_field_set
|
|
19
|
+
|
|
20
|
+
OMIT = Object.new
|
|
21
|
+
|
|
22
|
+
# @param age_gated [Boolean] Whether the campaign is age-gated.
|
|
23
|
+
# @param additional_properties [OpenStruct] Additional properties unmapped to the current class definition
|
|
24
|
+
# @return [Pinnacle::Campaigns::TollFree::Types::TollFreeCampaignOptions]
|
|
25
|
+
def initialize(age_gated: OMIT, additional_properties: nil)
|
|
26
|
+
@age_gated = age_gated if age_gated != OMIT
|
|
27
|
+
@additional_properties = additional_properties
|
|
28
|
+
@_field_set = { "ageGated": age_gated }.reject do |_k, v|
|
|
29
|
+
v == OMIT
|
|
30
|
+
end
|
|
31
|
+
end
|
|
32
|
+
|
|
33
|
+
# Deserialize a JSON object to an instance of TollFreeCampaignOptions
|
|
34
|
+
#
|
|
35
|
+
# @param json_object [String]
|
|
36
|
+
# @return [Pinnacle::Campaigns::TollFree::Types::TollFreeCampaignOptions]
|
|
37
|
+
def self.from_json(json_object:)
|
|
38
|
+
struct = JSON.parse(json_object, object_class: OpenStruct)
|
|
39
|
+
parsed_json = JSON.parse(json_object)
|
|
40
|
+
age_gated = parsed_json["ageGated"]
|
|
41
|
+
new(age_gated: age_gated, additional_properties: struct)
|
|
42
|
+
end
|
|
43
|
+
|
|
44
|
+
# Serialize an instance of TollFreeCampaignOptions to a JSON object
|
|
45
|
+
#
|
|
46
|
+
# @return [String]
|
|
47
|
+
def to_json(*_args)
|
|
48
|
+
@_field_set&.to_json
|
|
49
|
+
end
|
|
50
|
+
|
|
51
|
+
# Leveraged for Union-type generation, validate_raw attempts to parse the given
|
|
52
|
+
# hash and check each fields type against the current object's property
|
|
53
|
+
# definitions.
|
|
54
|
+
#
|
|
55
|
+
# @param obj [Object]
|
|
56
|
+
# @return [Void]
|
|
57
|
+
def self.validate_raw(obj:)
|
|
58
|
+
obj.age_gated&.is_a?(Boolean) != false || raise("Passed value for field obj.age_gated is not the expected type, validation failed.")
|
|
59
|
+
end
|
|
60
|
+
end
|
|
61
|
+
end
|
|
62
|
+
end
|
|
63
|
+
end
|
|
64
|
+
end
|
|
@@ -9,7 +9,7 @@ module Pinnacle
|
|
|
9
9
|
module TollFree
|
|
10
10
|
module Types
|
|
11
11
|
# Use case classification for the campaign.
|
|
12
|
-
class
|
|
12
|
+
class TollFreeCampaignUseCase
|
|
13
13
|
# @return [String] Summary of the use case.
|
|
14
14
|
attr_reader :summary
|
|
15
15
|
# @return [Pinnacle::Types::TollFreeCampaignUseCaseEnum]
|
|
@@ -25,7 +25,7 @@ module Pinnacle
|
|
|
25
25
|
# @param summary [String] Summary of the use case.
|
|
26
26
|
# @param value [Pinnacle::Types::TollFreeCampaignUseCaseEnum]
|
|
27
27
|
# @param additional_properties [OpenStruct] Additional properties unmapped to the current class definition
|
|
28
|
-
# @return [Pinnacle::Campaigns::TollFree::Types::
|
|
28
|
+
# @return [Pinnacle::Campaigns::TollFree::Types::TollFreeCampaignUseCase]
|
|
29
29
|
def initialize(summary: OMIT, value: OMIT, additional_properties: nil)
|
|
30
30
|
@summary = summary if summary != OMIT
|
|
31
31
|
@value = value if value != OMIT
|
|
@@ -35,10 +35,10 @@ module Pinnacle
|
|
|
35
35
|
end
|
|
36
36
|
end
|
|
37
37
|
|
|
38
|
-
# Deserialize a JSON object to an instance of
|
|
38
|
+
# Deserialize a JSON object to an instance of TollFreeCampaignUseCase
|
|
39
39
|
#
|
|
40
40
|
# @param json_object [String]
|
|
41
|
-
# @return [Pinnacle::Campaigns::TollFree::Types::
|
|
41
|
+
# @return [Pinnacle::Campaigns::TollFree::Types::TollFreeCampaignUseCase]
|
|
42
42
|
def self.from_json(json_object:)
|
|
43
43
|
struct = JSON.parse(json_object, object_class: OpenStruct)
|
|
44
44
|
parsed_json = JSON.parse(json_object)
|
|
@@ -51,7 +51,7 @@ module Pinnacle
|
|
|
51
51
|
)
|
|
52
52
|
end
|
|
53
53
|
|
|
54
|
-
# Serialize an instance of
|
|
54
|
+
# Serialize an instance of TollFreeCampaignUseCase to a JSON object
|
|
55
55
|
#
|
|
56
56
|
# @return [String]
|
|
57
57
|
def to_json(*_args)
|