trycourier 4.7.1 → 4.9.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/CHANGELOG.md +63 -0
- data/README.md +25 -235
- data/lib/courier/client.rb +12 -0
- data/lib/courier/internal/util.rb +50 -6
- data/lib/courier/models/audience_delete_params.rb +7 -1
- data/lib/courier/models/audience_list_members_params.rb +8 -1
- data/lib/courier/models/audience_retrieve_params.rb +7 -1
- data/lib/courier/models/audience_update_params.rb +8 -1
- data/lib/courier/models/audit_event_retrieve_params.rb +7 -1
- data/lib/courier/models/automations/invoke_invoke_by_template_params.rb +7 -1
- data/lib/courier/models/brand_delete_params.rb +7 -1
- data/lib/courier/models/brand_retrieve_params.rb +7 -1
- data/lib/courier/models/brand_update_params.rb +8 -1
- data/lib/courier/models/bulk_add_users_params.rb +7 -1
- data/lib/courier/models/bulk_list_users_params.rb +8 -1
- data/lib/courier/models/bulk_retrieve_job_params.rb +7 -1
- data/lib/courier/models/bulk_run_job_params.rb +7 -1
- data/lib/courier/models/channel.rb +75 -0
- data/lib/courier/models/channel_metadata.rb +15 -0
- data/lib/courier/models/elemental_content.rb +3 -10
- data/lib/courier/models/elemental_html_node_with_type.rb +24 -0
- data/lib/courier/models/elemental_node.rb +3 -1
- data/lib/courier/models/journey.rb +63 -0
- data/lib/courier/models/journey_invoke_params.rb +20 -0
- data/lib/courier/models/journey_list_params.rb +47 -0
- data/lib/courier/models/journeys_invoke_request.rb +49 -0
- data/lib/courier/models/journeys_invoke_response.rb +17 -0
- data/lib/courier/models/journeys_list_response.rb +24 -0
- data/lib/courier/models/list_delete_params.rb +7 -1
- data/lib/courier/models/list_restore_params.rb +7 -1
- data/lib/courier/models/list_retrieve_params.rb +7 -1
- data/lib/courier/models/list_update_params.rb +7 -1
- data/lib/courier/models/lists/subscription_add_params.rb +7 -1
- data/lib/courier/models/lists/subscription_list_params.rb +8 -1
- data/lib/courier/models/lists/subscription_subscribe_params.rb +7 -1
- data/lib/courier/models/lists/subscription_subscribe_user_params.rb +7 -1
- data/lib/courier/models/lists/subscription_unsubscribe_user_params.rb +7 -1
- data/lib/courier/models/message_cancel_params.rb +7 -1
- data/lib/courier/models/message_channels.rb +8 -0
- data/lib/courier/models/message_content_params.rb +7 -1
- data/lib/courier/models/message_details.rb +37 -37
- data/lib/courier/models/message_history_params.rb +8 -1
- data/lib/courier/models/message_providers.rb +8 -0
- data/lib/courier/models/message_providers_type.rb +38 -0
- data/lib/courier/models/message_retrieve_params.rb +7 -1
- data/lib/courier/models/metadata.rb +15 -0
- data/lib/courier/models/notification_archive_params.rb +20 -0
- data/lib/courier/models/notification_create_params.rb +14 -0
- data/lib/courier/models/notification_list_params.rb +13 -4
- data/lib/courier/models/notification_list_response.rb +108 -93
- data/lib/courier/models/notification_list_versions_params.rb +37 -0
- data/lib/courier/models/notification_publish_params.rb +20 -0
- data/lib/courier/models/notification_replace_params.rb +20 -0
- data/lib/courier/models/notification_retrieve_content_params.rb +7 -1
- data/lib/courier/models/notification_retrieve_params.rb +33 -0
- data/lib/courier/models/notification_template_create_request.rb +45 -0
- data/lib/courier/models/notification_template_get_response.rb +92 -0
- data/lib/courier/models/notification_template_mutation_response.rb +51 -0
- data/lib/courier/models/notification_template_payload.rb +98 -0
- data/lib/courier/models/notification_template_publish_request.rb +19 -0
- data/lib/courier/models/notification_template_summary.rb +81 -0
- data/lib/courier/models/notification_template_update_request.rb +46 -0
- data/lib/courier/models/notification_template_version_list_response.rb +22 -0
- data/lib/courier/models/notifications/check_delete_params.rb +7 -1
- data/lib/courier/models/notifications/check_list_params.rb +7 -1
- data/lib/courier/models/notifications/check_update_params.rb +7 -1
- data/lib/courier/models/notifications/draft_retrieve_content_params.rb +7 -1
- data/lib/courier/models/profile_create_params.rb +7 -1
- data/lib/courier/models/profile_delete_params.rb +7 -1
- data/lib/courier/models/profile_replace_params.rb +7 -1
- data/lib/courier/models/profile_retrieve_params.rb +7 -1
- data/lib/courier/models/profile_update_params.rb +8 -1
- data/lib/courier/models/profiles/list_delete_params.rb +7 -1
- data/lib/courier/models/profiles/list_retrieve_params.rb +8 -1
- data/lib/courier/models/profiles/list_subscribe_params.rb +7 -1
- data/lib/courier/models/provider.rb +67 -0
- data/lib/courier/models/provider_create_params.rb +52 -0
- data/lib/courier/models/provider_delete_params.rb +20 -0
- data/lib/courier/models/provider_list_params.rb +22 -0
- data/lib/courier/models/provider_list_response.rb +24 -0
- data/lib/courier/models/provider_retrieve_params.rb +20 -0
- data/lib/courier/models/provider_update_params.rb +58 -0
- data/lib/courier/models/providers/catalog_list_params.rb +44 -0
- data/lib/courier/models/providers/catalog_list_response.rb +26 -0
- data/lib/courier/models/providers_catalog_entry.rb +86 -0
- data/lib/courier/models/request_archive_params.rb +7 -1
- data/lib/courier/models/routing_strategy_archive_params.rb +20 -0
- data/lib/courier/models/routing_strategy_create_params.rb +14 -0
- data/lib/courier/models/routing_strategy_create_request.rb +58 -0
- data/lib/courier/models/routing_strategy_get_response.rb +99 -0
- data/lib/courier/models/routing_strategy_list_params.rb +30 -0
- data/lib/courier/models/routing_strategy_list_response.rb +24 -0
- data/lib/courier/models/routing_strategy_mutation_response.rb +19 -0
- data/lib/courier/models/routing_strategy_replace_params.rb +20 -0
- data/lib/courier/models/routing_strategy_replace_request.rb +59 -0
- data/lib/courier/models/routing_strategy_retrieve_params.rb +20 -0
- data/lib/courier/models/routing_strategy_summary.rb +75 -0
- data/lib/courier/models/send_message_params.rb +6 -154
- data/lib/courier/models/tenant_delete_params.rb +7 -1
- data/lib/courier/models/tenant_list_users_params.rb +8 -1
- data/lib/courier/models/tenant_retrieve_params.rb +7 -1
- data/lib/courier/models/tenant_template_input.rb +6 -152
- data/lib/courier/models/tenant_update_params.rb +8 -1
- data/lib/courier/models/tenants/preferences/item_delete_params.rb +7 -1
- data/lib/courier/models/tenants/preferences/item_update_params.rb +7 -1
- data/lib/courier/models/tenants/template_list_params.rb +8 -1
- data/lib/courier/models/tenants/template_publish_params.rb +7 -1
- data/lib/courier/models/tenants/template_replace_params.rb +7 -1
- data/lib/courier/models/tenants/template_retrieve_params.rb +7 -1
- data/lib/courier/models/tenants/templates/version_retrieve_params.rb +7 -1
- data/lib/courier/models/timeouts.rb +21 -0
- data/lib/courier/models/translation_retrieve_params.rb +7 -1
- data/lib/courier/models/translation_update_params.rb +7 -1
- data/lib/courier/models/users/preference_retrieve_params.rb +8 -1
- data/lib/courier/models/users/preference_retrieve_topic_params.rb +8 -1
- data/lib/courier/models/users/preference_update_or_create_topic_params.rb +8 -1
- data/lib/courier/models/users/tenant_add_multiple_params.rb +7 -1
- data/lib/courier/models/users/tenant_add_single_params.rb +7 -1
- data/lib/courier/models/users/tenant_list_params.rb +8 -1
- data/lib/courier/models/users/tenant_remove_all_params.rb +7 -1
- data/lib/courier/models/users/tenant_remove_single_params.rb +7 -1
- data/lib/courier/models/users/token_add_multiple_params.rb +7 -1
- data/lib/courier/models/users/token_add_single_params.rb +168 -2
- data/lib/courier/models/users/token_delete_params.rb +7 -1
- data/lib/courier/models/users/token_list_params.rb +7 -1
- data/lib/courier/models/users/token_retrieve_params.rb +7 -1
- data/lib/courier/models/users/token_update_params.rb +7 -1
- data/lib/courier/models/version_node.rb +46 -0
- data/lib/courier/models.rb +98 -0
- data/lib/courier/resources/audiences.rb +4 -2
- data/lib/courier/resources/audit_events.rb +2 -1
- data/lib/courier/resources/automations.rb +2 -1
- data/lib/courier/resources/brands.rb +2 -1
- data/lib/courier/resources/bulk.rb +2 -1
- data/lib/courier/resources/journeys.rb +73 -0
- data/lib/courier/resources/lists/subscriptions.rb +2 -1
- data/lib/courier/resources/lists.rb +2 -1
- data/lib/courier/resources/messages.rb +4 -2
- data/lib/courier/resources/notifications.rb +167 -4
- data/lib/courier/resources/profiles/lists.rb +2 -1
- data/lib/courier/resources/providers/catalog.rb +49 -0
- data/lib/courier/resources/providers.rb +150 -0
- data/lib/courier/resources/routing_strategies.rb +151 -0
- data/lib/courier/resources/tenants/templates.rb +2 -1
- data/lib/courier/resources/tenants.rb +4 -2
- data/lib/courier/resources/users/preferences.rb +7 -4
- data/lib/courier/resources/users/tenants.rb +2 -1
- data/lib/courier/resources/users/tokens.rb +7 -9
- data/lib/courier/version.rb +1 -1
- data/lib/courier.rb +54 -0
- data/rbi/courier/client.rbi +9 -0
- data/rbi/courier/internal/util.rbi +28 -0
- data/rbi/courier/models/audience_delete_params.rbi +13 -5
- data/rbi/courier/models/audience_list_members_params.rbi +6 -0
- data/rbi/courier/models/audience_retrieve_params.rbi +13 -5
- data/rbi/courier/models/audience_update_params.rbi +6 -0
- data/rbi/courier/models/audit_event_retrieve_params.rbi +13 -5
- data/rbi/courier/models/automations/invoke_invoke_by_template_params.rbi +6 -0
- data/rbi/courier/models/brand_delete_params.rbi +13 -5
- data/rbi/courier/models/brand_retrieve_params.rbi +13 -5
- data/rbi/courier/models/brand_update_params.rbi +6 -0
- data/rbi/courier/models/bulk_add_users_params.rbi +6 -1
- data/rbi/courier/models/bulk_list_users_params.rbi +6 -0
- data/rbi/courier/models/bulk_retrieve_job_params.rbi +13 -5
- data/rbi/courier/models/bulk_run_job_params.rbi +13 -5
- data/rbi/courier/models/channel.rbi +106 -0
- data/rbi/courier/models/channel_metadata.rbi +28 -0
- data/rbi/courier/models/elemental_content.rbi +9 -12
- data/rbi/courier/models/elemental_html_node_with_type.rbi +59 -0
- data/rbi/courier/models/elemental_node.rbi +2 -1
- data/rbi/courier/models/journey.rbi +91 -0
- data/rbi/courier/models/journey_invoke_params.rbi +35 -0
- data/rbi/courier/models/journey_list_params.rbi +85 -0
- data/rbi/courier/models/journeys_invoke_request.rbi +84 -0
- data/rbi/courier/models/journeys_invoke_response.rbi +27 -0
- data/rbi/courier/models/journeys_list_response.rbi +46 -0
- data/rbi/courier/models/list_delete_params.rbi +13 -5
- data/rbi/courier/models/list_restore_params.rbi +13 -5
- data/rbi/courier/models/list_retrieve_params.rbi +13 -5
- data/rbi/courier/models/list_update_params.rbi +6 -1
- data/rbi/courier/models/lists/subscription_add_params.rbi +6 -1
- data/rbi/courier/models/lists/subscription_list_params.rbi +6 -0
- data/rbi/courier/models/lists/subscription_subscribe_params.rbi +6 -1
- data/rbi/courier/models/lists/subscription_subscribe_user_params.rbi +6 -1
- data/rbi/courier/models/lists/subscription_unsubscribe_user_params.rbi +10 -2
- data/rbi/courier/models/message_cancel_params.rbi +13 -5
- data/rbi/courier/models/message_channels.rbi +11 -0
- data/rbi/courier/models/message_content_params.rbi +13 -5
- data/rbi/courier/models/message_details.rbi +55 -43
- data/rbi/courier/models/message_history_params.rbi +10 -1
- data/rbi/courier/models/message_providers.rbi +11 -0
- data/rbi/courier/models/message_providers_type.rbi +60 -0
- data/rbi/courier/models/message_retrieve_params.rbi +13 -5
- data/rbi/courier/models/metadata.rbi +26 -0
- data/rbi/courier/models/notification_archive_params.rbi +35 -0
- data/rbi/courier/models/notification_create_params.rbi +27 -0
- data/rbi/courier/models/notification_list_params.rbi +15 -2
- data/rbi/courier/models/notification_list_response.rbi +159 -119
- data/rbi/courier/models/notification_list_versions_params.rbi +66 -0
- data/rbi/courier/models/notification_publish_params.rbi +35 -0
- data/rbi/courier/models/notification_replace_params.rbi +35 -0
- data/rbi/courier/models/notification_retrieve_content_params.rbi +13 -5
- data/rbi/courier/models/notification_retrieve_params.rbi +54 -0
- data/rbi/courier/models/notification_template_create_request.rbi +102 -0
- data/rbi/courier/models/notification_template_get_response.rbi +162 -0
- data/rbi/courier/models/notification_template_mutation_response.rbi +121 -0
- data/rbi/courier/models/notification_template_payload.rbi +183 -0
- data/rbi/courier/models/notification_template_publish_request.rbi +35 -0
- data/rbi/courier/models/notification_template_summary.rbi +124 -0
- data/rbi/courier/models/notification_template_update_request.rbi +103 -0
- data/rbi/courier/models/notification_template_version_list_response.rbi +41 -0
- data/rbi/courier/models/notifications/check_delete_params.rbi +10 -2
- data/rbi/courier/models/notifications/check_list_params.rbi +10 -2
- data/rbi/courier/models/notifications/check_update_params.rbi +6 -1
- data/rbi/courier/models/notifications/draft_retrieve_content_params.rbi +13 -5
- data/rbi/courier/models/profile_create_params.rbi +6 -1
- data/rbi/courier/models/profile_delete_params.rbi +13 -5
- data/rbi/courier/models/profile_replace_params.rbi +6 -1
- data/rbi/courier/models/profile_retrieve_params.rbi +13 -5
- data/rbi/courier/models/profile_update_params.rbi +6 -0
- data/rbi/courier/models/profiles/list_delete_params.rbi +13 -5
- data/rbi/courier/models/profiles/list_retrieve_params.rbi +6 -0
- data/rbi/courier/models/profiles/list_subscribe_params.rbi +6 -1
- data/rbi/courier/models/provider.rbi +87 -0
- data/rbi/courier/models/provider_create_params.rbi +82 -0
- data/rbi/courier/models/provider_delete_params.rbi +35 -0
- data/rbi/courier/models/provider_list_params.rbi +43 -0
- data/rbi/courier/models/provider_list_response.rbi +42 -0
- data/rbi/courier/models/provider_retrieve_params.rbi +35 -0
- data/rbi/courier/models/provider_update_params.rbi +86 -0
- data/rbi/courier/models/providers/catalog_list_params.rbi +75 -0
- data/rbi/courier/models/providers/catalog_list_response.rbi +47 -0
- data/rbi/courier/models/providers_catalog_entry.rbi +129 -0
- data/rbi/courier/models/request_archive_params.rbi +13 -5
- data/rbi/courier/models/routing_strategy_archive_params.rbi +38 -0
- data/rbi/courier/models/routing_strategy_create_params.rbi +30 -0
- data/rbi/courier/models/routing_strategy_create_request.rbi +86 -0
- data/rbi/courier/models/routing_strategy_get_response.rbi +121 -0
- data/rbi/courier/models/routing_strategy_list_params.rbi +54 -0
- data/rbi/courier/models/routing_strategy_list_response.rbi +45 -0
- data/rbi/courier/models/routing_strategy_mutation_response.rbi +31 -0
- data/rbi/courier/models/routing_strategy_replace_params.rbi +38 -0
- data/rbi/courier/models/routing_strategy_replace_request.rbi +87 -0
- data/rbi/courier/models/routing_strategy_retrieve_params.rbi +38 -0
- data/rbi/courier/models/routing_strategy_summary.rbi +95 -0
- data/rbi/courier/models/send_message_params.rbi +6 -362
- data/rbi/courier/models/tenant_delete_params.rbi +13 -5
- data/rbi/courier/models/tenant_list_users_params.rbi +6 -0
- data/rbi/courier/models/tenant_retrieve_params.rbi +13 -5
- data/rbi/courier/models/tenant_template_input.rbi +8 -336
- data/rbi/courier/models/tenant_update_params.rbi +6 -0
- data/rbi/courier/models/tenants/preferences/item_delete_params.rbi +10 -2
- data/rbi/courier/models/tenants/preferences/item_update_params.rbi +10 -2
- data/rbi/courier/models/tenants/template_list_params.rbi +6 -0
- data/rbi/courier/models/tenants/template_publish_params.rbi +10 -2
- data/rbi/courier/models/tenants/template_replace_params.rbi +10 -2
- data/rbi/courier/models/tenants/template_retrieve_params.rbi +10 -2
- data/rbi/courier/models/tenants/templates/version_retrieve_params.rbi +6 -1
- data/rbi/courier/models/timeouts.rbi +33 -0
- data/rbi/courier/models/translation_retrieve_params.rbi +10 -2
- data/rbi/courier/models/translation_update_params.rbi +6 -1
- data/rbi/courier/models/users/preference_retrieve_params.rbi +6 -0
- data/rbi/courier/models/users/preference_retrieve_topic_params.rbi +6 -0
- data/rbi/courier/models/users/preference_update_or_create_topic_params.rbi +6 -0
- data/rbi/courier/models/users/tenant_add_multiple_params.rbi +6 -1
- data/rbi/courier/models/users/tenant_add_single_params.rbi +6 -1
- data/rbi/courier/models/users/tenant_list_params.rbi +6 -0
- data/rbi/courier/models/users/tenant_remove_all_params.rbi +13 -5
- data/rbi/courier/models/users/tenant_remove_single_params.rbi +10 -2
- data/rbi/courier/models/users/token_add_multiple_params.rbi +13 -5
- data/rbi/courier/models/users/token_add_single_params.rbi +290 -3
- data/rbi/courier/models/users/token_delete_params.rbi +10 -2
- data/rbi/courier/models/users/token_list_params.rbi +13 -5
- data/rbi/courier/models/users/token_retrieve_params.rbi +10 -2
- data/rbi/courier/models/users/token_update_params.rbi +6 -1
- data/rbi/courier/models/version_node.rbi +65 -0
- data/rbi/courier/models.rbi +106 -0
- data/rbi/courier/resources/journeys.rbi +64 -0
- data/rbi/courier/resources/notifications.rbi +119 -1
- data/rbi/courier/resources/providers/catalog.rbi +38 -0
- data/rbi/courier/resources/providers.rbi +116 -0
- data/rbi/courier/resources/routing_strategies.rbi +126 -0
- data/rbi/courier/resources/users/tokens.rbi +11 -9
- data/sig/courier/client.rbs +6 -0
- data/sig/courier/internal/util.rbs +14 -0
- data/sig/courier/models/audience_delete_params.rbs +11 -3
- data/sig/courier/models/audience_list_members_params.rbs +6 -1
- data/sig/courier/models/audience_retrieve_params.rbs +11 -3
- data/sig/courier/models/audience_update_params.rbs +5 -0
- data/sig/courier/models/audit_event_retrieve_params.rbs +11 -3
- data/sig/courier/models/automations/invoke_invoke_by_template_params.rbs +5 -0
- data/sig/courier/models/brand_delete_params.rbs +11 -3
- data/sig/courier/models/brand_retrieve_params.rbs +11 -3
- data/sig/courier/models/brand_update_params.rbs +5 -0
- data/sig/courier/models/bulk_add_users_params.rbs +5 -1
- data/sig/courier/models/bulk_list_users_params.rbs +6 -1
- data/sig/courier/models/bulk_retrieve_job_params.rbs +11 -3
- data/sig/courier/models/bulk_run_job_params.rbs +11 -3
- data/sig/courier/models/channel.rbs +61 -0
- data/sig/courier/models/channel_metadata.rbs +13 -0
- data/sig/courier/models/elemental_content.rbs +3 -11
- data/sig/courier/models/elemental_html_node_with_type.rbs +32 -0
- data/sig/courier/models/elemental_node.rbs +1 -0
- data/sig/courier/models/journey.rbs +55 -0
- data/sig/courier/models/journey_invoke_params.rbs +25 -0
- data/sig/courier/models/journey_list_params.rbs +45 -0
- data/sig/courier/models/journeys_invoke_request.rbs +36 -0
- data/sig/courier/models/journeys_invoke_response.rbs +13 -0
- data/sig/courier/models/journeys_list_response.rbs +23 -0
- data/sig/courier/models/list_delete_params.rbs +12 -3
- data/sig/courier/models/list_restore_params.rbs +11 -3
- data/sig/courier/models/list_retrieve_params.rbs +11 -3
- data/sig/courier/models/list_update_params.rbs +9 -1
- data/sig/courier/models/lists/subscription_add_params.rbs +8 -1
- data/sig/courier/models/lists/subscription_list_params.rbs +6 -1
- data/sig/courier/models/lists/subscription_subscribe_params.rbs +8 -1
- data/sig/courier/models/lists/subscription_subscribe_user_params.rbs +9 -1
- data/sig/courier/models/lists/subscription_unsubscribe_user_params.rbs +6 -1
- data/sig/courier/models/message_cancel_params.rbs +11 -3
- data/sig/courier/models/message_channels.rbs +7 -0
- data/sig/courier/models/message_content_params.rbs +11 -3
- data/sig/courier/models/message_details.rbs +31 -23
- data/sig/courier/models/message_history_params.rbs +6 -1
- data/sig/courier/models/message_providers.rbs +7 -0
- data/sig/courier/models/message_providers_type.rbs +35 -0
- data/sig/courier/models/message_retrieve_params.rbs +11 -3
- data/sig/courier/models/metadata.rbs +13 -0
- data/sig/courier/models/notification_archive_params.rbs +20 -0
- data/sig/courier/models/notification_create_params.rbs +15 -0
- data/sig/courier/models/notification_list_params.rbs +7 -1
- data/sig/courier/models/notification_list_response.rbs +81 -71
- data/sig/courier/models/notification_list_versions_params.rbs +36 -0
- data/sig/courier/models/notification_publish_params.rbs +22 -0
- data/sig/courier/models/notification_replace_params.rbs +22 -0
- data/sig/courier/models/notification_retrieve_content_params.rbs +8 -3
- data/sig/courier/models/notification_retrieve_params.rbs +30 -0
- data/sig/courier/models/notification_template_create_request.rbs +40 -0
- data/sig/courier/models/notification_template_get_response.rbs +72 -0
- data/sig/courier/models/notification_template_mutation_response.rbs +46 -0
- data/sig/courier/models/notification_template_payload.rbs +75 -0
- data/sig/courier/models/notification_template_publish_request.rbs +15 -0
- data/sig/courier/models/notification_template_summary.rbs +70 -0
- data/sig/courier/models/notification_template_update_request.rbs +40 -0
- data/sig/courier/models/notification_template_version_list_response.rbs +22 -0
- data/sig/courier/models/notifications/check_delete_params.rbs +10 -2
- data/sig/courier/models/notifications/check_list_params.rbs +10 -2
- data/sig/courier/models/notifications/check_update_params.rbs +9 -1
- data/sig/courier/models/notifications/draft_retrieve_content_params.rbs +8 -3
- data/sig/courier/models/profile_create_params.rbs +5 -1
- data/sig/courier/models/profile_delete_params.rbs +11 -3
- data/sig/courier/models/profile_replace_params.rbs +5 -1
- data/sig/courier/models/profile_retrieve_params.rbs +11 -3
- data/sig/courier/models/profile_update_params.rbs +5 -1
- data/sig/courier/models/profiles/list_delete_params.rbs +11 -3
- data/sig/courier/models/profiles/list_retrieve_params.rbs +6 -1
- data/sig/courier/models/profiles/list_subscribe_params.rbs +8 -1
- data/sig/courier/models/provider.rbs +52 -0
- data/sig/courier/models/provider_create_params.rbs +47 -0
- data/sig/courier/models/provider_delete_params.rbs +20 -0
- data/sig/courier/models/provider_list_params.rbs +25 -0
- data/sig/courier/models/provider_list_response.rbs +22 -0
- data/sig/courier/models/provider_retrieve_params.rbs +20 -0
- data/sig/courier/models/provider_update_params.rbs +52 -0
- data/sig/courier/models/providers/catalog_list_params.rbs +40 -0
- data/sig/courier/models/providers/catalog_list_response.rbs +27 -0
- data/sig/courier/models/providers_catalog_entry.rbs +64 -0
- data/sig/courier/models/request_archive_params.rbs +11 -3
- data/sig/courier/models/routing_strategy_archive_params.rbs +20 -0
- data/sig/courier/models/routing_strategy_create_params.rbs +15 -0
- data/sig/courier/models/routing_strategy_create_request.rbs +45 -0
- data/sig/courier/models/routing_strategy_get_response.rbs +70 -0
- data/sig/courier/models/routing_strategy_list_params.rbs +30 -0
- data/sig/courier/models/routing_strategy_list_response.rbs +25 -0
- data/sig/courier/models/routing_strategy_mutation_response.rbs +13 -0
- data/sig/courier/models/routing_strategy_replace_params.rbs +22 -0
- data/sig/courier/models/routing_strategy_replace_request.rbs +45 -0
- data/sig/courier/models/routing_strategy_retrieve_params.rbs +20 -0
- data/sig/courier/models/routing_strategy_summary.rbs +55 -0
- data/sig/courier/models/send_message_params.rbs +8 -130
- data/sig/courier/models/tenant_delete_params.rbs +11 -3
- data/sig/courier/models/tenant_list_users_params.rbs +5 -1
- data/sig/courier/models/tenant_retrieve_params.rbs +11 -3
- data/sig/courier/models/tenant_template_input.rbs +12 -134
- data/sig/courier/models/tenant_update_params.rbs +5 -0
- data/sig/courier/models/tenants/preferences/item_delete_params.rbs +6 -1
- data/sig/courier/models/tenants/preferences/item_update_params.rbs +8 -1
- data/sig/courier/models/tenants/template_list_params.rbs +5 -1
- data/sig/courier/models/tenants/template_publish_params.rbs +8 -1
- data/sig/courier/models/tenants/template_replace_params.rbs +8 -1
- data/sig/courier/models/tenants/template_retrieve_params.rbs +6 -1
- data/sig/courier/models/tenants/templates/version_retrieve_params.rbs +5 -1
- data/sig/courier/models/timeouts.rbs +15 -0
- data/sig/courier/models/translation_retrieve_params.rbs +6 -1
- data/sig/courier/models/translation_update_params.rbs +5 -1
- data/sig/courier/models/users/preference_retrieve_params.rbs +6 -1
- data/sig/courier/models/users/preference_retrieve_topic_params.rbs +5 -1
- data/sig/courier/models/users/preference_update_or_create_topic_params.rbs +5 -0
- data/sig/courier/models/users/tenant_add_multiple_params.rbs +5 -1
- data/sig/courier/models/users/tenant_add_single_params.rbs +5 -1
- data/sig/courier/models/users/tenant_list_params.rbs +5 -1
- data/sig/courier/models/users/tenant_remove_all_params.rbs +11 -3
- data/sig/courier/models/users/tenant_remove_single_params.rbs +6 -1
- data/sig/courier/models/users/token_add_multiple_params.rbs +11 -3
- data/sig/courier/models/users/token_add_single_params.rbs +127 -4
- data/sig/courier/models/users/token_delete_params.rbs +6 -1
- data/sig/courier/models/users/token_list_params.rbs +11 -3
- data/sig/courier/models/users/token_retrieve_params.rbs +6 -1
- data/sig/courier/models/users/token_update_params.rbs +5 -0
- data/sig/courier/models/version_node.rbs +32 -0
- data/sig/courier/models.rbs +96 -0
- data/sig/courier/resources/journeys.rbs +21 -0
- data/sig/courier/resources/notifications.rbs +35 -0
- data/sig/courier/resources/providers/catalog.rbs +16 -0
- data/sig/courier/resources/providers.rbs +38 -0
- data/sig/courier/resources/routing_strategies.rbs +41 -0
- data/sig/courier/resources/users/tokens.rbs +5 -6
- metadata +164 -2
|
@@ -0,0 +1,38 @@
|
|
|
1
|
+
# typed: strong
|
|
2
|
+
|
|
3
|
+
module Courier
|
|
4
|
+
module Models
|
|
5
|
+
class RoutingStrategyArchiveParams < Courier::Internal::Type::BaseModel
|
|
6
|
+
extend Courier::Internal::Type::RequestParameters::Converter
|
|
7
|
+
include Courier::Internal::Type::RequestParameters
|
|
8
|
+
|
|
9
|
+
OrHash =
|
|
10
|
+
T.type_alias do
|
|
11
|
+
T.any(
|
|
12
|
+
Courier::RoutingStrategyArchiveParams,
|
|
13
|
+
Courier::Internal::AnyHash
|
|
14
|
+
)
|
|
15
|
+
end
|
|
16
|
+
|
|
17
|
+
sig { returns(String) }
|
|
18
|
+
attr_accessor :id
|
|
19
|
+
|
|
20
|
+
sig do
|
|
21
|
+
params(
|
|
22
|
+
id: String,
|
|
23
|
+
request_options: Courier::RequestOptions::OrHash
|
|
24
|
+
).returns(T.attached_class)
|
|
25
|
+
end
|
|
26
|
+
def self.new(id:, request_options: {})
|
|
27
|
+
end
|
|
28
|
+
|
|
29
|
+
sig do
|
|
30
|
+
override.returns(
|
|
31
|
+
{ id: String, request_options: Courier::RequestOptions }
|
|
32
|
+
)
|
|
33
|
+
end
|
|
34
|
+
def to_hash
|
|
35
|
+
end
|
|
36
|
+
end
|
|
37
|
+
end
|
|
38
|
+
end
|
|
@@ -0,0 +1,30 @@
|
|
|
1
|
+
# typed: strong
|
|
2
|
+
|
|
3
|
+
module Courier
|
|
4
|
+
module Models
|
|
5
|
+
class RoutingStrategyCreateParams < Courier::Models::RoutingStrategyCreateRequest
|
|
6
|
+
extend Courier::Internal::Type::RequestParameters::Converter
|
|
7
|
+
include Courier::Internal::Type::RequestParameters
|
|
8
|
+
|
|
9
|
+
OrHash =
|
|
10
|
+
T.type_alias do
|
|
11
|
+
T.any(
|
|
12
|
+
Courier::RoutingStrategyCreateParams,
|
|
13
|
+
Courier::Internal::AnyHash
|
|
14
|
+
)
|
|
15
|
+
end
|
|
16
|
+
|
|
17
|
+
sig do
|
|
18
|
+
params(request_options: Courier::RequestOptions::OrHash).returns(
|
|
19
|
+
T.attached_class
|
|
20
|
+
)
|
|
21
|
+
end
|
|
22
|
+
def self.new(request_options: {})
|
|
23
|
+
end
|
|
24
|
+
|
|
25
|
+
sig { override.returns({ request_options: Courier::RequestOptions }) }
|
|
26
|
+
def to_hash
|
|
27
|
+
end
|
|
28
|
+
end
|
|
29
|
+
end
|
|
30
|
+
end
|
|
@@ -0,0 +1,86 @@
|
|
|
1
|
+
# typed: strong
|
|
2
|
+
|
|
3
|
+
module Courier
|
|
4
|
+
module Models
|
|
5
|
+
class RoutingStrategyCreateRequest < Courier::Internal::Type::BaseModel
|
|
6
|
+
OrHash =
|
|
7
|
+
T.type_alias do
|
|
8
|
+
T.any(
|
|
9
|
+
Courier::RoutingStrategyCreateRequest,
|
|
10
|
+
Courier::Internal::AnyHash
|
|
11
|
+
)
|
|
12
|
+
end
|
|
13
|
+
|
|
14
|
+
# Human-readable name for the routing strategy.
|
|
15
|
+
sig { returns(String) }
|
|
16
|
+
attr_accessor :name
|
|
17
|
+
|
|
18
|
+
# Routing tree defining channel selection method and order.
|
|
19
|
+
sig { returns(Courier::MessageRouting) }
|
|
20
|
+
attr_reader :routing
|
|
21
|
+
|
|
22
|
+
sig { params(routing: Courier::MessageRouting::OrHash).void }
|
|
23
|
+
attr_writer :routing
|
|
24
|
+
|
|
25
|
+
# Per-channel delivery configuration. Defaults to empty if omitted.
|
|
26
|
+
sig { returns(T.nilable(T::Hash[Symbol, Courier::Channel])) }
|
|
27
|
+
attr_accessor :channels
|
|
28
|
+
|
|
29
|
+
# Optional description of the routing strategy.
|
|
30
|
+
sig { returns(T.nilable(String)) }
|
|
31
|
+
attr_accessor :description
|
|
32
|
+
|
|
33
|
+
# Per-provider delivery configuration. Defaults to empty if omitted.
|
|
34
|
+
sig { returns(T.nilable(T::Hash[Symbol, Courier::MessageProvidersType])) }
|
|
35
|
+
attr_accessor :providers
|
|
36
|
+
|
|
37
|
+
# Optional tags for categorization.
|
|
38
|
+
sig { returns(T.nilable(T::Array[String])) }
|
|
39
|
+
attr_accessor :tags
|
|
40
|
+
|
|
41
|
+
# Request body for creating a routing strategy.
|
|
42
|
+
sig do
|
|
43
|
+
params(
|
|
44
|
+
name: String,
|
|
45
|
+
routing: Courier::MessageRouting::OrHash,
|
|
46
|
+
channels: T.nilable(T::Hash[Symbol, Courier::Channel::OrHash]),
|
|
47
|
+
description: T.nilable(String),
|
|
48
|
+
providers:
|
|
49
|
+
T.nilable(T::Hash[Symbol, Courier::MessageProvidersType::OrHash]),
|
|
50
|
+
tags: T.nilable(T::Array[String])
|
|
51
|
+
).returns(T.attached_class)
|
|
52
|
+
end
|
|
53
|
+
def self.new(
|
|
54
|
+
# Human-readable name for the routing strategy.
|
|
55
|
+
name:,
|
|
56
|
+
# Routing tree defining channel selection method and order.
|
|
57
|
+
routing:,
|
|
58
|
+
# Per-channel delivery configuration. Defaults to empty if omitted.
|
|
59
|
+
channels: nil,
|
|
60
|
+
# Optional description of the routing strategy.
|
|
61
|
+
description: nil,
|
|
62
|
+
# Per-provider delivery configuration. Defaults to empty if omitted.
|
|
63
|
+
providers: nil,
|
|
64
|
+
# Optional tags for categorization.
|
|
65
|
+
tags: nil
|
|
66
|
+
)
|
|
67
|
+
end
|
|
68
|
+
|
|
69
|
+
sig do
|
|
70
|
+
override.returns(
|
|
71
|
+
{
|
|
72
|
+
name: String,
|
|
73
|
+
routing: Courier::MessageRouting,
|
|
74
|
+
channels: T.nilable(T::Hash[Symbol, Courier::Channel]),
|
|
75
|
+
description: T.nilable(String),
|
|
76
|
+
providers:
|
|
77
|
+
T.nilable(T::Hash[Symbol, Courier::MessageProvidersType]),
|
|
78
|
+
tags: T.nilable(T::Array[String])
|
|
79
|
+
}
|
|
80
|
+
)
|
|
81
|
+
end
|
|
82
|
+
def to_hash
|
|
83
|
+
end
|
|
84
|
+
end
|
|
85
|
+
end
|
|
86
|
+
end
|
|
@@ -0,0 +1,121 @@
|
|
|
1
|
+
# typed: strong
|
|
2
|
+
|
|
3
|
+
module Courier
|
|
4
|
+
module Models
|
|
5
|
+
class RoutingStrategyGetResponse < Courier::Internal::Type::BaseModel
|
|
6
|
+
OrHash =
|
|
7
|
+
T.type_alias do
|
|
8
|
+
T.any(Courier::RoutingStrategyGetResponse, Courier::Internal::AnyHash)
|
|
9
|
+
end
|
|
10
|
+
|
|
11
|
+
# The routing strategy ID (rs\_ prefix).
|
|
12
|
+
sig { returns(String) }
|
|
13
|
+
attr_accessor :id
|
|
14
|
+
|
|
15
|
+
# Per-channel delivery configuration. May be empty.
|
|
16
|
+
sig { returns(T::Hash[Symbol, Courier::Channel]) }
|
|
17
|
+
attr_accessor :channels
|
|
18
|
+
|
|
19
|
+
# Epoch milliseconds when the strategy was created.
|
|
20
|
+
sig { returns(Integer) }
|
|
21
|
+
attr_accessor :created
|
|
22
|
+
|
|
23
|
+
# User ID of the creator.
|
|
24
|
+
sig { returns(String) }
|
|
25
|
+
attr_accessor :creator
|
|
26
|
+
|
|
27
|
+
# Human-readable name.
|
|
28
|
+
sig { returns(String) }
|
|
29
|
+
attr_accessor :name
|
|
30
|
+
|
|
31
|
+
# Per-provider delivery configuration. May be empty.
|
|
32
|
+
sig { returns(T::Hash[Symbol, Courier::MessageProvidersType]) }
|
|
33
|
+
attr_accessor :providers
|
|
34
|
+
|
|
35
|
+
# Routing tree defining channel selection method and order.
|
|
36
|
+
sig { returns(Courier::MessageRouting) }
|
|
37
|
+
attr_reader :routing
|
|
38
|
+
|
|
39
|
+
sig { params(routing: Courier::MessageRouting::OrHash).void }
|
|
40
|
+
attr_writer :routing
|
|
41
|
+
|
|
42
|
+
# Description of the routing strategy.
|
|
43
|
+
sig { returns(T.nilable(String)) }
|
|
44
|
+
attr_accessor :description
|
|
45
|
+
|
|
46
|
+
# Tags for categorization.
|
|
47
|
+
sig { returns(T.nilable(T::Array[String])) }
|
|
48
|
+
attr_accessor :tags
|
|
49
|
+
|
|
50
|
+
# Epoch milliseconds of last update.
|
|
51
|
+
sig { returns(T.nilable(Integer)) }
|
|
52
|
+
attr_accessor :updated
|
|
53
|
+
|
|
54
|
+
# User ID of the last updater.
|
|
55
|
+
sig { returns(T.nilable(String)) }
|
|
56
|
+
attr_accessor :updater
|
|
57
|
+
|
|
58
|
+
# Full routing strategy entity returned by GET.
|
|
59
|
+
sig do
|
|
60
|
+
params(
|
|
61
|
+
id: String,
|
|
62
|
+
channels: T::Hash[Symbol, Courier::Channel::OrHash],
|
|
63
|
+
created: Integer,
|
|
64
|
+
creator: String,
|
|
65
|
+
name: String,
|
|
66
|
+
providers: T::Hash[Symbol, Courier::MessageProvidersType::OrHash],
|
|
67
|
+
routing: Courier::MessageRouting::OrHash,
|
|
68
|
+
description: T.nilable(String),
|
|
69
|
+
tags: T.nilable(T::Array[String]),
|
|
70
|
+
updated: T.nilable(Integer),
|
|
71
|
+
updater: T.nilable(String)
|
|
72
|
+
).returns(T.attached_class)
|
|
73
|
+
end
|
|
74
|
+
def self.new(
|
|
75
|
+
# The routing strategy ID (rs\_ prefix).
|
|
76
|
+
id:,
|
|
77
|
+
# Per-channel delivery configuration. May be empty.
|
|
78
|
+
channels:,
|
|
79
|
+
# Epoch milliseconds when the strategy was created.
|
|
80
|
+
created:,
|
|
81
|
+
# User ID of the creator.
|
|
82
|
+
creator:,
|
|
83
|
+
# Human-readable name.
|
|
84
|
+
name:,
|
|
85
|
+
# Per-provider delivery configuration. May be empty.
|
|
86
|
+
providers:,
|
|
87
|
+
# Routing tree defining channel selection method and order.
|
|
88
|
+
routing:,
|
|
89
|
+
# Description of the routing strategy.
|
|
90
|
+
description: nil,
|
|
91
|
+
# Tags for categorization.
|
|
92
|
+
tags: nil,
|
|
93
|
+
# Epoch milliseconds of last update.
|
|
94
|
+
updated: nil,
|
|
95
|
+
# User ID of the last updater.
|
|
96
|
+
updater: nil
|
|
97
|
+
)
|
|
98
|
+
end
|
|
99
|
+
|
|
100
|
+
sig do
|
|
101
|
+
override.returns(
|
|
102
|
+
{
|
|
103
|
+
id: String,
|
|
104
|
+
channels: T::Hash[Symbol, Courier::Channel],
|
|
105
|
+
created: Integer,
|
|
106
|
+
creator: String,
|
|
107
|
+
name: String,
|
|
108
|
+
providers: T::Hash[Symbol, Courier::MessageProvidersType],
|
|
109
|
+
routing: Courier::MessageRouting,
|
|
110
|
+
description: T.nilable(String),
|
|
111
|
+
tags: T.nilable(T::Array[String]),
|
|
112
|
+
updated: T.nilable(Integer),
|
|
113
|
+
updater: T.nilable(String)
|
|
114
|
+
}
|
|
115
|
+
)
|
|
116
|
+
end
|
|
117
|
+
def to_hash
|
|
118
|
+
end
|
|
119
|
+
end
|
|
120
|
+
end
|
|
121
|
+
end
|
|
@@ -0,0 +1,54 @@
|
|
|
1
|
+
# typed: strong
|
|
2
|
+
|
|
3
|
+
module Courier
|
|
4
|
+
module Models
|
|
5
|
+
class RoutingStrategyListParams < Courier::Internal::Type::BaseModel
|
|
6
|
+
extend Courier::Internal::Type::RequestParameters::Converter
|
|
7
|
+
include Courier::Internal::Type::RequestParameters
|
|
8
|
+
|
|
9
|
+
OrHash =
|
|
10
|
+
T.type_alias do
|
|
11
|
+
T.any(Courier::RoutingStrategyListParams, Courier::Internal::AnyHash)
|
|
12
|
+
end
|
|
13
|
+
|
|
14
|
+
# Opaque pagination cursor from a previous response. Omit for the first page.
|
|
15
|
+
sig { returns(T.nilable(String)) }
|
|
16
|
+
attr_accessor :cursor
|
|
17
|
+
|
|
18
|
+
# Maximum number of results per page. Default 20, max 100.
|
|
19
|
+
sig { returns(T.nilable(Integer)) }
|
|
20
|
+
attr_reader :limit
|
|
21
|
+
|
|
22
|
+
sig { params(limit: Integer).void }
|
|
23
|
+
attr_writer :limit
|
|
24
|
+
|
|
25
|
+
sig do
|
|
26
|
+
params(
|
|
27
|
+
cursor: T.nilable(String),
|
|
28
|
+
limit: Integer,
|
|
29
|
+
request_options: Courier::RequestOptions::OrHash
|
|
30
|
+
).returns(T.attached_class)
|
|
31
|
+
end
|
|
32
|
+
def self.new(
|
|
33
|
+
# Opaque pagination cursor from a previous response. Omit for the first page.
|
|
34
|
+
cursor: nil,
|
|
35
|
+
# Maximum number of results per page. Default 20, max 100.
|
|
36
|
+
limit: nil,
|
|
37
|
+
request_options: {}
|
|
38
|
+
)
|
|
39
|
+
end
|
|
40
|
+
|
|
41
|
+
sig do
|
|
42
|
+
override.returns(
|
|
43
|
+
{
|
|
44
|
+
cursor: T.nilable(String),
|
|
45
|
+
limit: Integer,
|
|
46
|
+
request_options: Courier::RequestOptions
|
|
47
|
+
}
|
|
48
|
+
)
|
|
49
|
+
end
|
|
50
|
+
def to_hash
|
|
51
|
+
end
|
|
52
|
+
end
|
|
53
|
+
end
|
|
54
|
+
end
|
|
@@ -0,0 +1,45 @@
|
|
|
1
|
+
# typed: strong
|
|
2
|
+
|
|
3
|
+
module Courier
|
|
4
|
+
module Models
|
|
5
|
+
class RoutingStrategyListResponse < Courier::Internal::Type::BaseModel
|
|
6
|
+
OrHash =
|
|
7
|
+
T.type_alias do
|
|
8
|
+
T.any(
|
|
9
|
+
Courier::RoutingStrategyListResponse,
|
|
10
|
+
Courier::Internal::AnyHash
|
|
11
|
+
)
|
|
12
|
+
end
|
|
13
|
+
|
|
14
|
+
sig { returns(Courier::Paging) }
|
|
15
|
+
attr_reader :paging
|
|
16
|
+
|
|
17
|
+
sig { params(paging: Courier::Paging::OrHash).void }
|
|
18
|
+
attr_writer :paging
|
|
19
|
+
|
|
20
|
+
sig { returns(T::Array[Courier::RoutingStrategySummary]) }
|
|
21
|
+
attr_accessor :results
|
|
22
|
+
|
|
23
|
+
# Paginated list of routing strategy summaries.
|
|
24
|
+
sig do
|
|
25
|
+
params(
|
|
26
|
+
paging: Courier::Paging::OrHash,
|
|
27
|
+
results: T::Array[Courier::RoutingStrategySummary::OrHash]
|
|
28
|
+
).returns(T.attached_class)
|
|
29
|
+
end
|
|
30
|
+
def self.new(paging:, results:)
|
|
31
|
+
end
|
|
32
|
+
|
|
33
|
+
sig do
|
|
34
|
+
override.returns(
|
|
35
|
+
{
|
|
36
|
+
paging: Courier::Paging,
|
|
37
|
+
results: T::Array[Courier::RoutingStrategySummary]
|
|
38
|
+
}
|
|
39
|
+
)
|
|
40
|
+
end
|
|
41
|
+
def to_hash
|
|
42
|
+
end
|
|
43
|
+
end
|
|
44
|
+
end
|
|
45
|
+
end
|
|
@@ -0,0 +1,31 @@
|
|
|
1
|
+
# typed: strong
|
|
2
|
+
|
|
3
|
+
module Courier
|
|
4
|
+
module Models
|
|
5
|
+
class RoutingStrategyMutationResponse < Courier::Internal::Type::BaseModel
|
|
6
|
+
OrHash =
|
|
7
|
+
T.type_alias do
|
|
8
|
+
T.any(
|
|
9
|
+
Courier::RoutingStrategyMutationResponse,
|
|
10
|
+
Courier::Internal::AnyHash
|
|
11
|
+
)
|
|
12
|
+
end
|
|
13
|
+
|
|
14
|
+
# The routing strategy ID (rs\_ prefix).
|
|
15
|
+
sig { returns(String) }
|
|
16
|
+
attr_accessor :id
|
|
17
|
+
|
|
18
|
+
# Response returned by create and replace operations.
|
|
19
|
+
sig { params(id: String).returns(T.attached_class) }
|
|
20
|
+
def self.new(
|
|
21
|
+
# The routing strategy ID (rs\_ prefix).
|
|
22
|
+
id:
|
|
23
|
+
)
|
|
24
|
+
end
|
|
25
|
+
|
|
26
|
+
sig { override.returns({ id: String }) }
|
|
27
|
+
def to_hash
|
|
28
|
+
end
|
|
29
|
+
end
|
|
30
|
+
end
|
|
31
|
+
end
|
|
@@ -0,0 +1,38 @@
|
|
|
1
|
+
# typed: strong
|
|
2
|
+
|
|
3
|
+
module Courier
|
|
4
|
+
module Models
|
|
5
|
+
class RoutingStrategyReplaceParams < Courier::Models::RoutingStrategyReplaceRequest
|
|
6
|
+
extend Courier::Internal::Type::RequestParameters::Converter
|
|
7
|
+
include Courier::Internal::Type::RequestParameters
|
|
8
|
+
|
|
9
|
+
OrHash =
|
|
10
|
+
T.type_alias do
|
|
11
|
+
T.any(
|
|
12
|
+
Courier::RoutingStrategyReplaceParams,
|
|
13
|
+
Courier::Internal::AnyHash
|
|
14
|
+
)
|
|
15
|
+
end
|
|
16
|
+
|
|
17
|
+
sig { returns(String) }
|
|
18
|
+
attr_accessor :id
|
|
19
|
+
|
|
20
|
+
sig do
|
|
21
|
+
params(
|
|
22
|
+
id: String,
|
|
23
|
+
request_options: Courier::RequestOptions::OrHash
|
|
24
|
+
).returns(T.attached_class)
|
|
25
|
+
end
|
|
26
|
+
def self.new(id:, request_options: {})
|
|
27
|
+
end
|
|
28
|
+
|
|
29
|
+
sig do
|
|
30
|
+
override.returns(
|
|
31
|
+
{ id: String, request_options: Courier::RequestOptions }
|
|
32
|
+
)
|
|
33
|
+
end
|
|
34
|
+
def to_hash
|
|
35
|
+
end
|
|
36
|
+
end
|
|
37
|
+
end
|
|
38
|
+
end
|
|
@@ -0,0 +1,87 @@
|
|
|
1
|
+
# typed: strong
|
|
2
|
+
|
|
3
|
+
module Courier
|
|
4
|
+
module Models
|
|
5
|
+
class RoutingStrategyReplaceRequest < Courier::Internal::Type::BaseModel
|
|
6
|
+
OrHash =
|
|
7
|
+
T.type_alias do
|
|
8
|
+
T.any(
|
|
9
|
+
Courier::RoutingStrategyReplaceRequest,
|
|
10
|
+
Courier::Internal::AnyHash
|
|
11
|
+
)
|
|
12
|
+
end
|
|
13
|
+
|
|
14
|
+
# Human-readable name for the routing strategy.
|
|
15
|
+
sig { returns(String) }
|
|
16
|
+
attr_accessor :name
|
|
17
|
+
|
|
18
|
+
# Routing tree defining channel selection method and order.
|
|
19
|
+
sig { returns(Courier::MessageRouting) }
|
|
20
|
+
attr_reader :routing
|
|
21
|
+
|
|
22
|
+
sig { params(routing: Courier::MessageRouting::OrHash).void }
|
|
23
|
+
attr_writer :routing
|
|
24
|
+
|
|
25
|
+
# Per-channel delivery configuration. Omit to clear.
|
|
26
|
+
sig { returns(T.nilable(T::Hash[Symbol, Courier::Channel])) }
|
|
27
|
+
attr_accessor :channels
|
|
28
|
+
|
|
29
|
+
# Optional description. Omit or null to clear.
|
|
30
|
+
sig { returns(T.nilable(String)) }
|
|
31
|
+
attr_accessor :description
|
|
32
|
+
|
|
33
|
+
# Per-provider delivery configuration. Omit to clear.
|
|
34
|
+
sig { returns(T.nilable(T::Hash[Symbol, Courier::MessageProvidersType])) }
|
|
35
|
+
attr_accessor :providers
|
|
36
|
+
|
|
37
|
+
# Optional tags. Omit or null to clear.
|
|
38
|
+
sig { returns(T.nilable(T::Array[String])) }
|
|
39
|
+
attr_accessor :tags
|
|
40
|
+
|
|
41
|
+
# Request body for replacing a routing strategy. Full document replacement;
|
|
42
|
+
# missing optional fields are cleared.
|
|
43
|
+
sig do
|
|
44
|
+
params(
|
|
45
|
+
name: String,
|
|
46
|
+
routing: Courier::MessageRouting::OrHash,
|
|
47
|
+
channels: T.nilable(T::Hash[Symbol, Courier::Channel::OrHash]),
|
|
48
|
+
description: T.nilable(String),
|
|
49
|
+
providers:
|
|
50
|
+
T.nilable(T::Hash[Symbol, Courier::MessageProvidersType::OrHash]),
|
|
51
|
+
tags: T.nilable(T::Array[String])
|
|
52
|
+
).returns(T.attached_class)
|
|
53
|
+
end
|
|
54
|
+
def self.new(
|
|
55
|
+
# Human-readable name for the routing strategy.
|
|
56
|
+
name:,
|
|
57
|
+
# Routing tree defining channel selection method and order.
|
|
58
|
+
routing:,
|
|
59
|
+
# Per-channel delivery configuration. Omit to clear.
|
|
60
|
+
channels: nil,
|
|
61
|
+
# Optional description. Omit or null to clear.
|
|
62
|
+
description: nil,
|
|
63
|
+
# Per-provider delivery configuration. Omit to clear.
|
|
64
|
+
providers: nil,
|
|
65
|
+
# Optional tags. Omit or null to clear.
|
|
66
|
+
tags: nil
|
|
67
|
+
)
|
|
68
|
+
end
|
|
69
|
+
|
|
70
|
+
sig do
|
|
71
|
+
override.returns(
|
|
72
|
+
{
|
|
73
|
+
name: String,
|
|
74
|
+
routing: Courier::MessageRouting,
|
|
75
|
+
channels: T.nilable(T::Hash[Symbol, Courier::Channel]),
|
|
76
|
+
description: T.nilable(String),
|
|
77
|
+
providers:
|
|
78
|
+
T.nilable(T::Hash[Symbol, Courier::MessageProvidersType]),
|
|
79
|
+
tags: T.nilable(T::Array[String])
|
|
80
|
+
}
|
|
81
|
+
)
|
|
82
|
+
end
|
|
83
|
+
def to_hash
|
|
84
|
+
end
|
|
85
|
+
end
|
|
86
|
+
end
|
|
87
|
+
end
|
|
@@ -0,0 +1,38 @@
|
|
|
1
|
+
# typed: strong
|
|
2
|
+
|
|
3
|
+
module Courier
|
|
4
|
+
module Models
|
|
5
|
+
class RoutingStrategyRetrieveParams < Courier::Internal::Type::BaseModel
|
|
6
|
+
extend Courier::Internal::Type::RequestParameters::Converter
|
|
7
|
+
include Courier::Internal::Type::RequestParameters
|
|
8
|
+
|
|
9
|
+
OrHash =
|
|
10
|
+
T.type_alias do
|
|
11
|
+
T.any(
|
|
12
|
+
Courier::RoutingStrategyRetrieveParams,
|
|
13
|
+
Courier::Internal::AnyHash
|
|
14
|
+
)
|
|
15
|
+
end
|
|
16
|
+
|
|
17
|
+
sig { returns(String) }
|
|
18
|
+
attr_accessor :id
|
|
19
|
+
|
|
20
|
+
sig do
|
|
21
|
+
params(
|
|
22
|
+
id: String,
|
|
23
|
+
request_options: Courier::RequestOptions::OrHash
|
|
24
|
+
).returns(T.attached_class)
|
|
25
|
+
end
|
|
26
|
+
def self.new(id:, request_options: {})
|
|
27
|
+
end
|
|
28
|
+
|
|
29
|
+
sig do
|
|
30
|
+
override.returns(
|
|
31
|
+
{ id: String, request_options: Courier::RequestOptions }
|
|
32
|
+
)
|
|
33
|
+
end
|
|
34
|
+
def to_hash
|
|
35
|
+
end
|
|
36
|
+
end
|
|
37
|
+
end
|
|
38
|
+
end
|
|
@@ -0,0 +1,95 @@
|
|
|
1
|
+
# typed: strong
|
|
2
|
+
|
|
3
|
+
module Courier
|
|
4
|
+
module Models
|
|
5
|
+
class RoutingStrategySummary < Courier::Internal::Type::BaseModel
|
|
6
|
+
OrHash =
|
|
7
|
+
T.type_alias do
|
|
8
|
+
T.any(Courier::RoutingStrategySummary, Courier::Internal::AnyHash)
|
|
9
|
+
end
|
|
10
|
+
|
|
11
|
+
# The routing strategy ID (rs\_ prefix).
|
|
12
|
+
sig { returns(String) }
|
|
13
|
+
attr_accessor :id
|
|
14
|
+
|
|
15
|
+
# Epoch milliseconds when the strategy was created.
|
|
16
|
+
sig { returns(Integer) }
|
|
17
|
+
attr_accessor :created
|
|
18
|
+
|
|
19
|
+
# User ID of the creator.
|
|
20
|
+
sig { returns(String) }
|
|
21
|
+
attr_accessor :creator
|
|
22
|
+
|
|
23
|
+
# Human-readable name.
|
|
24
|
+
sig { returns(String) }
|
|
25
|
+
attr_accessor :name
|
|
26
|
+
|
|
27
|
+
# Description of the routing strategy.
|
|
28
|
+
sig { returns(T.nilable(String)) }
|
|
29
|
+
attr_accessor :description
|
|
30
|
+
|
|
31
|
+
# Tags for categorization.
|
|
32
|
+
sig { returns(T.nilable(T::Array[String])) }
|
|
33
|
+
attr_accessor :tags
|
|
34
|
+
|
|
35
|
+
# Epoch milliseconds of last update.
|
|
36
|
+
sig { returns(T.nilable(Integer)) }
|
|
37
|
+
attr_accessor :updated
|
|
38
|
+
|
|
39
|
+
# User ID of the last updater.
|
|
40
|
+
sig { returns(T.nilable(String)) }
|
|
41
|
+
attr_accessor :updater
|
|
42
|
+
|
|
43
|
+
# Routing strategy metadata returned in list responses. Does not include
|
|
44
|
+
# routing/channels/providers content.
|
|
45
|
+
sig do
|
|
46
|
+
params(
|
|
47
|
+
id: String,
|
|
48
|
+
created: Integer,
|
|
49
|
+
creator: String,
|
|
50
|
+
name: String,
|
|
51
|
+
description: T.nilable(String),
|
|
52
|
+
tags: T.nilable(T::Array[String]),
|
|
53
|
+
updated: T.nilable(Integer),
|
|
54
|
+
updater: T.nilable(String)
|
|
55
|
+
).returns(T.attached_class)
|
|
56
|
+
end
|
|
57
|
+
def self.new(
|
|
58
|
+
# The routing strategy ID (rs\_ prefix).
|
|
59
|
+
id:,
|
|
60
|
+
# Epoch milliseconds when the strategy was created.
|
|
61
|
+
created:,
|
|
62
|
+
# User ID of the creator.
|
|
63
|
+
creator:,
|
|
64
|
+
# Human-readable name.
|
|
65
|
+
name:,
|
|
66
|
+
# Description of the routing strategy.
|
|
67
|
+
description: nil,
|
|
68
|
+
# Tags for categorization.
|
|
69
|
+
tags: nil,
|
|
70
|
+
# Epoch milliseconds of last update.
|
|
71
|
+
updated: nil,
|
|
72
|
+
# User ID of the last updater.
|
|
73
|
+
updater: nil
|
|
74
|
+
)
|
|
75
|
+
end
|
|
76
|
+
|
|
77
|
+
sig do
|
|
78
|
+
override.returns(
|
|
79
|
+
{
|
|
80
|
+
id: String,
|
|
81
|
+
created: Integer,
|
|
82
|
+
creator: String,
|
|
83
|
+
name: String,
|
|
84
|
+
description: T.nilable(String),
|
|
85
|
+
tags: T.nilable(T::Array[String]),
|
|
86
|
+
updated: T.nilable(Integer),
|
|
87
|
+
updater: T.nilable(String)
|
|
88
|
+
}
|
|
89
|
+
)
|
|
90
|
+
end
|
|
91
|
+
def to_hash
|
|
92
|
+
end
|
|
93
|
+
end
|
|
94
|
+
end
|
|
95
|
+
end
|