rcs 1.0.17 → 2.0.0.pre.rc.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.
- checksums.yaml +4 -4
- data/lib/environment.rb +1 -1
- data/lib/rcs/brands/client.rb +631 -0
- data/lib/rcs/brands/types/autofill_brand_schema_options.rb +61 -0
- data/lib/rcs/brands/types/brand_contact.rb +84 -0
- data/lib/rcs/campaigns/client.rb +44 -0
- data/lib/rcs/campaigns/dlc/client.rb +480 -0
- data/lib/rcs/campaigns/dlc/types/upsert_dlc_schema_keywords.rb +99 -0
- data/lib/rcs/campaigns/dlc/types/upsert_dlc_schema_keywords_help.rb +74 -0
- data/lib/rcs/campaigns/dlc/types/upsert_dlc_schema_keywords_opt_in.rb +74 -0
- data/lib/rcs/campaigns/dlc/types/upsert_dlc_schema_keywords_opt_out.rb +74 -0
- data/lib/rcs/campaigns/dlc/types/upsert_dlc_schema_links.rb +74 -0
- data/lib/rcs/campaigns/dlc/types/upsert_dlc_schema_options.rb +110 -0
- data/lib/rcs/campaigns/dlc/types/upsert_dlc_schema_use_case.rb +76 -0
- data/lib/rcs/campaigns/rcs/client.rb +457 -0
- data/lib/rcs/campaigns/rcs/types/rcs_autofill_response.rb +155 -0
- data/lib/rcs/campaigns/rcs/types/upsert_rcs_schema_agent.rb +140 -0
- data/lib/rcs/campaigns/rcs/types/upsert_rcs_schema_agent_emails_item.rb +73 -0
- data/lib/rcs/campaigns/rcs/types/upsert_rcs_schema_agent_phones_item.rb +73 -0
- data/lib/rcs/campaigns/rcs/types/upsert_rcs_schema_agent_websites_item.rb +73 -0
- data/lib/rcs/campaigns/rcs/types/upsert_rcs_schema_links.rb +74 -0
- data/lib/rcs/campaigns/rcs/types/upsert_rcs_schema_opt_in.rb +75 -0
- data/lib/rcs/campaigns/rcs/types/upsert_rcs_schema_opt_out.rb +76 -0
- data/lib/rcs/campaigns/rcs/types/upsert_rcs_schema_use_case.rb +75 -0
- data/lib/rcs/campaigns/toll_free/client.rb +429 -0
- data/lib/rcs/campaigns/toll_free/types/toll_free_autofill_response.rb +130 -0
- data/lib/rcs/campaigns/toll_free/types/upsert_toll_free_schema_opt_in.rb +86 -0
- data/lib/rcs/campaigns/toll_free/types/upsert_toll_free_schema_use_case.rb +75 -0
- data/lib/rcs/contacts/client.rb +275 -0
- data/lib/rcs/conversations/client.rb +273 -0
- data/lib/rcs/message/client.rb +30 -0
- data/lib/rcs/message/sms/client.rb +96 -0
- data/lib/rcs/messages/client.rb +185 -0
- data/lib/rcs/messages/mms/client.rb +98 -0
- data/lib/rcs/messages/rcs/client.rb +94 -0
- data/lib/rcs/messages/send/client.rb +318 -0
- data/lib/rcs/messages/send/types/send_mms_response.rb +60 -0
- data/lib/rcs/messages/send/types/send_mms_schema_options.rb +108 -0
- data/lib/rcs/messages/send/types/send_rcs_response.rb +60 -0
- data/lib/rcs/messages/send/types/send_sms_response.rb +60 -0
- data/lib/rcs/messages/send/types/send_sms_schema_options.rb +81 -0
- data/lib/rcs/messages/types/message_reaction_schema_options.rb +71 -0
- data/lib/rcs/phone_numbers/campaign/client.rb +179 -0
- data/lib/rcs/phone_numbers/client.rb +345 -0
- data/lib/rcs/phone_numbers/types/phone_details_schema_level.rb +16 -0
- data/lib/rcs/phone_numbers/types/phone_details_schema_options.rb +93 -0
- data/lib/rcs/phone_numbers/types/phone_details_schema_options_enhanced_contact_info.rb +64 -0
- data/lib/rcs/phone_numbers/types/phone_numbers_get_response.rb +58 -0
- data/lib/rcs/phone_numbers/types/search_schema_location.rb +96 -0
- data/lib/rcs/phone_numbers/types/search_schema_number.rb +81 -0
- data/lib/rcs/phone_numbers/types/search_schema_options.rb +62 -0
- data/lib/rcs/phone_numbers/webhook/client.rb +191 -0
- data/lib/rcs/status/client.rb +30 -0
- data/lib/rcs/status/get/client.rb +367 -0
- data/lib/rcs/tools/client.rb +32 -199
- data/lib/rcs/tools/contact_card/client.rb +285 -0
- data/lib/rcs/tools/contact_card/types/get_v_card_schema_options.rb +67 -0
- data/lib/rcs/tools/file/client.rb +138 -0
- data/lib/rcs/tools/file/types/file_upload_schema_options.rb +70 -0
- data/lib/rcs/tools/file/types/file_upload_schema_options_download.rb +66 -0
- data/lib/rcs/tools/url/client.rb +245 -0
- data/lib/rcs/types/advanced_phone_information.rb +147 -0
- data/lib/rcs/types/advanced_phone_information_carrier.rb +90 -0
- data/lib/rcs/types/advanced_phone_information_contact.rb +146 -0
- data/lib/rcs/types/advanced_phone_information_location.rb +142 -0
- data/lib/rcs/types/advanced_phone_information_location_coordinates.rb +73 -0
- data/lib/rcs/types/advanced_phone_information_location_country.rb +77 -0
- data/lib/rcs/types/advanced_phone_information_type.rb +97 -0
- data/lib/rcs/types/advanced_phone_information_type_recommendation.rb +15 -0
- data/lib/rcs/types/agent.rb +68 -0
- data/lib/rcs/types/attach_webhook_params.rb +60 -0
- data/lib/rcs/types/attach_webhook_response_webhook.rb +86 -0
- data/lib/rcs/types/attach_webhook_schema_name.rb +88 -0
- data/lib/rcs/types/attach_webhook_schema_webhook_id.rb +77 -0
- data/lib/rcs/types/attached_phone_number_result.rb +75 -0
- data/lib/rcs/types/autofill_campaign_params.rb +69 -0
- data/lib/rcs/types/autofill_dlc_campaign_response.rb +169 -0
- data/lib/rcs/types/autofill_dlc_response_keywords.rb +95 -0
- data/lib/rcs/types/autofill_dlc_response_keywords_help.rb +70 -0
- data/lib/rcs/{send/types/send_sms_response.rb → types/autofill_dlc_response_keywords_opt_in.rb} +18 -17
- data/lib/rcs/types/autofill_dlc_response_keywords_opt_out.rb +70 -0
- data/lib/rcs/types/autofill_dlc_response_links.rb +70 -0
- data/lib/rcs/types/autofill_dlc_response_options.rb +106 -0
- data/lib/rcs/types/autofill_dlc_response_use_case.rb +72 -0
- data/lib/rcs/types/bad_request_error_body.rb +44 -45
- data/lib/rcs/types/basic_phone_information.rb +127 -0
- data/lib/rcs/{company/types/company_register_response_brand.rb → types/basic_phone_information_contact.rb} +12 -21
- data/lib/rcs/types/basic_phone_information_location.rb +74 -0
- data/lib/rcs/types/basic_phone_information_location_country.rb +75 -0
- data/lib/rcs/types/brand_status.rb +92 -0
- data/lib/rcs/types/brand_status_enum.rb +21 -0
- data/lib/rcs/types/buy_response_capabilities.rb +77 -0
- data/lib/rcs/types/campaign_enum.rb +15 -0
- data/lib/rcs/types/campaign_query.rb +69 -0
- data/lib/rcs/{company/types/company_register_request_company_id.rb → types/campaign_submission_result.rb} +15 -16
- data/lib/rcs/types/campaign_validation_response_errors_item.rb +76 -0
- data/lib/rcs/types/campaign_validation_result.rb +71 -0
- data/lib/rcs/types/click_action.rb +73 -0
- data/lib/rcs/types/click_action_data.rb +56 -0
- data/lib/rcs/types/click_action_data_metadata.rb +69 -0
- data/lib/rcs/types/company_sector_enum.rb +26 -0
- data/lib/rcs/types/company_type_enum.rb +14 -0
- data/lib/rcs/types/configured_webhook.rb +85 -0
- data/lib/rcs/types/contact.rb +105 -0
- data/lib/rcs/types/contact_id.rb +57 -0
- data/lib/rcs/types/conversation.rb +146 -0
- data/lib/rcs/types/conversation_contact.rb +68 -0
- data/lib/rcs/types/conversation_list.rb +79 -0
- data/lib/rcs/types/conversation_sender.rb +60 -0
- data/lib/rcs/types/create_url_options.rb +61 -0
- data/lib/rcs/types/detached_phone_number_result.rb +75 -0
- data/lib/rcs/types/detached_webhook_info.rb +74 -0
- data/lib/rcs/types/detailed_phone_number_enum.rb +25 -0
- data/lib/rcs/types/dlc_assignment_status_enum.rb +19 -0
- data/lib/rcs/types/dlc_campaign_status.rb +107 -0
- data/lib/rcs/types/dlc_campaign_use_case_enum.rb +35 -0
- data/lib/rcs/types/dlc_campaign_with_extended_brand_and_status.rb +194 -0
- data/lib/rcs/types/dlc_with_extended_brand_and_status_keywords.rb +94 -0
- data/lib/rcs/types/dlc_with_extended_brand_and_status_keywords_help.rb +72 -0
- data/lib/rcs/{send/types/send_mms_response.rb → types/dlc_with_extended_brand_and_status_keywords_opt_in.rb} +20 -17
- data/lib/rcs/{send/types/send_rcs_response.rb → types/dlc_with_extended_brand_and_status_keywords_opt_out.rb} +20 -17
- data/lib/rcs/types/dlc_with_extended_brand_and_status_links.rb +70 -0
- data/lib/rcs/types/dlc_with_extended_brand_and_status_options.rb +106 -0
- data/lib/rcs/types/dlc_with_extended_brand_and_status_use_case.rb +72 -0
- data/lib/rcs/types/enhanced_contact.rb +9 -0
- data/lib/rcs/types/enhanced_contact_item.rb +104 -0
- data/lib/rcs/types/error.rb +61 -0
- data/lib/rcs/types/extended_brand.rb +194 -0
- data/lib/rcs/types/extended_brand_with_vetting.rb +226 -0
- data/lib/rcs/types/extended_rcs_campaign.rb +173 -0
- data/lib/rcs/{company/types/company_register_request.rb → types/get_conversation_params.rb} +13 -12
- data/lib/rcs/types/get_conversation_request_id.rb +58 -0
- data/lib/rcs/types/get_conversation_request_recipient.rb +72 -0
- data/lib/rcs/types/get_dlc_campaign_status_response_updates.rb +96 -0
- data/lib/rcs/types/get_toll_free_campaign_status_response_updates.rb +92 -0
- data/lib/rcs/types/inbound_button.rb +56 -0
- data/lib/rcs/types/link_click_event.rb +465 -0
- data/lib/rcs/{company/types/company_update_response.rb → types/location_share_action.rb} +19 -19
- data/lib/rcs/types/location_share_action_data.rb +89 -0
- data/lib/rcs/types/message.rb +174 -0
- data/lib/rcs/types/message_content.rb +85 -0
- data/lib/rcs/types/message_method_enum.rb +12 -0
- data/lib/rcs/types/message_protocol_enum.rb +12 -0
- data/lib/rcs/types/message_schedule.rb +94 -0
- data/lib/rcs/types/message_status_enum.rb +16 -0
- data/lib/rcs/types/message_volume_enum.rb +20 -0
- data/lib/rcs/types/messaging_profile_enum.rb +11 -0
- data/lib/rcs/types/mms_content.rb +74 -0
- data/lib/rcs/types/mms_validation_response_segments.rb +85 -0
- data/lib/rcs/types/mms_validation_response_segments_value_item.rb +75 -0
- data/lib/rcs/types/mms_validation_result.rb +82 -0
- data/lib/rcs/types/nullable_contact.rb +84 -0
- data/lib/rcs/types/number_format.rb +79 -0
- data/lib/rcs/types/opt_in_method_enum.rb +13 -0
- data/lib/rcs/types/optional_brand_info.rb +145 -0
- data/lib/rcs/types/optional_contact.rb +83 -0
- data/lib/rcs/types/optional_contacts.rb +84 -0
- data/lib/rcs/types/phone.rb +101 -0
- data/lib/rcs/types/phone_capabilities.rb +75 -0
- data/lib/rcs/types/phone_enum.rb +13 -0
- data/lib/rcs/types/phone_feature_enum.rb +18 -0
- data/lib/rcs/types/phone_number_campaign_attach_failed_item.rb +67 -0
- data/lib/rcs/types/phone_number_campaign_attach_phone_numbers_item.rb +75 -0
- data/lib/rcs/types/phone_number_campaign_attach_phone_numbers_item_campaign.rb +78 -0
- data/lib/rcs/types/phone_number_campaign_detach_failed_item.rb +67 -0
- data/lib/rcs/types/phone_number_campaign_detach_phone_numbers_item.rb +75 -0
- data/lib/rcs/types/phone_number_campaign_detach_phone_numbers_item_campaign.rb +78 -0
- data/lib/rcs/types/phone_number_cost.rb +75 -0
- data/lib/rcs/types/phone_number_details.rb +110 -0
- data/lib/rcs/types/phone_number_enum.rb +18 -0
- data/lib/rcs/types/phone_number_region.rb +91 -0
- data/lib/rcs/types/phone_number_status.rb +90 -0
- data/lib/rcs/types/phone_number_status_enum.rb +16 -0
- data/lib/rcs/types/pinnacle_file_upload_metadata.rb +84 -0
- data/lib/rcs/types/pinnacle_url_config.rb +71 -0
- data/lib/rcs/types/profile_status_enum.rb +17 -0
- data/lib/rcs/types/purchased_number.rb +75 -0
- data/lib/rcs/types/rcs.rb +70 -0
- data/lib/rcs/types/rcs_base.rb +82 -0
- data/lib/rcs/types/rcs_base_options.rb +100 -0
- data/lib/rcs/types/rcs_button_call.rb +68 -0
- data/lib/rcs/types/rcs_button_content.rb +148 -0
- data/lib/rcs/types/rcs_button_open_url.rb +68 -0
- data/lib/rcs/types/rcs_button_request_user_location.rb +58 -0
- data/lib/rcs/types/rcs_button_schedule_event.rb +98 -0
- data/lib/rcs/types/rcs_button_send_location.rb +74 -0
- data/lib/rcs/types/rcs_button_send_location_lat_long.rb +68 -0
- data/lib/rcs/types/rcs_button_trigger.rb +78 -0
- data/lib/rcs/types/rcs_campaign.rb +143 -0
- data/lib/rcs/types/rcs_campaign_opt_in_method_enum.rb +15 -0
- data/lib/rcs/types/rcs_campaign_schema_agent.rb +134 -0
- data/lib/rcs/types/rcs_campaign_schema_agent_emails_item.rb +69 -0
- data/lib/rcs/types/rcs_campaign_schema_agent_phones_item.rb +69 -0
- data/lib/rcs/types/rcs_campaign_schema_agent_websites_item.rb +69 -0
- data/lib/rcs/types/rcs_campaign_schema_extra_agent.rb +134 -0
- data/lib/rcs/types/rcs_campaign_schema_extra_agent_emails_item.rb +70 -0
- data/lib/rcs/types/rcs_campaign_schema_extra_agent_phones_item.rb +70 -0
- data/lib/rcs/types/rcs_campaign_schema_extra_agent_websites_item.rb +71 -0
- data/lib/rcs/types/rcs_campaign_schema_extra_links.rb +70 -0
- data/lib/rcs/types/rcs_campaign_schema_extra_opt_in.rb +71 -0
- data/lib/rcs/types/rcs_campaign_schema_extra_opt_out.rb +70 -0
- data/lib/rcs/types/rcs_campaign_schema_extra_use_case.rb +71 -0
- data/lib/rcs/types/rcs_campaign_schema_links.rb +70 -0
- data/lib/rcs/types/rcs_campaign_schema_opt_in.rb +71 -0
- data/lib/rcs/types/rcs_campaign_schema_opt_out.rb +70 -0
- data/lib/rcs/types/rcs_campaign_schema_use_case.rb +71 -0
- data/lib/rcs/types/rcs_campaign_status.rb +86 -0
- data/lib/rcs/types/rcs_campaign_use_case_enum.rb +23 -0
- data/lib/rcs/types/rcs_card.rb +110 -0
- data/lib/rcs/types/rcs_cards.rb +79 -0
- data/lib/rcs/types/rcs_cards_cards_item.rb +88 -0
- data/lib/rcs/types/rcs_cards_content.rb +79 -0
- data/lib/rcs/types/rcs_cards_content_cards_item.rb +94 -0
- data/lib/rcs/types/rcs_content.rb +72 -0
- data/lib/rcs/types/rcs_media.rb +110 -0
- data/lib/rcs/types/rcs_media_content.rb +81 -0
- data/lib/rcs/types/rcs_media_details_content.rb +77 -0
- data/lib/rcs/types/rcs_text.rb +106 -0
- data/lib/rcs/types/rcs_text_content.rb +72 -0
- data/lib/rcs/types/rcs_validate_content.rb +70 -0
- data/lib/rcs/{company/types/company_register_response.rb → types/rcs_validate_content_media.rb} +19 -21
- data/lib/rcs/types/rcs_validation_result.rb +76 -0
- data/lib/rcs/types/reaction_result.rb +67 -0
- data/lib/rcs/types/scheduled_messaage.rb +73 -0
- data/lib/rcs/types/scheduled_send_response_config.rb +89 -0
- data/lib/rcs/types/send_sms_response_segments.rb +69 -0
- data/lib/rcs/types/send_sms_response_segments_encoding.rb +11 -0
- data/lib/rcs/types/sent_mms_details.rb +102 -0
- data/lib/rcs/types/sent_rcs_details.rb +105 -0
- data/lib/rcs/types/sent_sms_details.rb +108 -0
- data/lib/rcs/types/shortened_url.rb +77 -0
- data/lib/rcs/types/shortened_url_with_click_data.rb +90 -0
- data/lib/rcs/types/sms_content.rb +58 -0
- data/lib/rcs/types/sms_validation_response_segments.rb +80 -0
- data/lib/rcs/types/sms_validation_response_segments_gsm_7.rb +75 -0
- data/lib/rcs/types/sms_validation_response_segments_utf_16.rb +68 -0
- data/lib/rcs/types/sms_validation_response_total.rb +75 -0
- data/lib/rcs/types/sms_validation_result.rb +102 -0
- data/lib/rcs/types/sub_use_case_enum.rb +19 -0
- data/lib/rcs/types/submission_results.rb +57 -0
- data/lib/rcs/types/successful_conversation_update.rb +58 -0
- data/lib/rcs/types/toll_free_campaign.rb +118 -0
- data/lib/rcs/types/toll_free_campaign_schema_opt_in.rb +78 -0
- data/lib/rcs/types/toll_free_campaign_schema_use_case.rb +71 -0
- data/lib/rcs/types/toll_free_campaign_status.rb +91 -0
- data/lib/rcs/types/toll_free_campaign_use_case_enum.rb +52 -0
- data/lib/rcs/types/toll_free_campaign_with_extended_brand_and_status.rb +155 -0
- data/lib/rcs/types/toll_free_status_enum.rb +20 -0
- data/lib/rcs/types/tracking.rb +17 -0
- data/lib/rcs/types/updated_contact_id.rb +57 -0
- data/lib/rcs/types/upload_results.rb +80 -0
- data/lib/rcs/types/v_card_address_schema_type_item.rb +15 -0
- data/lib/rcs/types/v_card_data.rb +237 -0
- data/lib/rcs/types/v_card_data_file.rb +74 -0
- data/lib/rcs/types/v_card_data_file_metadata.rb +62 -0
- data/lib/rcs/types/v_card_email_schema_type_item.rb +21 -0
- data/lib/rcs/types/v_card_geo.rb +70 -0
- data/lib/rcs/types/v_card_name.rb +98 -0
- data/lib/rcs/types/v_card_organization.rb +70 -0
- data/lib/rcs/types/v_card_phone_schema_type_item.rb +21 -0
- data/lib/rcs/types/validate_campaign_params.rb +69 -0
- data/lib/rcs/types/validation_error_details.rb +76 -0
- data/lib/rcs/types/validation_results.rb +71 -0
- data/lib/rcs/types/vcard.rb +215 -0
- data/lib/rcs/types/vcard_address.rb +130 -0
- data/lib/rcs/types/vcard_content.rb +223 -0
- data/lib/rcs/types/vcard_email.rb +70 -0
- data/lib/rcs/types/vcard_phone.rb +70 -0
- data/lib/rcs/types/vcard_resource.rb +71 -0
- data/lib/rcs/types/vetting_feedback.rb +81 -0
- data/lib/rcs/types/vetting_history.rb +98 -0
- data/lib/rcs/types/vetting_history_vetting_status.rb +13 -0
- data/lib/rcs/types/vetting_results.rb +57 -0
- data/lib/rcs/types/webhook_event_enum.rb +13 -0
- data/lib/rcs/types/webhook_result.rb +64 -0
- data/lib/rcs/{company/types/company_update_response_brand.rb → types/webhooks.rb} +25 -17
- data/lib/rcs/types/zod_error.rb +73 -0
- data/lib/rcs/webhooks/client.rb +93 -0
- data/lib/rcs.rb +67 -83
- data/lib/requests.rb +4 -4
- data/lib/types_export.rb +252 -46
- metadata +278 -52
- data/lib/rcs/company/client.rb +0 -375
- data/lib/rcs/company/types/company_register_request_company.rb +0 -128
- data/lib/rcs/send/client.rb +0 -382
- data/lib/rcs/send/types/rcs_fallback.rb +0 -84
- data/lib/rcs/tools/types/tools_shorten_url_response.rb +0 -70
- data/lib/rcs/tools/types/tools_upload_url_response.rb +0 -69
- data/lib/rcs/types/action.rb +0 -154
- data/lib/rcs/types/action_lat_long.rb +0 -68
- data/lib/rcs/types/action_type.rb +0 -16
- data/lib/rcs/types/additional_email.rb +0 -65
- data/lib/rcs/types/additional_phone_number.rb +0 -65
- data/lib/rcs/types/additional_website.rb +0 -65
- data/lib/rcs/types/card.rb +0 -90
- data/lib/rcs/types/company.rb +0 -319
- data/lib/rcs/types/company_additional_emails_item.rb +0 -67
- data/lib/rcs/types/company_additional_phone_numbers_item.rb +0 -67
- data/lib/rcs/types/company_additional_websites_item.rb +0 -67
- data/lib/rcs/types/company_category.rb +0 -20
- data/lib/rcs/types/company_contact.rb +0 -117
- data/lib/rcs/types/company_details.rb +0 -120
- data/lib/rcs/types/forbidden_error_body.rb +0 -57
- data/lib/rcs/types/inbound_action_message.rb +0 -117
- data/lib/rcs/types/inbound_location_message.rb +0 -106
- data/lib/rcs/types/inbound_location_message_coordinates.rb +0 -65
- data/lib/rcs/types/inbound_media_message.rb +0 -112
- data/lib/rcs/types/inbound_message.rb +0 -88
- data/lib/rcs/types/inbound_message_message_type.rb +0 -10
- data/lib/rcs/types/inbound_message_metadata.rb +0 -79
- data/lib/rcs/types/inbound_text_message.rb +0 -100
- data/lib/rcs/types/internal_server_error_body.rb +0 -57
- data/lib/rcs/types/media_payload.rb +0 -65
- data/lib/rcs/types/message_metadata.rb +0 -56
- data/lib/rcs/types/messaging.rb +0 -95
- data/lib/rcs/types/optionals.rb +0 -99
- data/lib/rcs/types/payment_required_error_body.rb +0 -57
- data/lib/rcs/types/point_of_contact.rb +0 -72
- data/lib/rcs/types/rcs_functionalities.rb +0 -117
- data/lib/rcs/types/sender_metadata.rb +0 -74
- data/lib/rcs/types/unauthorized_error_body.rb +0 -57
@@ -0,0 +1,78 @@
|
|
1
|
+
# frozen_string_literal: true
|
2
|
+
|
3
|
+
require_relative "opt_in_method_enum"
|
4
|
+
require "ostruct"
|
5
|
+
require "json"
|
6
|
+
|
7
|
+
module Pinnacle
|
8
|
+
module Types
|
9
|
+
# Opt-in keyword settings.
|
10
|
+
class TollFreeCampaignSchemaOptIn
|
11
|
+
# @return [Pinnacle::Types::OptInMethodEnum]
|
12
|
+
attr_reader :method
|
13
|
+
# @return [String] Url to opt in.
|
14
|
+
attr_reader :url
|
15
|
+
# @return [String] Explain how users find the opt-in.
|
16
|
+
attr_reader :workflow_description
|
17
|
+
# @return [OpenStruct] Additional properties unmapped to the current class definition
|
18
|
+
attr_reader :additional_properties
|
19
|
+
# @return [Object]
|
20
|
+
attr_reader :_field_set
|
21
|
+
protected :_field_set
|
22
|
+
|
23
|
+
OMIT = Object.new
|
24
|
+
|
25
|
+
# @param method [Pinnacle::Types::OptInMethodEnum]
|
26
|
+
# @param url [String] Url to opt in.
|
27
|
+
# @param workflow_description [String] Explain how users find the opt-in.
|
28
|
+
# @param additional_properties [OpenStruct] Additional properties unmapped to the current class definition
|
29
|
+
# @return [Pinnacle::Types::TollFreeCampaignSchemaOptIn]
|
30
|
+
def initialize(method: OMIT, url: OMIT, workflow_description: OMIT, additional_properties: nil)
|
31
|
+
@method = method if method != OMIT
|
32
|
+
@url = url if url != OMIT
|
33
|
+
@workflow_description = workflow_description if workflow_description != OMIT
|
34
|
+
@additional_properties = additional_properties
|
35
|
+
@_field_set = { "method": method, "url": url, "workflowDescription": workflow_description }.reject do |_k, v|
|
36
|
+
v == OMIT
|
37
|
+
end
|
38
|
+
end
|
39
|
+
|
40
|
+
# Deserialize a JSON object to an instance of TollFreeCampaignSchemaOptIn
|
41
|
+
#
|
42
|
+
# @param json_object [String]
|
43
|
+
# @return [Pinnacle::Types::TollFreeCampaignSchemaOptIn]
|
44
|
+
def self.from_json(json_object:)
|
45
|
+
struct = JSON.parse(json_object, object_class: OpenStruct)
|
46
|
+
parsed_json = JSON.parse(json_object)
|
47
|
+
method = parsed_json["method"]
|
48
|
+
url = parsed_json["url"]
|
49
|
+
workflow_description = parsed_json["workflowDescription"]
|
50
|
+
new(
|
51
|
+
method: method,
|
52
|
+
url: url,
|
53
|
+
workflow_description: workflow_description,
|
54
|
+
additional_properties: struct
|
55
|
+
)
|
56
|
+
end
|
57
|
+
|
58
|
+
# Serialize an instance of TollFreeCampaignSchemaOptIn to a JSON object
|
59
|
+
#
|
60
|
+
# @return [String]
|
61
|
+
def to_json(*_args)
|
62
|
+
@_field_set&.to_json
|
63
|
+
end
|
64
|
+
|
65
|
+
# Leveraged for Union-type generation, validate_raw attempts to parse the given
|
66
|
+
# hash and check each fields type against the current object's property
|
67
|
+
# definitions.
|
68
|
+
#
|
69
|
+
# @param obj [Object]
|
70
|
+
# @return [Void]
|
71
|
+
def self.validate_raw(obj:)
|
72
|
+
obj.method&.is_a?(Pinnacle::Types::OptInMethodEnum) != false || raise("Passed value for field obj.method is not the expected type, validation failed.")
|
73
|
+
obj.url&.is_a?(String) != false || raise("Passed value for field obj.url is not the expected type, validation failed.")
|
74
|
+
obj.workflow_description&.is_a?(String) != false || raise("Passed value for field obj.workflow_description is not the expected type, validation failed.")
|
75
|
+
end
|
76
|
+
end
|
77
|
+
end
|
78
|
+
end
|
@@ -0,0 +1,71 @@
|
|
1
|
+
# frozen_string_literal: true
|
2
|
+
|
3
|
+
require_relative "toll_free_campaign_use_case_enum"
|
4
|
+
require "ostruct"
|
5
|
+
require "json"
|
6
|
+
|
7
|
+
module Pinnacle
|
8
|
+
module Types
|
9
|
+
# Use case classification for the campaign.
|
10
|
+
class TollFreeCampaignSchemaUseCase
|
11
|
+
# @return [String] Summary of the use case.
|
12
|
+
attr_reader :summary
|
13
|
+
# @return [Pinnacle::Types::TollFreeCampaignUseCaseEnum]
|
14
|
+
attr_reader :value
|
15
|
+
# @return [OpenStruct] Additional properties unmapped to the current class definition
|
16
|
+
attr_reader :additional_properties
|
17
|
+
# @return [Object]
|
18
|
+
attr_reader :_field_set
|
19
|
+
protected :_field_set
|
20
|
+
|
21
|
+
OMIT = Object.new
|
22
|
+
|
23
|
+
# @param summary [String] Summary of the use case.
|
24
|
+
# @param value [Pinnacle::Types::TollFreeCampaignUseCaseEnum]
|
25
|
+
# @param additional_properties [OpenStruct] Additional properties unmapped to the current class definition
|
26
|
+
# @return [Pinnacle::Types::TollFreeCampaignSchemaUseCase]
|
27
|
+
def initialize(summary: OMIT, value: OMIT, additional_properties: nil)
|
28
|
+
@summary = summary if summary != OMIT
|
29
|
+
@value = value if value != OMIT
|
30
|
+
@additional_properties = additional_properties
|
31
|
+
@_field_set = { "summary": summary, "value": value }.reject do |_k, v|
|
32
|
+
v == OMIT
|
33
|
+
end
|
34
|
+
end
|
35
|
+
|
36
|
+
# Deserialize a JSON object to an instance of TollFreeCampaignSchemaUseCase
|
37
|
+
#
|
38
|
+
# @param json_object [String]
|
39
|
+
# @return [Pinnacle::Types::TollFreeCampaignSchemaUseCase]
|
40
|
+
def self.from_json(json_object:)
|
41
|
+
struct = JSON.parse(json_object, object_class: OpenStruct)
|
42
|
+
parsed_json = JSON.parse(json_object)
|
43
|
+
summary = parsed_json["summary"]
|
44
|
+
value = parsed_json["value"]
|
45
|
+
new(
|
46
|
+
summary: summary,
|
47
|
+
value: value,
|
48
|
+
additional_properties: struct
|
49
|
+
)
|
50
|
+
end
|
51
|
+
|
52
|
+
# Serialize an instance of TollFreeCampaignSchemaUseCase to a JSON object
|
53
|
+
#
|
54
|
+
# @return [String]
|
55
|
+
def to_json(*_args)
|
56
|
+
@_field_set&.to_json
|
57
|
+
end
|
58
|
+
|
59
|
+
# Leveraged for Union-type generation, validate_raw attempts to parse the given
|
60
|
+
# hash and check each fields type against the current object's property
|
61
|
+
# definitions.
|
62
|
+
#
|
63
|
+
# @param obj [Object]
|
64
|
+
# @return [Void]
|
65
|
+
def self.validate_raw(obj:)
|
66
|
+
obj.summary&.is_a?(String) != false || raise("Passed value for field obj.summary is not the expected type, validation failed.")
|
67
|
+
obj.value&.is_a?(Pinnacle::Types::TollFreeCampaignUseCaseEnum) != false || raise("Passed value for field obj.value is not the expected type, validation failed.")
|
68
|
+
end
|
69
|
+
end
|
70
|
+
end
|
71
|
+
end
|
@@ -0,0 +1,91 @@
|
|
1
|
+
# frozen_string_literal: true
|
2
|
+
|
3
|
+
require_relative "get_toll_free_campaign_status_response_updates"
|
4
|
+
require "ostruct"
|
5
|
+
require "json"
|
6
|
+
|
7
|
+
module Pinnacle
|
8
|
+
module Types
|
9
|
+
# Response for get toll-free campaign status.
|
10
|
+
class TollFreeCampaignStatus
|
11
|
+
# @return [String] Summary of errors related to the verification process. <br>
|
12
|
+
# These errors may request additional information or point out erroneous and/or
|
13
|
+
# missing fields.
|
14
|
+
attr_reader :error
|
15
|
+
# @return [Integer] Id of the toll-free campaign.
|
16
|
+
attr_reader :id
|
17
|
+
# @return [Pinnacle::Types::GetTollFreeCampaignStatusResponseUpdates] Status of phone numbers that are being attached to this campaign. <br>
|
18
|
+
# Note that phone numbers can only be attached to `VERIFIED` campaigns via the
|
19
|
+
# [attach campaign endpoint](../phone-numbers/attach-campaign).
|
20
|
+
attr_reader :updates
|
21
|
+
# @return [OpenStruct] Additional properties unmapped to the current class definition
|
22
|
+
attr_reader :additional_properties
|
23
|
+
# @return [Object]
|
24
|
+
attr_reader :_field_set
|
25
|
+
protected :_field_set
|
26
|
+
|
27
|
+
OMIT = Object.new
|
28
|
+
|
29
|
+
# @param error [String] Summary of errors related to the verification process. <br>
|
30
|
+
# These errors may request additional information or point out erroneous and/or
|
31
|
+
# missing fields.
|
32
|
+
# @param id [Integer] Id of the toll-free campaign.
|
33
|
+
# @param updates [Pinnacle::Types::GetTollFreeCampaignStatusResponseUpdates] Status of phone numbers that are being attached to this campaign. <br>
|
34
|
+
# Note that phone numbers can only be attached to `VERIFIED` campaigns via the
|
35
|
+
# [attach campaign endpoint](../phone-numbers/attach-campaign).
|
36
|
+
# @param additional_properties [OpenStruct] Additional properties unmapped to the current class definition
|
37
|
+
# @return [Pinnacle::Types::TollFreeCampaignStatus]
|
38
|
+
def initialize(id:, updates:, error: OMIT, additional_properties: nil)
|
39
|
+
@error = error if error != OMIT
|
40
|
+
@id = id
|
41
|
+
@updates = updates
|
42
|
+
@additional_properties = additional_properties
|
43
|
+
@_field_set = { "error": error, "id": id, "updates": updates }.reject do |_k, v|
|
44
|
+
v == OMIT
|
45
|
+
end
|
46
|
+
end
|
47
|
+
|
48
|
+
# Deserialize a JSON object to an instance of TollFreeCampaignStatus
|
49
|
+
#
|
50
|
+
# @param json_object [String]
|
51
|
+
# @return [Pinnacle::Types::TollFreeCampaignStatus]
|
52
|
+
def self.from_json(json_object:)
|
53
|
+
struct = JSON.parse(json_object, object_class: OpenStruct)
|
54
|
+
parsed_json = JSON.parse(json_object)
|
55
|
+
error = parsed_json["error"]
|
56
|
+
id = parsed_json["id"]
|
57
|
+
if parsed_json["updates"].nil?
|
58
|
+
updates = nil
|
59
|
+
else
|
60
|
+
updates = parsed_json["updates"].to_json
|
61
|
+
updates = Pinnacle::Types::GetTollFreeCampaignStatusResponseUpdates.from_json(json_object: updates)
|
62
|
+
end
|
63
|
+
new(
|
64
|
+
error: error,
|
65
|
+
id: id,
|
66
|
+
updates: updates,
|
67
|
+
additional_properties: struct
|
68
|
+
)
|
69
|
+
end
|
70
|
+
|
71
|
+
# Serialize an instance of TollFreeCampaignStatus to a JSON object
|
72
|
+
#
|
73
|
+
# @return [String]
|
74
|
+
def to_json(*_args)
|
75
|
+
@_field_set&.to_json
|
76
|
+
end
|
77
|
+
|
78
|
+
# Leveraged for Union-type generation, validate_raw attempts to parse the given
|
79
|
+
# hash and check each fields type against the current object's property
|
80
|
+
# definitions.
|
81
|
+
#
|
82
|
+
# @param obj [Object]
|
83
|
+
# @return [Void]
|
84
|
+
def self.validate_raw(obj:)
|
85
|
+
obj.error&.is_a?(String) != false || raise("Passed value for field obj.error is not the expected type, validation failed.")
|
86
|
+
obj.id.is_a?(Integer) != false || raise("Passed value for field obj.id is not the expected type, validation failed.")
|
87
|
+
Pinnacle::Types::GetTollFreeCampaignStatusResponseUpdates.validate_raw(obj: obj.updates)
|
88
|
+
end
|
89
|
+
end
|
90
|
+
end
|
91
|
+
end
|
@@ -0,0 +1,52 @@
|
|
1
|
+
# frozen_string_literal: true
|
2
|
+
|
3
|
+
module Pinnacle
|
4
|
+
module Types
|
5
|
+
# The primary use case classification for this campaign.
|
6
|
+
class TollFreeCampaignUseCaseEnum
|
7
|
+
APP_NOTIFICATIONS = "APP_NOTIFICATIONS"
|
8
|
+
APPOINTMENTS = "APPOINTMENTS"
|
9
|
+
AUCTIONS = "AUCTIONS"
|
10
|
+
AUTO_REPAIR_SERVICES = "AUTO_REPAIR_SERVICES"
|
11
|
+
BANK_TRANSFERS = "BANK_TRANSFERS"
|
12
|
+
BILLING = "BILLING"
|
13
|
+
BOOKING_CONFIRMATIONS = "BOOKING_CONFIRMATIONS"
|
14
|
+
BUSINESS_UPDATES = "BUSINESS_UPDATES"
|
15
|
+
CAREER_TRAINING = "CAREER_TRAINING"
|
16
|
+
CHATBOT = "CHATBOT"
|
17
|
+
CONVERSATIONAL_ALERTS = "CONVERSATIONAL_ALERTS"
|
18
|
+
COURIER_SERVICES_DELIVERIES = "COURIER_SERVICES_DELIVERIES"
|
19
|
+
COVID_19_ALERTS = "COVID_19_ALERTS"
|
20
|
+
EMERGENCY_ALERTS = "EMERGENCY_ALERTS"
|
21
|
+
EVENTS_PLANNING = "EVENTS_PLANNING"
|
22
|
+
FINANCIAL_SERVICES = "FINANCIAL_SERVICES"
|
23
|
+
FRAUD_ALERTS = "FRAUD_ALERTS"
|
24
|
+
FUNDRAISING = "FUNDRAISING"
|
25
|
+
GENERAL_MARKETING = "GENERAL_MARKETING"
|
26
|
+
GENERAL_SCHOOL_UPDATES = "GENERAL_SCHOOL_UPDATES"
|
27
|
+
HEALTHCARE_ALERTS = "HEALTHCARE_ALERTS"
|
28
|
+
HOUSING_COMMUNITY_UPDATES = "HOUSING_COMMUNITY_UPDATES"
|
29
|
+
HR_STAFFING = "HR_STAFFING"
|
30
|
+
INSURANCE_SERVICES = "INSURANCE_SERVICES"
|
31
|
+
JOB_DISPATCH = "JOB_DISPATCH"
|
32
|
+
LEGAL_SERVICES = "LEGAL_SERVICES"
|
33
|
+
MIXED = "MIXED"
|
34
|
+
MOTIVATIONAL_REMINDERS = "MOTIVATIONAL_REMINDERS"
|
35
|
+
NOTARY_NOTIFICATIONS = "NOTARY_NOTIFICATIONS"
|
36
|
+
ORDER_NOTIFICATIONS = "ORDER_NOTIFICATIONS"
|
37
|
+
POLITICAL = "POLITICAL"
|
38
|
+
PUBLIC_WORKS = "PUBLIC_WORKS"
|
39
|
+
REAL_ESTATE_SERVICES = "REAL_ESTATE_SERVICES"
|
40
|
+
RELIGIOUS_SERVICES = "RELIGIOUS_SERVICES"
|
41
|
+
REPAIR_DIAGNOSTICS_ALERTS = "REPAIR_DIAGNOSTICS_ALERTS"
|
42
|
+
REWARDS_PROGRAM = "REWARDS_PROGRAM"
|
43
|
+
SURVEYS = "SURVEYS"
|
44
|
+
SYSTEM_ALERTS = "SYSTEM_ALERTS"
|
45
|
+
TWO_FA = "TWO_FA"
|
46
|
+
VOTING_REMINDERS = "VOTING_REMINDERS"
|
47
|
+
WAITLIST_ALERTS = "WAITLIST_ALERTS"
|
48
|
+
WEBINAR_REMINDERS = "WEBINAR_REMINDERS"
|
49
|
+
WORKSHOP_ALERTS = "WORKSHOP_ALERTS"
|
50
|
+
end
|
51
|
+
end
|
52
|
+
end
|
@@ -0,0 +1,155 @@
|
|
1
|
+
# frozen_string_literal: true
|
2
|
+
|
3
|
+
require_relative "extended_brand"
|
4
|
+
require_relative "profile_status_enum"
|
5
|
+
require_relative "message_volume_enum"
|
6
|
+
require_relative "toll_free_campaign_schema_opt_in"
|
7
|
+
require_relative "toll_free_campaign_schema_use_case"
|
8
|
+
require "ostruct"
|
9
|
+
require "json"
|
10
|
+
|
11
|
+
module Pinnacle
|
12
|
+
module Types
|
13
|
+
class TollFreeCampaignWithExtendedBrandAndStatus
|
14
|
+
# @return [Pinnacle::Types::ExtendedBrand] Brand associated with this campaign.
|
15
|
+
attr_reader :brand
|
16
|
+
# @return [Pinnacle::Types::ProfileStatusEnum] Current review status of the brand.<br>
|
17
|
+
# `INCOMPLETE`: Has not been submitted.<br>
|
18
|
+
# `PENDING`: Currently being reviewed.<br>
|
19
|
+
# `VERIFIED`: Verified and good to go.<br>
|
20
|
+
# `UNVERIFIED`: No longer verified due to an update in the brand details.<br>
|
21
|
+
# `VETTED`: Brand has been vetted by an external provider and has received vetting
|
22
|
+
# scores.
|
23
|
+
attr_reader :status
|
24
|
+
# @return [Integer] Unique identifier for the campaign.
|
25
|
+
attr_reader :campaign_id
|
26
|
+
# @return [Pinnacle::Types::MessageVolumeEnum]
|
27
|
+
attr_reader :monthly_volume
|
28
|
+
# @return [String] Display name of the campaign.
|
29
|
+
attr_reader :name
|
30
|
+
# @return [Pinnacle::Types::TollFreeCampaignSchemaOptIn] Opt-in keyword settings.
|
31
|
+
attr_reader :opt_in
|
32
|
+
# @return [String] Explain message that would be sent.
|
33
|
+
attr_reader :production_message_content
|
34
|
+
# @return [Pinnacle::Types::TollFreeCampaignSchemaUseCase] Use case classification for the campaign.
|
35
|
+
attr_reader :use_case
|
36
|
+
# @return [OpenStruct] Additional properties unmapped to the current class definition
|
37
|
+
attr_reader :additional_properties
|
38
|
+
# @return [Object]
|
39
|
+
attr_reader :_field_set
|
40
|
+
protected :_field_set
|
41
|
+
|
42
|
+
OMIT = Object.new
|
43
|
+
|
44
|
+
# @param brand [Pinnacle::Types::ExtendedBrand] Brand associated with this campaign.
|
45
|
+
# @param status [Pinnacle::Types::ProfileStatusEnum] Current review status of the brand.<br>
|
46
|
+
# `INCOMPLETE`: Has not been submitted.<br>
|
47
|
+
# `PENDING`: Currently being reviewed.<br>
|
48
|
+
# `VERIFIED`: Verified and good to go.<br>
|
49
|
+
# `UNVERIFIED`: No longer verified due to an update in the brand details.<br>
|
50
|
+
# `VETTED`: Brand has been vetted by an external provider and has received vetting
|
51
|
+
# scores.
|
52
|
+
# @param campaign_id [Integer] Unique identifier for the campaign.
|
53
|
+
# @param monthly_volume [Pinnacle::Types::MessageVolumeEnum]
|
54
|
+
# @param name [String] Display name of the campaign.
|
55
|
+
# @param opt_in [Pinnacle::Types::TollFreeCampaignSchemaOptIn] Opt-in keyword settings.
|
56
|
+
# @param production_message_content [String] Explain message that would be sent.
|
57
|
+
# @param use_case [Pinnacle::Types::TollFreeCampaignSchemaUseCase] Use case classification for the campaign.
|
58
|
+
# @param additional_properties [OpenStruct] Additional properties unmapped to the current class definition
|
59
|
+
# @return [Pinnacle::Types::TollFreeCampaignWithExtendedBrandAndStatus]
|
60
|
+
def initialize(brand:, status:, campaign_id: OMIT, monthly_volume: OMIT, name: OMIT, opt_in: OMIT,
|
61
|
+
production_message_content: OMIT, use_case: OMIT, additional_properties: nil)
|
62
|
+
@brand = brand
|
63
|
+
@status = status
|
64
|
+
@campaign_id = campaign_id if campaign_id != OMIT
|
65
|
+
@monthly_volume = monthly_volume if monthly_volume != OMIT
|
66
|
+
@name = name if name != OMIT
|
67
|
+
@opt_in = opt_in if opt_in != OMIT
|
68
|
+
@production_message_content = production_message_content if production_message_content != OMIT
|
69
|
+
@use_case = use_case if use_case != OMIT
|
70
|
+
@additional_properties = additional_properties
|
71
|
+
@_field_set = {
|
72
|
+
"brand": brand,
|
73
|
+
"status": status,
|
74
|
+
"campaignId": campaign_id,
|
75
|
+
"monthlyVolume": monthly_volume,
|
76
|
+
"name": name,
|
77
|
+
"optIn": opt_in,
|
78
|
+
"productionMessageContent": production_message_content,
|
79
|
+
"useCase": use_case
|
80
|
+
}.reject do |_k, v|
|
81
|
+
v == OMIT
|
82
|
+
end
|
83
|
+
end
|
84
|
+
|
85
|
+
# Deserialize a JSON object to an instance of
|
86
|
+
# TollFreeCampaignWithExtendedBrandAndStatus
|
87
|
+
#
|
88
|
+
# @param json_object [String]
|
89
|
+
# @return [Pinnacle::Types::TollFreeCampaignWithExtendedBrandAndStatus]
|
90
|
+
def self.from_json(json_object:)
|
91
|
+
struct = JSON.parse(json_object, object_class: OpenStruct)
|
92
|
+
parsed_json = JSON.parse(json_object)
|
93
|
+
if parsed_json["brand"].nil?
|
94
|
+
brand = nil
|
95
|
+
else
|
96
|
+
brand = parsed_json["brand"].to_json
|
97
|
+
brand = Pinnacle::Types::ExtendedBrand.from_json(json_object: brand)
|
98
|
+
end
|
99
|
+
status = parsed_json["status"]
|
100
|
+
campaign_id = parsed_json["campaignId"]
|
101
|
+
monthly_volume = parsed_json["monthlyVolume"]
|
102
|
+
name = parsed_json["name"]
|
103
|
+
if parsed_json["optIn"].nil?
|
104
|
+
opt_in = nil
|
105
|
+
else
|
106
|
+
opt_in = parsed_json["optIn"].to_json
|
107
|
+
opt_in = Pinnacle::Types::TollFreeCampaignSchemaOptIn.from_json(json_object: opt_in)
|
108
|
+
end
|
109
|
+
production_message_content = parsed_json["productionMessageContent"]
|
110
|
+
if parsed_json["useCase"].nil?
|
111
|
+
use_case = nil
|
112
|
+
else
|
113
|
+
use_case = parsed_json["useCase"].to_json
|
114
|
+
use_case = Pinnacle::Types::TollFreeCampaignSchemaUseCase.from_json(json_object: use_case)
|
115
|
+
end
|
116
|
+
new(
|
117
|
+
brand: brand,
|
118
|
+
status: status,
|
119
|
+
campaign_id: campaign_id,
|
120
|
+
monthly_volume: monthly_volume,
|
121
|
+
name: name,
|
122
|
+
opt_in: opt_in,
|
123
|
+
production_message_content: production_message_content,
|
124
|
+
use_case: use_case,
|
125
|
+
additional_properties: struct
|
126
|
+
)
|
127
|
+
end
|
128
|
+
|
129
|
+
# Serialize an instance of TollFreeCampaignWithExtendedBrandAndStatus to a JSON
|
130
|
+
# object
|
131
|
+
#
|
132
|
+
# @return [String]
|
133
|
+
def to_json(*_args)
|
134
|
+
@_field_set&.to_json
|
135
|
+
end
|
136
|
+
|
137
|
+
# Leveraged for Union-type generation, validate_raw attempts to parse the given
|
138
|
+
# hash and check each fields type against the current object's property
|
139
|
+
# definitions.
|
140
|
+
#
|
141
|
+
# @param obj [Object]
|
142
|
+
# @return [Void]
|
143
|
+
def self.validate_raw(obj:)
|
144
|
+
Pinnacle::Types::ExtendedBrand.validate_raw(obj: obj.brand)
|
145
|
+
obj.status.is_a?(Pinnacle::Types::ProfileStatusEnum) != false || raise("Passed value for field obj.status is not the expected type, validation failed.")
|
146
|
+
obj.campaign_id&.is_a?(Integer) != false || raise("Passed value for field obj.campaign_id is not the expected type, validation failed.")
|
147
|
+
obj.monthly_volume&.is_a?(Pinnacle::Types::MessageVolumeEnum) != false || raise("Passed value for field obj.monthly_volume is not the expected type, validation failed.")
|
148
|
+
obj.name&.is_a?(String) != false || raise("Passed value for field obj.name is not the expected type, validation failed.")
|
149
|
+
obj.opt_in.nil? || Pinnacle::Types::TollFreeCampaignSchemaOptIn.validate_raw(obj: obj.opt_in)
|
150
|
+
obj.production_message_content&.is_a?(String) != false || raise("Passed value for field obj.production_message_content is not the expected type, validation failed.")
|
151
|
+
obj.use_case.nil? || Pinnacle::Types::TollFreeCampaignSchemaUseCase.validate_raw(obj: obj.use_case)
|
152
|
+
end
|
153
|
+
end
|
154
|
+
end
|
155
|
+
end
|
@@ -0,0 +1,20 @@
|
|
1
|
+
# frozen_string_literal: true
|
2
|
+
|
3
|
+
module Pinnacle
|
4
|
+
module Types
|
5
|
+
# Current assignment status of the toll free number to this campaign.
|
6
|
+
# `IN_PROGRESS`: Being reviewed.
|
7
|
+
# `WAITING_FOR_PROVIDER`: Being reviewed by our toll-free vendor.
|
8
|
+
# `WAITING_FOR_TELECO`: Final review by carriers before number is live.
|
9
|
+
# `VERIFIED`: Verified and ready to send messages.
|
10
|
+
# `REJECTED`: Issues were found related to your campaign.
|
11
|
+
class TollFreeStatusEnum
|
12
|
+
WAITING_FOR_PROVIDER = "WAITING_FOR_PROVIDER"
|
13
|
+
WAITING_FOR_CUSTOMER = "WAITING_FOR_CUSTOMER"
|
14
|
+
WAITING_FOR_TELECO = "WAITING_FOR_TELECO"
|
15
|
+
IN_PROGRESS = "IN_PROGRESS"
|
16
|
+
VERIFIED = "VERIFIED"
|
17
|
+
REJECTED = "REJECTED"
|
18
|
+
end
|
19
|
+
end
|
20
|
+
end
|
@@ -0,0 +1,17 @@
|
|
1
|
+
# frozen_string_literal: true
|
2
|
+
|
3
|
+
module Pinnacle
|
4
|
+
module Types
|
5
|
+
# Enable tracking on sent messages. If not provided, messages are not tracked. You
|
6
|
+
# will not be able to react to these messages unless you provide the
|
7
|
+
# [options.force](./react#request.body.options.force) field.
|
8
|
+
# `ID` - Append an explicit ID at the end of the message for tracking. Users will
|
9
|
+
# see this ID. <br>
|
10
|
+
# `HIDDEN` - Invisible IDs are sent with messages for tracking. Will not be
|
11
|
+
# visible to users but will lead to slightly longer message lengths.
|
12
|
+
class Tracking
|
13
|
+
ID = "ID"
|
14
|
+
HIDDEN = "HIDDEN"
|
15
|
+
end
|
16
|
+
end
|
17
|
+
end
|
@@ -0,0 +1,57 @@
|
|
1
|
+
# frozen_string_literal: true
|
2
|
+
|
3
|
+
require "ostruct"
|
4
|
+
require "json"
|
5
|
+
|
6
|
+
module Pinnacle
|
7
|
+
module Types
|
8
|
+
class UpdatedContactId
|
9
|
+
# @return [Integer] Unique ID of the updated contact.
|
10
|
+
attr_reader :id
|
11
|
+
# @return [OpenStruct] Additional properties unmapped to the current class definition
|
12
|
+
attr_reader :additional_properties
|
13
|
+
# @return [Object]
|
14
|
+
attr_reader :_field_set
|
15
|
+
protected :_field_set
|
16
|
+
|
17
|
+
OMIT = Object.new
|
18
|
+
|
19
|
+
# @param id [Integer] Unique ID of the updated contact.
|
20
|
+
# @param additional_properties [OpenStruct] Additional properties unmapped to the current class definition
|
21
|
+
# @return [Pinnacle::Types::UpdatedContactId]
|
22
|
+
def initialize(id:, additional_properties: nil)
|
23
|
+
@id = id
|
24
|
+
@additional_properties = additional_properties
|
25
|
+
@_field_set = { "id": id }
|
26
|
+
end
|
27
|
+
|
28
|
+
# Deserialize a JSON object to an instance of UpdatedContactId
|
29
|
+
#
|
30
|
+
# @param json_object [String]
|
31
|
+
# @return [Pinnacle::Types::UpdatedContactId]
|
32
|
+
def self.from_json(json_object:)
|
33
|
+
struct = JSON.parse(json_object, object_class: OpenStruct)
|
34
|
+
parsed_json = JSON.parse(json_object)
|
35
|
+
id = parsed_json["id"]
|
36
|
+
new(id: id, additional_properties: struct)
|
37
|
+
end
|
38
|
+
|
39
|
+
# Serialize an instance of UpdatedContactId to a JSON object
|
40
|
+
#
|
41
|
+
# @return [String]
|
42
|
+
def to_json(*_args)
|
43
|
+
@_field_set&.to_json
|
44
|
+
end
|
45
|
+
|
46
|
+
# Leveraged for Union-type generation, validate_raw attempts to parse the given
|
47
|
+
# hash and check each fields type against the current object's property
|
48
|
+
# definitions.
|
49
|
+
#
|
50
|
+
# @param obj [Object]
|
51
|
+
# @return [Void]
|
52
|
+
def self.validate_raw(obj:)
|
53
|
+
obj.id.is_a?(Integer) != false || raise("Passed value for field obj.id is not the expected type, validation failed.")
|
54
|
+
end
|
55
|
+
end
|
56
|
+
end
|
57
|
+
end
|
@@ -0,0 +1,80 @@
|
|
1
|
+
# frozen_string_literal: true
|
2
|
+
|
3
|
+
require_relative "pinnacle_file_upload_metadata"
|
4
|
+
require "ostruct"
|
5
|
+
require "json"
|
6
|
+
|
7
|
+
module Pinnacle
|
8
|
+
module Types
|
9
|
+
class UploadResults
|
10
|
+
# @return [String] Presigned URL for uploading your file to storage.
|
11
|
+
attr_reader :upload_url
|
12
|
+
# @return [String] Presigned URL for downloading your file.
|
13
|
+
attr_reader :download_url
|
14
|
+
# @return [Pinnacle::Types::PinnacleFileUploadMetadata]
|
15
|
+
attr_reader :metadata
|
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 upload_url [String] Presigned URL for uploading your file to storage.
|
25
|
+
# @param download_url [String] Presigned URL for downloading your file.
|
26
|
+
# @param metadata [Pinnacle::Types::PinnacleFileUploadMetadata]
|
27
|
+
# @param additional_properties [OpenStruct] Additional properties unmapped to the current class definition
|
28
|
+
# @return [Pinnacle::Types::UploadResults]
|
29
|
+
def initialize(upload_url:, download_url:, metadata:, additional_properties: nil)
|
30
|
+
@upload_url = upload_url
|
31
|
+
@download_url = download_url
|
32
|
+
@metadata = metadata
|
33
|
+
@additional_properties = additional_properties
|
34
|
+
@_field_set = { "uploadUrl": upload_url, "downloadUrl": download_url, "metadata": metadata }
|
35
|
+
end
|
36
|
+
|
37
|
+
# Deserialize a JSON object to an instance of UploadResults
|
38
|
+
#
|
39
|
+
# @param json_object [String]
|
40
|
+
# @return [Pinnacle::Types::UploadResults]
|
41
|
+
def self.from_json(json_object:)
|
42
|
+
struct = JSON.parse(json_object, object_class: OpenStruct)
|
43
|
+
parsed_json = JSON.parse(json_object)
|
44
|
+
upload_url = parsed_json["uploadUrl"]
|
45
|
+
download_url = parsed_json["downloadUrl"]
|
46
|
+
if parsed_json["metadata"].nil?
|
47
|
+
metadata = nil
|
48
|
+
else
|
49
|
+
metadata = parsed_json["metadata"].to_json
|
50
|
+
metadata = Pinnacle::Types::PinnacleFileUploadMetadata.from_json(json_object: metadata)
|
51
|
+
end
|
52
|
+
new(
|
53
|
+
upload_url: upload_url,
|
54
|
+
download_url: download_url,
|
55
|
+
metadata: metadata,
|
56
|
+
additional_properties: struct
|
57
|
+
)
|
58
|
+
end
|
59
|
+
|
60
|
+
# Serialize an instance of UploadResults to a JSON object
|
61
|
+
#
|
62
|
+
# @return [String]
|
63
|
+
def to_json(*_args)
|
64
|
+
@_field_set&.to_json
|
65
|
+
end
|
66
|
+
|
67
|
+
# Leveraged for Union-type generation, validate_raw attempts to parse the given
|
68
|
+
# hash and check each fields type against the current object's property
|
69
|
+
# definitions.
|
70
|
+
#
|
71
|
+
# @param obj [Object]
|
72
|
+
# @return [Void]
|
73
|
+
def self.validate_raw(obj:)
|
74
|
+
obj.upload_url.is_a?(String) != false || raise("Passed value for field obj.upload_url is not the expected type, validation failed.")
|
75
|
+
obj.download_url.is_a?(String) != false || raise("Passed value for field obj.download_url is not the expected type, validation failed.")
|
76
|
+
Pinnacle::Types::PinnacleFileUploadMetadata.validate_raw(obj: obj.metadata)
|
77
|
+
end
|
78
|
+
end
|
79
|
+
end
|
80
|
+
end
|