Class: Pingram::TenDlcCampaignRegistrationDetails
- Inherits:
-
ApiModelBase
- Object
- ApiModelBase
- Pingram::TenDlcCampaignRegistrationDetails
- Defined in:
- lib/pingram/models/ten_dlc_campaign_registration_details.rb
Overview
Admin GET/PATCH response for 10DLC campaign registration
Defined Under Namespace
Classes: EnumAttributeValidator
Instance Attribute Summary collapse
-
#account_id ⇒ Object
Returns the value of attribute account_id.
-
#campaign_age_gated ⇒ Object
Returns the value of attribute campaign_age_gated.
-
#campaign_description ⇒ Object
Returns the value of attribute campaign_description.
-
#campaign_direct_lending ⇒ Object
Returns the value of attribute campaign_direct_lending.
-
#campaign_embedded_link ⇒ Object
Returns the value of attribute campaign_embedded_link.
-
#campaign_embedded_link_url ⇒ Object
Returns the value of attribute campaign_embedded_link_url.
-
#campaign_embedded_phone ⇒ Object
Returns the value of attribute campaign_embedded_phone.
-
#campaign_help_keywords ⇒ Object
Returns the value of attribute campaign_help_keywords.
-
#campaign_help_message ⇒ Object
Returns the value of attribute campaign_help_message.
-
#campaign_id ⇒ Object
Returns the value of attribute campaign_id.
-
#campaign_message_flow ⇒ Object
Returns the value of attribute campaign_message_flow.
-
#campaign_optin_keywords ⇒ Object
Returns the value of attribute campaign_optin_keywords.
-
#campaign_optin_message ⇒ Object
Returns the value of attribute campaign_optin_message.
-
#campaign_optout_keywords ⇒ Object
Returns the value of attribute campaign_optout_keywords.
-
#campaign_optout_message ⇒ Object
Returns the value of attribute campaign_optout_message.
-
#campaign_privacy_policy_link ⇒ Object
Returns the value of attribute campaign_privacy_policy_link.
-
#campaign_sample1 ⇒ Object
Returns the value of attribute campaign_sample1.
-
#campaign_sample2 ⇒ Object
Returns the value of attribute campaign_sample2.
-
#campaign_sample3 ⇒ Object
Returns the value of attribute campaign_sample3.
-
#campaign_sample4 ⇒ Object
Returns the value of attribute campaign_sample4.
-
#campaign_status ⇒ Object
Pingram-side brand registration workflow status.
-
#campaign_terms_and_conditions_link ⇒ Object
Returns the value of attribute campaign_terms_and_conditions_link.
-
#campaign_usecase ⇒ Object
Returns the value of attribute campaign_usecase.
-
#created_at ⇒ Object
Returns the value of attribute created_at.
-
#updated_at ⇒ Object
Returns the value of attribute updated_at.
Class Method Summary collapse
-
.acceptable_attribute_map ⇒ Object
Returns attribute mapping this model knows about.
-
.acceptable_attributes ⇒ Object
Returns all the JSON keys this model knows about.
-
.attribute_map ⇒ Object
Attribute mapping from ruby-style variable name to JSON key.
-
.build_from_hash(attributes) ⇒ Object
Builds the object from hash.
-
.openapi_nullable ⇒ Object
List of attributes with nullable: true.
-
.openapi_types ⇒ Object
Attribute type mapping.
Instance Method Summary collapse
-
#==(o) ⇒ Object
Checks equality by comparing each attribute.
- #eql?(o) ⇒ Boolean
-
#hash ⇒ Integer
Calculates hash code according to all attributes.
-
#initialize(attributes = {}) ⇒ TenDlcCampaignRegistrationDetails
constructor
Initializes the object.
-
#list_invalid_properties ⇒ Object
Show invalid properties with the reasons.
-
#to_hash ⇒ Hash
Returns the object in the form of hash.
-
#valid? ⇒ Boolean
Check to see if the all the properties in the model are valid.
Methods inherited from ApiModelBase
_deserialize, #_to_hash, #to_body, #to_s
Constructor Details
#initialize(attributes = {}) ⇒ TenDlcCampaignRegistrationDetails
Initializes the object
172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 206 207 208 209 210 211 212 213 214 215 216 217 218 219 220 221 222 223 224 225 226 227 228 229 230 231 232 233 234 235 236 237 238 239 240 241 242 243 244 245 246 247 248 249 250 251 252 253 254 255 256 257 258 259 260 261 262 263 264 265 266 267 268 269 270 271 272 273 274 275 276 277 278 279 280 281 282 283 284 285 286 287 288 289 290 291 292 293 |
# File 'lib/pingram/models/ten_dlc_campaign_registration_details.rb', line 172 def initialize(attributes = {}) if (!attributes.is_a?(Hash)) fail ArgumentError, "The input argument (attributes) must be a hash in `Pingram::TenDlcCampaignRegistrationDetails` initialize method" end # check to see if the attribute exists and convert string to symbol for hash key acceptable_attribute_map = self.class.acceptable_attribute_map attributes = attributes.each_with_object({}) { |(k, v), h| if (!acceptable_attribute_map.key?(k.to_sym)) fail ArgumentError, "`#{k}` is not a valid attribute in `Pingram::TenDlcCampaignRegistrationDetails`. Please check the name to make sure it's valid. List of attributes: " + acceptable_attribute_map.keys.inspect end h[k.to_sym] = v } if attributes.key?(:'account_id') self.account_id = attributes[:'account_id'] else self.account_id = nil end if attributes.key?(:'campaign_status') self.campaign_status = attributes[:'campaign_status'] else self.campaign_status = nil end if attributes.key?(:'campaign_description') self.campaign_description = attributes[:'campaign_description'] end if attributes.key?(:'campaign_sample1') self.campaign_sample1 = attributes[:'campaign_sample1'] end if attributes.key?(:'campaign_sample2') self.campaign_sample2 = attributes[:'campaign_sample2'] end if attributes.key?(:'campaign_sample3') self.campaign_sample3 = attributes[:'campaign_sample3'] end if attributes.key?(:'campaign_sample4') self.campaign_sample4 = attributes[:'campaign_sample4'] end if attributes.key?(:'campaign_message_flow') self. = attributes[:'campaign_message_flow'] end if attributes.key?(:'campaign_optin_keywords') self.campaign_optin_keywords = attributes[:'campaign_optin_keywords'] end if attributes.key?(:'campaign_optin_message') self. = attributes[:'campaign_optin_message'] end if attributes.key?(:'campaign_optout_keywords') self.campaign_optout_keywords = attributes[:'campaign_optout_keywords'] end if attributes.key?(:'campaign_optout_message') self. = attributes[:'campaign_optout_message'] end if attributes.key?(:'campaign_help_keywords') self.campaign_help_keywords = attributes[:'campaign_help_keywords'] end if attributes.key?(:'campaign_help_message') self. = attributes[:'campaign_help_message'] end if attributes.key?(:'campaign_embedded_link') self. = attributes[:'campaign_embedded_link'] end if attributes.key?(:'campaign_embedded_link_url') self. = attributes[:'campaign_embedded_link_url'] end if attributes.key?(:'campaign_embedded_phone') self. = attributes[:'campaign_embedded_phone'] end if attributes.key?(:'campaign_age_gated') self.campaign_age_gated = attributes[:'campaign_age_gated'] end if attributes.key?(:'campaign_direct_lending') self.campaign_direct_lending = attributes[:'campaign_direct_lending'] end if attributes.key?(:'campaign_privacy_policy_link') self.campaign_privacy_policy_link = attributes[:'campaign_privacy_policy_link'] end if attributes.key?(:'campaign_terms_and_conditions_link') self.campaign_terms_and_conditions_link = attributes[:'campaign_terms_and_conditions_link'] end if attributes.key?(:'campaign_usecase') self.campaign_usecase = attributes[:'campaign_usecase'] end if attributes.key?(:'campaign_id') self.campaign_id = attributes[:'campaign_id'] end if attributes.key?(:'created_at') self.created_at = attributes[:'created_at'] else self.created_at = nil end if attributes.key?(:'updated_at') self.updated_at = attributes[:'updated_at'] else self.updated_at = nil end end |
Instance Attribute Details
#account_id ⇒ Object
Returns the value of attribute account_id.
19 20 21 |
# File 'lib/pingram/models/ten_dlc_campaign_registration_details.rb', line 19 def account_id @account_id end |
#campaign_age_gated ⇒ Object
Returns the value of attribute campaign_age_gated.
54 55 56 |
# File 'lib/pingram/models/ten_dlc_campaign_registration_details.rb', line 54 def campaign_age_gated @campaign_age_gated end |
#campaign_description ⇒ Object
Returns the value of attribute campaign_description.
24 25 26 |
# File 'lib/pingram/models/ten_dlc_campaign_registration_details.rb', line 24 def campaign_description @campaign_description end |
#campaign_direct_lending ⇒ Object
Returns the value of attribute campaign_direct_lending.
56 57 58 |
# File 'lib/pingram/models/ten_dlc_campaign_registration_details.rb', line 56 def campaign_direct_lending @campaign_direct_lending end |
#campaign_embedded_link ⇒ Object
Returns the value of attribute campaign_embedded_link.
48 49 50 |
# File 'lib/pingram/models/ten_dlc_campaign_registration_details.rb', line 48 def @campaign_embedded_link end |
#campaign_embedded_link_url ⇒ Object
Returns the value of attribute campaign_embedded_link_url.
50 51 52 |
# File 'lib/pingram/models/ten_dlc_campaign_registration_details.rb', line 50 def @campaign_embedded_link_url end |
#campaign_embedded_phone ⇒ Object
Returns the value of attribute campaign_embedded_phone.
52 53 54 |
# File 'lib/pingram/models/ten_dlc_campaign_registration_details.rb', line 52 def @campaign_embedded_phone end |
#campaign_help_keywords ⇒ Object
Returns the value of attribute campaign_help_keywords.
44 45 46 |
# File 'lib/pingram/models/ten_dlc_campaign_registration_details.rb', line 44 def campaign_help_keywords @campaign_help_keywords end |
#campaign_help_message ⇒ Object
Returns the value of attribute campaign_help_message.
46 47 48 |
# File 'lib/pingram/models/ten_dlc_campaign_registration_details.rb', line 46 def @campaign_help_message end |
#campaign_id ⇒ Object
Returns the value of attribute campaign_id.
64 65 66 |
# File 'lib/pingram/models/ten_dlc_campaign_registration_details.rb', line 64 def campaign_id @campaign_id end |
#campaign_message_flow ⇒ Object
Returns the value of attribute campaign_message_flow.
34 35 36 |
# File 'lib/pingram/models/ten_dlc_campaign_registration_details.rb', line 34 def @campaign_message_flow end |
#campaign_optin_keywords ⇒ Object
Returns the value of attribute campaign_optin_keywords.
36 37 38 |
# File 'lib/pingram/models/ten_dlc_campaign_registration_details.rb', line 36 def campaign_optin_keywords @campaign_optin_keywords end |
#campaign_optin_message ⇒ Object
Returns the value of attribute campaign_optin_message.
38 39 40 |
# File 'lib/pingram/models/ten_dlc_campaign_registration_details.rb', line 38 def @campaign_optin_message end |
#campaign_optout_keywords ⇒ Object
Returns the value of attribute campaign_optout_keywords.
40 41 42 |
# File 'lib/pingram/models/ten_dlc_campaign_registration_details.rb', line 40 def campaign_optout_keywords @campaign_optout_keywords end |
#campaign_optout_message ⇒ Object
Returns the value of attribute campaign_optout_message.
42 43 44 |
# File 'lib/pingram/models/ten_dlc_campaign_registration_details.rb', line 42 def @campaign_optout_message end |
#campaign_privacy_policy_link ⇒ Object
Returns the value of attribute campaign_privacy_policy_link.
58 59 60 |
# File 'lib/pingram/models/ten_dlc_campaign_registration_details.rb', line 58 def campaign_privacy_policy_link @campaign_privacy_policy_link end |
#campaign_sample1 ⇒ Object
Returns the value of attribute campaign_sample1.
26 27 28 |
# File 'lib/pingram/models/ten_dlc_campaign_registration_details.rb', line 26 def campaign_sample1 @campaign_sample1 end |
#campaign_sample2 ⇒ Object
Returns the value of attribute campaign_sample2.
28 29 30 |
# File 'lib/pingram/models/ten_dlc_campaign_registration_details.rb', line 28 def campaign_sample2 @campaign_sample2 end |
#campaign_sample3 ⇒ Object
Returns the value of attribute campaign_sample3.
30 31 32 |
# File 'lib/pingram/models/ten_dlc_campaign_registration_details.rb', line 30 def campaign_sample3 @campaign_sample3 end |
#campaign_sample4 ⇒ Object
Returns the value of attribute campaign_sample4.
32 33 34 |
# File 'lib/pingram/models/ten_dlc_campaign_registration_details.rb', line 32 def campaign_sample4 @campaign_sample4 end |
#campaign_status ⇒ Object
Pingram-side brand registration workflow status. - not_started: no customer submission yet - pending_review: customer submitted; Pingram has not submitted to carriers - in_progress: submitted for carrier review - approved | rejected | info_needed: review outcome
22 23 24 |
# File 'lib/pingram/models/ten_dlc_campaign_registration_details.rb', line 22 def campaign_status @campaign_status end |
#campaign_terms_and_conditions_link ⇒ Object
Returns the value of attribute campaign_terms_and_conditions_link.
60 61 62 |
# File 'lib/pingram/models/ten_dlc_campaign_registration_details.rb', line 60 def campaign_terms_and_conditions_link @campaign_terms_and_conditions_link end |
#campaign_usecase ⇒ Object
Returns the value of attribute campaign_usecase.
62 63 64 |
# File 'lib/pingram/models/ten_dlc_campaign_registration_details.rb', line 62 def campaign_usecase @campaign_usecase end |
#created_at ⇒ Object
Returns the value of attribute created_at.
66 67 68 |
# File 'lib/pingram/models/ten_dlc_campaign_registration_details.rb', line 66 def created_at @created_at end |
#updated_at ⇒ Object
Returns the value of attribute updated_at.
68 69 70 |
# File 'lib/pingram/models/ten_dlc_campaign_registration_details.rb', line 68 def updated_at @updated_at end |
Class Method Details
.acceptable_attribute_map ⇒ Object
Returns attribute mapping this model knows about
124 125 126 |
# File 'lib/pingram/models/ten_dlc_campaign_registration_details.rb', line 124 def self.acceptable_attribute_map attribute_map end |
.acceptable_attributes ⇒ Object
Returns all the JSON keys this model knows about
129 130 131 |
# File 'lib/pingram/models/ten_dlc_campaign_registration_details.rb', line 129 def self.acceptable_attributes acceptable_attribute_map.values end |
.attribute_map ⇒ Object
Attribute mapping from ruby-style variable name to JSON key.
93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 |
# File 'lib/pingram/models/ten_dlc_campaign_registration_details.rb', line 93 def self.attribute_map { :'account_id' => :'accountId', :'campaign_status' => :'campaignStatus', :'campaign_description' => :'campaignDescription', :'campaign_sample1' => :'campaignSample1', :'campaign_sample2' => :'campaignSample2', :'campaign_sample3' => :'campaignSample3', :'campaign_sample4' => :'campaignSample4', :'campaign_message_flow' => :'campaignMessageFlow', :'campaign_optin_keywords' => :'campaignOptinKeywords', :'campaign_optin_message' => :'campaignOptinMessage', :'campaign_optout_keywords' => :'campaignOptoutKeywords', :'campaign_optout_message' => :'campaignOptoutMessage', :'campaign_help_keywords' => :'campaignHelpKeywords', :'campaign_help_message' => :'campaignHelpMessage', :'campaign_embedded_link' => :'campaignEmbeddedLink', :'campaign_embedded_link_url' => :'campaignEmbeddedLinkUrl', :'campaign_embedded_phone' => :'campaignEmbeddedPhone', :'campaign_age_gated' => :'campaignAgeGated', :'campaign_direct_lending' => :'campaignDirectLending', :'campaign_privacy_policy_link' => :'campaignPrivacyPolicyLink', :'campaign_terms_and_conditions_link' => :'campaignTermsAndConditionsLink', :'campaign_usecase' => :'campaignUsecase', :'campaign_id' => :'campaignId', :'created_at' => :'createdAt', :'updated_at' => :'updatedAt' } end |
.build_from_hash(attributes) ⇒ Object
Builds the object from hash
419 420 421 422 423 424 425 426 427 428 429 430 431 432 433 434 435 436 437 |
# File 'lib/pingram/models/ten_dlc_campaign_registration_details.rb', line 419 def self.build_from_hash(attributes) return nil unless attributes.is_a?(Hash) attributes = attributes.transform_keys(&:to_sym) transformed_hash = {} openapi_types.each_pair do |key, type| if attributes.key?(attribute_map[key]) && attributes[attribute_map[key]].nil? transformed_hash["#{key}"] = nil elsif type =~ /\AArray<(.*)>/i # check to ensure the input is an array given that the attribute # is documented as an array but the input is not if attributes[attribute_map[key]].is_a?(Array) transformed_hash["#{key}"] = attributes[attribute_map[key]].map { |v| _deserialize($1, v) } end elsif !attributes[attribute_map[key]].nil? transformed_hash["#{key}"] = _deserialize(type, attributes[attribute_map[key]]) end end new(transformed_hash) end |
.openapi_nullable ⇒ Object
List of attributes with nullable: true
165 166 167 168 |
# File 'lib/pingram/models/ten_dlc_campaign_registration_details.rb', line 165 def self.openapi_nullable Set.new([ ]) end |
.openapi_types ⇒ Object
Attribute type mapping.
134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 |
# File 'lib/pingram/models/ten_dlc_campaign_registration_details.rb', line 134 def self.openapi_types { :'account_id' => :'String', :'campaign_status' => :'String', :'campaign_description' => :'String', :'campaign_sample1' => :'String', :'campaign_sample2' => :'String', :'campaign_sample3' => :'String', :'campaign_sample4' => :'String', :'campaign_message_flow' => :'String', :'campaign_optin_keywords' => :'String', :'campaign_optin_message' => :'String', :'campaign_optout_keywords' => :'String', :'campaign_optout_message' => :'String', :'campaign_help_keywords' => :'String', :'campaign_help_message' => :'String', :'campaign_embedded_link' => :'Boolean', :'campaign_embedded_link_url' => :'String', :'campaign_embedded_phone' => :'Boolean', :'campaign_age_gated' => :'Boolean', :'campaign_direct_lending' => :'Boolean', :'campaign_privacy_policy_link' => :'String', :'campaign_terms_and_conditions_link' => :'String', :'campaign_usecase' => :'String', :'campaign_id' => :'String', :'created_at' => :'String', :'updated_at' => :'String' } end |
Instance Method Details
#==(o) ⇒ Object
Checks equality by comparing each attribute.
374 375 376 377 378 379 380 381 382 383 384 385 386 387 388 389 390 391 392 393 394 395 396 397 398 399 400 401 402 |
# File 'lib/pingram/models/ten_dlc_campaign_registration_details.rb', line 374 def ==(o) return true if self.equal?(o) self.class == o.class && account_id == o.account_id && campaign_status == o.campaign_status && campaign_description == o.campaign_description && campaign_sample1 == o.campaign_sample1 && campaign_sample2 == o.campaign_sample2 && campaign_sample3 == o.campaign_sample3 && campaign_sample4 == o.campaign_sample4 && == o. && campaign_optin_keywords == o.campaign_optin_keywords && == o. && campaign_optout_keywords == o.campaign_optout_keywords && == o. && campaign_help_keywords == o.campaign_help_keywords && == o. && == o. && == o. && == o. && campaign_age_gated == o.campaign_age_gated && campaign_direct_lending == o.campaign_direct_lending && campaign_privacy_policy_link == o.campaign_privacy_policy_link && campaign_terms_and_conditions_link == o.campaign_terms_and_conditions_link && campaign_usecase == o.campaign_usecase && campaign_id == o.campaign_id && created_at == o.created_at && updated_at == o.updated_at end |
#eql?(o) ⇒ Boolean
406 407 408 |
# File 'lib/pingram/models/ten_dlc_campaign_registration_details.rb', line 406 def eql?(o) self == o end |
#hash ⇒ Integer
Calculates hash code according to all attributes.
412 413 414 |
# File 'lib/pingram/models/ten_dlc_campaign_registration_details.rb', line 412 def hash [account_id, campaign_status, campaign_description, campaign_sample1, campaign_sample2, campaign_sample3, campaign_sample4, , campaign_optin_keywords, , campaign_optout_keywords, , campaign_help_keywords, , , , , campaign_age_gated, campaign_direct_lending, campaign_privacy_policy_link, campaign_terms_and_conditions_link, campaign_usecase, campaign_id, created_at, updated_at].hash end |
#list_invalid_properties ⇒ Object
Show invalid properties with the reasons. Usually used together with valid?
297 298 299 300 301 302 303 304 305 306 307 308 309 310 311 312 313 314 315 316 317 |
# File 'lib/pingram/models/ten_dlc_campaign_registration_details.rb', line 297 def list_invalid_properties warn '[DEPRECATED] the `list_invalid_properties` method is obsolete' invalid_properties = Array.new if @account_id.nil? invalid_properties.push('invalid value for "account_id", account_id cannot be nil.') end if @campaign_status.nil? invalid_properties.push('invalid value for "campaign_status", campaign_status cannot be nil.') end if @created_at.nil? invalid_properties.push('invalid value for "created_at", created_at cannot be nil.') end if @updated_at.nil? invalid_properties.push('invalid value for "updated_at", updated_at cannot be nil.') end invalid_properties end |
#to_hash ⇒ Hash
Returns the object in the form of hash
441 442 443 444 445 446 447 448 449 450 451 452 453 |
# File 'lib/pingram/models/ten_dlc_campaign_registration_details.rb', line 441 def to_hash hash = {} self.class.attribute_map.each_pair do |attr, param| value = self.send(attr) if value.nil? is_nullable = self.class.openapi_nullable.include?(attr) next if !is_nullable || (is_nullable && !instance_variable_defined?(:"@#{attr}")) end hash[param] = _to_hash(value) end hash end |
#valid? ⇒ Boolean
Check to see if the all the properties in the model are valid
321 322 323 324 325 326 327 328 329 330 |
# File 'lib/pingram/models/ten_dlc_campaign_registration_details.rb', line 321 def valid? warn '[DEPRECATED] the `valid?` method is obsolete' return false if @account_id.nil? return false if @campaign_status.nil? campaign_status_validator = EnumAttributeValidator.new('String', ["not_started", "in_progress", "pending_review", "approved", "rejected", "info_needed"]) return false unless campaign_status_validator.valid?(@campaign_status) return false if @created_at.nil? return false if @updated_at.nil? true end |