brevo-python 4.0.1__py3-none-any.whl
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.
- brevo/__init__.py +2253 -0
- brevo/account/__init__.py +79 -0
- brevo/account/client.py +317 -0
- brevo/account/raw_client.py +341 -0
- brevo/account/types/__init__.py +77 -0
- brevo/account/types/get_account_activity_response.py +24 -0
- brevo/account/types/get_account_activity_response_logs_item.py +45 -0
- brevo/account/types/get_account_response.py +85 -0
- brevo/account/types/get_account_response_address.py +43 -0
- brevo/account/types/get_account_response_date_time_preferences.py +38 -0
- brevo/account/types/get_account_response_marketing_automation.py +29 -0
- brevo/account/types/get_account_response_plan_item.py +53 -0
- brevo/account/types/get_account_response_plan_item_type.py +5 -0
- brevo/account/types/get_account_response_plan_verticals_item.py +63 -0
- brevo/account/types/get_account_response_plan_verticals_item_plan_category.py +5 -0
- brevo/account/types/get_account_response_plan_verticals_item_status.py +5 -0
- brevo/account/types/get_account_response_plan_verticals_item_users.py +35 -0
- brevo/account/types/get_account_response_relay.py +34 -0
- brevo/account/types/get_account_response_relay_data.py +40 -0
- brevo/balance/__init__.py +139 -0
- brevo/balance/client.py +2589 -0
- brevo/balance/raw_client.py +4538 -0
- brevo/balance/types/__init__.py +169 -0
- brevo/balance/types/create_balance_limit_request_constraint_type.py +5 -0
- brevo/balance/types/create_balance_limit_request_duration_unit.py +5 -0
- brevo/balance/types/create_balance_limit_request_transaction_type.py +5 -0
- brevo/balance/types/create_balance_order_response.py +96 -0
- brevo/balance/types/get_balance_definition_list_request_sort.py +5 -0
- brevo/balance/types/get_balance_definition_list_request_sort_field.py +5 -0
- brevo/balance/types/get_balance_definition_list_request_version.py +5 -0
- brevo/balance/types/get_balance_definition_list_response.py +24 -0
- brevo/balance/types/get_balance_definition_request_version.py +5 -0
- brevo/balance/types/get_balance_limit_request_version.py +5 -0
- brevo/balance/types/get_contact_balances_response.py +30 -0
- brevo/balance/types/get_contact_balances_response_balances_item.py +33 -0
- brevo/balance/types/get_loyalty_balance_programs_pid_transaction_history_request_sort.py +5 -0
- brevo/balance/types/get_loyalty_balance_programs_pid_transaction_history_request_sort_field.py +7 -0
- brevo/balance/types/get_loyalty_balance_programs_pid_transaction_history_response.py +57 -0
- brevo/balance/types/get_loyalty_balance_programs_pid_transaction_history_response_transaction_history_item.py +77 -0
- brevo/balance/types/get_subscription_balances_response.py +21 -0
- brevo/balance/types/get_subscription_balances_response_balance_item.py +30 -0
- brevo/balance/types/post_loyalty_balance_programs_pid_balance_definitions_request_balance_availability_duration_modifier.py +7 -0
- brevo/balance/types/post_loyalty_balance_programs_pid_balance_definitions_request_balance_availability_duration_unit.py +7 -0
- brevo/balance/types/post_loyalty_balance_programs_pid_balance_definitions_request_balance_option_amount_overtaking_strategy.py +7 -0
- brevo/balance/types/post_loyalty_balance_programs_pid_balance_definitions_request_balance_option_credit_rounding.py +7 -0
- brevo/balance/types/post_loyalty_balance_programs_pid_balance_definitions_request_balance_option_debit_rounding.py +7 -0
- brevo/balance/types/post_loyalty_balance_programs_pid_balance_definitions_request_unit.py +26 -0
- brevo/balance/types/post_loyalty_balance_programs_pid_subscriptions_cid_balances_response.py +66 -0
- brevo/balance/types/update_balance_definition_request_balance_availability_duration_modifier.py +7 -0
- brevo/balance/types/update_balance_definition_request_balance_availability_duration_unit.py +7 -0
- brevo/balance/types/update_balance_definition_request_balance_option_amount_overtaking_strategy.py +7 -0
- brevo/balance/types/update_balance_definition_request_balance_option_credit_rounding.py +7 -0
- brevo/balance/types/update_balance_definition_request_balance_option_debit_rounding.py +7 -0
- brevo/balance/types/update_balance_definition_request_unit.py +26 -0
- brevo/balance/types/update_balance_limit_request_constraint_type.py +5 -0
- brevo/balance/types/update_balance_limit_request_duration_unit.py +5 -0
- brevo/balance/types/update_balance_limit_request_transaction_type.py +5 -0
- brevo/client.py +773 -0
- brevo/companies/__init__.py +61 -0
- brevo/companies/client.py +994 -0
- brevo/companies/raw_client.py +1285 -0
- brevo/companies/types/__init__.py +59 -0
- brevo/companies/types/get_companies_request_sort.py +5 -0
- brevo/companies/types/get_companies_response.py +28 -0
- brevo/companies/types/get_crm_attributes_companies_response_item.py +40 -0
- brevo/companies/types/post_companies_import_response.py +26 -0
- brevo/companies/types/post_companies_response.py +27 -0
- brevo/companies/types/post_crm_attributes_request_attribute_type.py +7 -0
- brevo/companies/types/post_crm_attributes_request_object_type.py +5 -0
- brevo/companies/types/post_crm_attributes_response.py +23 -0
- brevo/contacts/__init__.py +289 -0
- brevo/contacts/client.py +3298 -0
- brevo/contacts/raw_client.py +4614 -0
- brevo/contacts/types/__init__.py +309 -0
- brevo/contacts/types/add_contact_to_list_request_body.py +11 -0
- brevo/contacts/types/add_contact_to_list_request_body_emails.py +23 -0
- brevo/contacts/types/add_contact_to_list_request_body_ext_ids.py +29 -0
- brevo/contacts/types/add_contact_to_list_request_body_ids.py +23 -0
- brevo/contacts/types/create_attribute_request_attribute_category.py +7 -0
- brevo/contacts/types/create_attribute_request_enumeration_item.py +28 -0
- brevo/contacts/types/create_attribute_request_type.py +7 -0
- brevo/contacts/types/create_contact_request_attributes_value.py +5 -0
- brevo/contacts/types/create_contact_response.py +23 -0
- brevo/contacts/types/create_doi_contact_request_attributes_value.py +5 -0
- brevo/contacts/types/create_folder_response.py +23 -0
- brevo/contacts/types/create_list_response.py +23 -0
- brevo/contacts/types/delete_attribute_request_attribute_category.py +7 -0
- brevo/contacts/types/delete_contact_request_identifier.py +5 -0
- brevo/contacts/types/delete_contact_request_identifier_type.py +7 -0
- brevo/contacts/types/get_attributes_response.py +24 -0
- brevo/contacts/types/get_attributes_response_attributes_item.py +57 -0
- brevo/contacts/types/get_attributes_response_attributes_item_category.py +7 -0
- brevo/contacts/types/get_attributes_response_attributes_item_enumeration_item.py +28 -0
- brevo/contacts/types/get_attributes_response_attributes_item_type.py +7 -0
- brevo/contacts/types/get_contact_info_request_identifier.py +5 -0
- brevo/contacts/types/get_contact_info_request_identifier_type.py +7 -0
- brevo/contacts/types/get_contact_info_response.py +80 -0
- brevo/contacts/types/get_contact_info_response_attributes.py +22 -0
- brevo/contacts/types/get_contact_info_response_statistics.py +86 -0
- brevo/contacts/types/get_contact_info_response_statistics_clicked_item.py +33 -0
- brevo/contacts/types/get_contact_info_response_statistics_clicked_item_links_item.py +40 -0
- brevo/contacts/types/get_contact_info_response_statistics_complaints_item.py +31 -0
- brevo/contacts/types/get_contact_info_response_statistics_delivered_item.py +31 -0
- brevo/contacts/types/get_contact_info_response_statistics_hard_bounces_item.py +31 -0
- brevo/contacts/types/get_contact_info_response_statistics_messages_sent_item.py +31 -0
- brevo/contacts/types/get_contact_info_response_statistics_opened_item.py +40 -0
- brevo/contacts/types/get_contact_info_response_statistics_soft_bounces_item.py +31 -0
- brevo/contacts/types/get_contact_info_response_statistics_transac_attributes_item.py +18 -0
- brevo/contacts/types/get_contact_info_response_statistics_unsubscriptions.py +43 -0
- brevo/contacts/types/get_contact_info_response_statistics_unsubscriptions_admin_unsubscription_item.py +30 -0
- brevo/contacts/types/get_contact_info_response_statistics_unsubscriptions_user_unsubscription_item.py +35 -0
- brevo/contacts/types/get_contact_stats_request_identifier.py +5 -0
- brevo/contacts/types/get_contact_stats_response.py +59 -0
- brevo/contacts/types/get_contact_stats_response_clicked_item.py +28 -0
- brevo/contacts/types/get_contact_stats_response_clicked_item_links_item.py +40 -0
- brevo/contacts/types/get_contact_stats_response_complaints_item.py +31 -0
- brevo/contacts/types/get_contact_stats_response_delivered_item.py +31 -0
- brevo/contacts/types/get_contact_stats_response_hard_bounces_item.py +31 -0
- brevo/contacts/types/get_contact_stats_response_messages_sent_item.py +31 -0
- brevo/contacts/types/get_contact_stats_response_opened_item.py +40 -0
- brevo/contacts/types/get_contact_stats_response_soft_bounces_item.py +31 -0
- brevo/contacts/types/get_contact_stats_response_transac_attributes_item.py +31 -0
- brevo/contacts/types/get_contact_stats_response_unsubscriptions.py +39 -0
- brevo/contacts/types/get_contact_stats_response_unsubscriptions_admin_unsubscription_item.py +30 -0
- brevo/contacts/types/get_contact_stats_response_unsubscriptions_user_unsubscription_item.py +35 -0
- brevo/contacts/types/get_contacts_from_list_request_sort.py +5 -0
- brevo/contacts/types/get_contacts_request_sort.py +5 -0
- brevo/contacts/types/get_folder_lists_request_sort.py +5 -0
- brevo/contacts/types/get_folder_lists_response.py +26 -0
- brevo/contacts/types/get_folders_request_sort.py +5 -0
- brevo/contacts/types/get_folders_response.py +26 -0
- brevo/contacts/types/get_list_response.py +68 -0
- brevo/contacts/types/get_list_response_campaign_stats_item.py +26 -0
- brevo/contacts/types/get_lists_request_sort.py +5 -0
- brevo/contacts/types/get_lists_response.py +29 -0
- brevo/contacts/types/get_lists_response_lists_item.py +49 -0
- brevo/contacts/types/get_segments_request_sort.py +5 -0
- brevo/contacts/types/get_segments_response.py +29 -0
- brevo/contacts/types/get_segments_response_segments_item.py +41 -0
- brevo/contacts/types/import_contacts_request_json_body_item.py +25 -0
- brevo/contacts/types/import_contacts_request_new_list.py +41 -0
- brevo/contacts/types/import_contacts_response.py +26 -0
- brevo/contacts/types/remove_contact_from_list_request_body.py +15 -0
- brevo/contacts/types/remove_contact_from_list_request_body_all.py +29 -0
- brevo/contacts/types/remove_contact_from_list_request_body_emails.py +23 -0
- brevo/contacts/types/remove_contact_from_list_request_body_ext_ids.py +29 -0
- brevo/contacts/types/remove_contact_from_list_request_body_ids.py +23 -0
- brevo/contacts/types/request_contact_export_request_custom_contact_filter.py +90 -0
- brevo/contacts/types/request_contact_export_request_custom_contact_filter_action_for_contacts.py +7 -0
- brevo/contacts/types/request_contact_export_request_custom_contact_filter_action_for_email_campaigns.py +8 -0
- brevo/contacts/types/request_contact_export_request_custom_contact_filter_action_for_sms_campaigns.py +7 -0
- brevo/contacts/types/request_contact_export_response.py +26 -0
- brevo/contacts/types/update_attribute_request_attribute_category.py +7 -0
- brevo/contacts/types/update_attribute_request_enumeration_item.py +28 -0
- brevo/contacts/types/update_batch_contacts_request_contacts_item.py +80 -0
- brevo/contacts/types/update_contact_request_attributes_value.py +5 -0
- brevo/contacts/types/update_contact_request_identifier.py +5 -0
- brevo/contacts/types/update_contact_request_identifier_type.py +7 -0
- brevo/conversations/__init__.py +34 -0
- brevo/conversations/client.py +912 -0
- brevo/conversations/raw_client.py +1328 -0
- brevo/conversations/types/__init__.py +36 -0
- brevo/conversations/types/put_conversations_visitor_group_response.py +31 -0
- brevo/core/__init__.py +125 -0
- brevo/core/api_error.py +23 -0
- brevo/core/client_wrapper.py +100 -0
- brevo/core/datetime_utils.py +28 -0
- brevo/core/file.py +67 -0
- brevo/core/force_multipart.py +18 -0
- brevo/core/http_client.py +776 -0
- brevo/core/http_response.py +59 -0
- brevo/core/http_sse/__init__.py +42 -0
- brevo/core/http_sse/_api.py +112 -0
- brevo/core/http_sse/_decoders.py +61 -0
- brevo/core/http_sse/_exceptions.py +7 -0
- brevo/core/http_sse/_models.py +17 -0
- brevo/core/jsonable_encoder.py +108 -0
- brevo/core/logging.py +107 -0
- brevo/core/pydantic_utilities.py +577 -0
- brevo/core/query_encoder.py +58 -0
- brevo/core/remove_none_from_dict.py +11 -0
- brevo/core/request_options.py +35 -0
- brevo/core/serialization.py +276 -0
- brevo/core/unchecked_base_model.py +376 -0
- brevo/coupons/__init__.py +49 -0
- brevo/coupons/client.py +550 -0
- brevo/coupons/raw_client.py +839 -0
- brevo/coupons/types/__init__.py +47 -0
- brevo/coupons/types/create_coupon_collection_response.py +23 -0
- brevo/coupons/types/get_coupon_collections_request_sort.py +5 -0
- brevo/coupons/types/get_coupon_collections_request_sort_by.py +7 -0
- brevo/coupons/types/update_coupon_collection_response.py +35 -0
- brevo/custom_objects/__init__.py +139 -0
- brevo/custom_objects/client.py +437 -0
- brevo/custom_objects/raw_client.py +711 -0
- brevo/custom_objects/types/__init__.py +177 -0
- brevo/custom_objects/types/batch_delete_object_records_request_identifiers.py +10 -0
- brevo/custom_objects/types/batch_delete_object_records_request_identifiers_ext_ids.py +23 -0
- brevo/custom_objects/types/batch_delete_object_records_request_identifiers_ids.py +23 -0
- brevo/custom_objects/types/batch_delete_object_records_response.py +27 -0
- brevo/custom_objects/types/getrecords_request_association.py +5 -0
- brevo/custom_objects/types/getrecords_request_sort.py +5 -0
- brevo/custom_objects/types/getrecords_response.py +26 -0
- brevo/custom_objects/types/getrecords_response_records_item.py +51 -0
- brevo/custom_objects/types/getrecords_response_records_item_associations_item.py +10 -0
- brevo/custom_objects/types/getrecords_response_records_item_associations_item_one.py +28 -0
- brevo/custom_objects/types/getrecords_response_records_item_associations_item_one_records_item.py +15 -0
- brevo/custom_objects/types/getrecords_response_records_item_associations_item_one_records_item_one.py +28 -0
- brevo/custom_objects/types/getrecords_response_records_item_associations_item_one_records_item_one_identifiers.py +27 -0
- brevo/custom_objects/types/getrecords_response_records_item_associations_item_one_records_item_zero.py +28 -0
- brevo/custom_objects/types/getrecords_response_records_item_associations_item_one_records_item_zero_identifiers.py +27 -0
- brevo/custom_objects/types/getrecords_response_records_item_associations_item_zero.py +28 -0
- brevo/custom_objects/types/getrecords_response_records_item_associations_item_zero_records_item.py +15 -0
- brevo/custom_objects/types/getrecords_response_records_item_associations_item_zero_records_item_one.py +28 -0
- brevo/custom_objects/types/getrecords_response_records_item_associations_item_zero_records_item_one_identifiers.py +27 -0
- brevo/custom_objects/types/getrecords_response_records_item_associations_item_zero_records_item_zero.py +28 -0
- brevo/custom_objects/types/getrecords_response_records_item_associations_item_zero_records_item_zero_identifiers.py +27 -0
- brevo/custom_objects/types/getrecords_response_records_item_identifiers.py +32 -0
- brevo/custom_objects/types/upsertrecords_request_records_item.py +31 -0
- brevo/custom_objects/types/upsertrecords_request_records_item_associations_item.py +12 -0
- brevo/custom_objects/types/upsertrecords_request_records_item_associations_item_one.py +28 -0
- brevo/custom_objects/types/upsertrecords_request_records_item_associations_item_one_records_item.py +15 -0
- brevo/custom_objects/types/upsertrecords_request_records_item_associations_item_one_records_item_one.py +20 -0
- brevo/custom_objects/types/upsertrecords_request_records_item_associations_item_one_records_item_zero.py +28 -0
- brevo/custom_objects/types/upsertrecords_request_records_item_associations_item_one_records_item_zero_identifiers.py +32 -0
- brevo/custom_objects/types/upsertrecords_request_records_item_associations_item_zero.py +28 -0
- brevo/custom_objects/types/upsertrecords_request_records_item_associations_item_zero_records_item.py +23 -0
- brevo/custom_objects/types/upsertrecords_request_records_item_associations_item_zero_records_item_identifiers.py +28 -0
- brevo/custom_objects/types/upsertrecords_request_records_item_identifiers.py +32 -0
- brevo/custom_objects/types/upsertrecords_response.py +29 -0
- brevo/deals/__init__.py +52 -0
- brevo/deals/client.py +1013 -0
- brevo/deals/raw_client.py +1326 -0
- brevo/deals/types/__init__.py +50 -0
- brevo/deals/types/get_crm_attributes_deals_response_item.py +40 -0
- brevo/deals/types/get_crm_deals_request_sort.py +5 -0
- brevo/deals/types/get_crm_deals_response.py +28 -0
- brevo/deals/types/post_crm_deals_import_response.py +26 -0
- brevo/deals/types/post_crm_deals_response.py +27 -0
- brevo/domains/__init__.py +79 -0
- brevo/domains/client.py +506 -0
- brevo/domains/raw_client.py +698 -0
- brevo/domains/types/__init__.py +83 -0
- brevo/domains/types/authenticate_domain_response.py +28 -0
- brevo/domains/types/create_domain_response.py +44 -0
- brevo/domains/types/create_domain_response_dns_records.py +40 -0
- brevo/domains/types/create_domain_response_dns_records_brevo_code.py +42 -0
- brevo/domains/types/create_domain_response_dns_records_dkim_record.py +42 -0
- brevo/domains/types/create_domain_response_dns_records_dmarc_record.py +42 -0
- brevo/domains/types/get_domain_configuration_response.py +41 -0
- brevo/domains/types/get_domain_configuration_response_dns_records.py +44 -0
- brevo/domains/types/get_domain_configuration_response_dns_records_brevo_code.py +42 -0
- brevo/domains/types/get_domain_configuration_response_dns_records_dkim_record.py +42 -0
- brevo/domains/types/get_domain_configuration_response_dns_records_dmarc_record.py +42 -0
- brevo/domains/types/get_domains_response.py +39 -0
- brevo/domains/types/get_domains_response_domains_item.py +56 -0
- brevo/domains/types/get_domains_response_domains_item_creator.py +41 -0
- brevo/ecommerce/__init__.py +112 -0
- brevo/ecommerce/client.py +2176 -0
- brevo/ecommerce/raw_client.py +2895 -0
- brevo/ecommerce/types/__init__.py +124 -0
- brevo/ecommerce/types/create_batch_order_response.py +28 -0
- brevo/ecommerce/types/create_product_alert_request_contact_identifiers.py +33 -0
- brevo/ecommerce/types/create_update_batch_category_request_categories_item.py +48 -0
- brevo/ecommerce/types/create_update_batch_category_response.py +31 -0
- brevo/ecommerce/types/create_update_batch_products_request_products_item.py +89 -0
- brevo/ecommerce/types/create_update_batch_products_request_products_item_meta_info_value.py +5 -0
- brevo/ecommerce/types/create_update_batch_products_response.py +31 -0
- brevo/ecommerce/types/create_update_category_response.py +23 -0
- brevo/ecommerce/types/create_update_product_request_meta_info_value.py +5 -0
- brevo/ecommerce/types/create_update_product_response.py +23 -0
- brevo/ecommerce/types/get_categories_request_sort.py +5 -0
- brevo/ecommerce/types/get_categories_response.py +25 -0
- brevo/ecommerce/types/get_ecommerce_attribution_metrics_conversion_source_conversion_source_id_request_conversion_source.py +7 -0
- brevo/ecommerce/types/get_ecommerce_attribution_metrics_conversion_source_conversion_source_id_response.py +40 -0
- brevo/ecommerce/types/get_ecommerce_attribution_metrics_conversion_source_conversion_source_id_response_conversion_source.py +7 -0
- brevo/ecommerce/types/get_ecommerce_attribution_metrics_response.py +30 -0
- brevo/ecommerce/types/get_ecommerce_attribution_metrics_response_totals.py +32 -0
- brevo/ecommerce/types/get_ecommerce_attribution_products_conversion_source_conversion_source_id_request_conversion_source.py +7 -0
- brevo/ecommerce/types/get_ecommerce_attribution_products_conversion_source_conversion_source_id_response.py +28 -0
- brevo/ecommerce/types/get_ecommerce_attribution_products_conversion_source_conversion_source_id_response_products_item.py +33 -0
- brevo/ecommerce/types/get_ecommerce_config_display_currency_response.py +23 -0
- brevo/ecommerce/types/get_orders_request_sort.py +5 -0
- brevo/ecommerce/types/get_products_request_sort.py +5 -0
- brevo/ecommerce/types/get_products_response.py +26 -0
- brevo/ecommerce/types/set_config_display_currency_response.py +23 -0
- brevo/email_campaigns/__init__.py +139 -0
- brevo/email_campaigns/client.py +1864 -0
- brevo/email_campaigns/raw_client.py +2472 -0
- brevo/email_campaigns/types/__init__.py +141 -0
- brevo/email_campaigns/types/create_email_campaign_request_email_expiration_date.py +33 -0
- brevo/email_campaigns/types/create_email_campaign_request_email_expiration_date_unit.py +5 -0
- brevo/email_campaigns/types/create_email_campaign_request_recipients.py +52 -0
- brevo/email_campaigns/types/create_email_campaign_request_sender.py +37 -0
- brevo/email_campaigns/types/create_email_campaign_request_winner_criteria.py +5 -0
- brevo/email_campaigns/types/create_email_campaign_response.py +23 -0
- brevo/email_campaigns/types/email_export_recipients_request_recipients_type.py +10 -0
- brevo/email_campaigns/types/email_export_recipients_response.py +26 -0
- brevo/email_campaigns/types/get_ab_test_campaign_result_response.py +64 -0
- brevo/email_campaigns/types/get_ab_test_campaign_result_response_clicked_links.py +28 -0
- brevo/email_campaigns/types/get_ab_test_campaign_result_response_statistics.py +32 -0
- brevo/email_campaigns/types/get_ab_test_campaign_result_response_winning_criteria.py +5 -0
- brevo/email_campaigns/types/get_ab_test_campaign_result_response_winning_version.py +7 -0
- brevo/email_campaigns/types/get_email_campaign_request_statistics.py +7 -0
- brevo/email_campaigns/types/get_email_campaign_response.py +234 -0
- brevo/email_campaigns/types/get_email_campaign_response_sender.py +33 -0
- brevo/email_campaigns/types/get_email_campaign_response_status.py +7 -0
- brevo/email_campaigns/types/get_email_campaign_response_type.py +5 -0
- brevo/email_campaigns/types/get_email_campaigns_request_sort.py +5 -0
- brevo/email_campaigns/types/get_email_campaigns_request_statistics.py +7 -0
- brevo/email_campaigns/types/get_email_campaigns_request_status.py +7 -0
- brevo/email_campaigns/types/get_email_campaigns_request_type.py +5 -0
- brevo/email_campaigns/types/get_email_campaigns_response.py +25 -0
- brevo/email_campaigns/types/get_email_campaigns_response_campaigns_item.py +234 -0
- brevo/email_campaigns/types/get_email_campaigns_response_campaigns_item_sender.py +33 -0
- brevo/email_campaigns/types/get_email_campaigns_response_campaigns_item_status.py +7 -0
- brevo/email_campaigns/types/get_email_campaigns_response_campaigns_item_type.py +5 -0
- brevo/email_campaigns/types/get_shared_template_url_response.py +29 -0
- brevo/email_campaigns/types/update_email_campaign_request_email_expiration_date.py +33 -0
- brevo/email_campaigns/types/update_email_campaign_request_email_expiration_date_unit.py +5 -0
- brevo/email_campaigns/types/update_email_campaign_request_recipients.py +53 -0
- brevo/email_campaigns/types/update_email_campaign_request_sender.py +37 -0
- brevo/email_campaigns/types/update_email_campaign_request_winner_criteria.py +5 -0
- brevo/email_campaigns/types/upload_image_to_gallery_response.py +23 -0
- brevo/environment.py +7 -0
- brevo/errors/__init__.py +80 -0
- brevo/errors/bad_request_error.py +10 -0
- brevo/errors/conflict_error.py +11 -0
- brevo/errors/expectation_failed_error.py +11 -0
- brevo/errors/failed_dependency_error.py +10 -0
- brevo/errors/forbidden_error.py +10 -0
- brevo/errors/internal_server_error.py +10 -0
- brevo/errors/method_not_allowed_error.py +11 -0
- brevo/errors/not_found_error.py +10 -0
- brevo/errors/payment_required_error.py +11 -0
- brevo/errors/precondition_failed_error.py +11 -0
- brevo/errors/too_early_error.py +11 -0
- brevo/errors/too_many_requests_error.py +11 -0
- brevo/errors/unauthorized_error.py +10 -0
- brevo/errors/unprocessable_entity_error.py +11 -0
- brevo/errors/unsupported_media_type_error.py +11 -0
- brevo/event/__init__.py +52 -0
- brevo/event/client.py +184 -0
- brevo/event/raw_client.py +230 -0
- brevo/event/types/__init__.py +50 -0
- brevo/event/types/create_event_request_contact_properties_value.py +5 -0
- brevo/event/types/create_event_request_event_properties_value.py +5 -0
- brevo/event/types/create_event_request_identifiers.py +52 -0
- brevo/event/types/create_event_request_object.py +33 -0
- brevo/event/types/create_event_request_object_identifiers.py +32 -0
- brevo/external_feeds/__init__.py +79 -0
- brevo/external_feeds/client.py +915 -0
- brevo/external_feeds/raw_client.py +1087 -0
- brevo/external_feeds/types/__init__.py +77 -0
- brevo/external_feeds/types/create_external_feed_request_auth_type.py +5 -0
- brevo/external_feeds/types/create_external_feed_request_headers_item.py +28 -0
- brevo/external_feeds/types/create_external_feed_response.py +23 -0
- brevo/external_feeds/types/get_all_external_feeds_request_auth_type.py +5 -0
- brevo/external_feeds/types/get_all_external_feeds_request_sort.py +5 -0
- brevo/external_feeds/types/get_all_external_feeds_response.py +29 -0
- brevo/external_feeds/types/get_all_external_feeds_response_feeds_item.py +96 -0
- brevo/external_feeds/types/get_all_external_feeds_response_feeds_item_auth_type.py +5 -0
- brevo/external_feeds/types/get_all_external_feeds_response_feeds_item_headers_item.py +28 -0
- brevo/external_feeds/types/get_external_feed_by_uuid_response.py +105 -0
- brevo/external_feeds/types/get_external_feed_by_uuid_response_auth_type.py +5 -0
- brevo/external_feeds/types/get_external_feed_by_uuid_response_headers_item.py +28 -0
- brevo/external_feeds/types/update_external_feed_request_auth_type.py +5 -0
- brevo/external_feeds/types/update_external_feed_request_headers_item.py +28 -0
- brevo/files/__init__.py +38 -0
- brevo/files/client.py +479 -0
- brevo/files/raw_client.py +675 -0
- brevo/files/types/__init__.py +40 -0
- brevo/files/types/get_crm_files_id_response.py +30 -0
- brevo/files/types/get_crm_files_request_entity.py +5 -0
- brevo/files/types/get_crm_files_request_sort.py +5 -0
- brevo/inbound_parsing/__init__.py +58 -0
- brevo/inbound_parsing/client.py +323 -0
- brevo/inbound_parsing/raw_client.py +420 -0
- brevo/inbound_parsing/types/__init__.py +60 -0
- brevo/inbound_parsing/types/get_inbound_email_events_by_uuid_response.py +72 -0
- brevo/inbound_parsing/types/get_inbound_email_events_by_uuid_response_attachments_item.py +40 -0
- brevo/inbound_parsing/types/get_inbound_email_events_by_uuid_response_logs_item.py +30 -0
- brevo/inbound_parsing/types/get_inbound_email_events_by_uuid_response_logs_item_type.py +7 -0
- brevo/inbound_parsing/types/get_inbound_email_events_request_sort.py +5 -0
- brevo/inbound_parsing/types/get_inbound_email_events_response.py +21 -0
- brevo/inbound_parsing/types/get_inbound_email_events_response_events_item.py +42 -0
- brevo/master_account/__init__.py +202 -0
- brevo/master_account/client.py +2757 -0
- brevo/master_account/raw_client.py +3351 -0
- brevo/master_account/types/__init__.py +244 -0
- brevo/master_account/types/get_corporate_group_id_response.py +31 -0
- brevo/master_account/types/get_corporate_group_id_response_group.py +35 -0
- brevo/master_account/types/get_corporate_group_id_response_sub_accounts_item.py +35 -0
- brevo/master_account/types/get_corporate_group_id_response_users_item.py +36 -0
- brevo/master_account/types/get_corporate_invited_users_list_response.py +24 -0
- brevo/master_account/types/get_corporate_invited_users_list_response_users_item.py +50 -0
- brevo/master_account/types/get_corporate_invited_users_list_response_users_item_feature_access.py +69 -0
- brevo/master_account/types/get_corporate_invited_users_list_response_users_item_groups.py +32 -0
- brevo/master_account/types/get_corporate_ip_response_item.py +22 -0
- brevo/master_account/types/get_corporate_master_account_response.py +57 -0
- brevo/master_account/types/get_corporate_master_account_response_billing_info.py +48 -0
- brevo/master_account/types/get_corporate_master_account_response_billing_info_address.py +50 -0
- brevo/master_account/types/get_corporate_master_account_response_billing_info_name.py +35 -0
- brevo/master_account/types/get_corporate_master_account_response_plan_info.py +63 -0
- brevo/master_account/types/get_corporate_master_account_response_plan_info_features_item.py +62 -0
- brevo/master_account/types/get_corporate_master_account_response_plan_info_plan_period.py +5 -0
- brevo/master_account/types/get_corporate_sub_account_id_response.py +48 -0
- brevo/master_account/types/get_corporate_sub_account_id_response_groups_item.py +28 -0
- brevo/master_account/types/get_corporate_sub_account_id_response_plan_info.py +42 -0
- brevo/master_account/types/get_corporate_sub_account_id_response_plan_info_credits.py +65 -0
- brevo/master_account/types/get_corporate_sub_account_id_response_plan_info_credits_emails.py +32 -0
- brevo/master_account/types/get_corporate_sub_account_id_response_plan_info_credits_external_feeds.py +33 -0
- brevo/master_account/types/get_corporate_sub_account_id_response_plan_info_credits_sms.py +32 -0
- brevo/master_account/types/get_corporate_sub_account_id_response_plan_info_credits_whatsapp.py +32 -0
- brevo/master_account/types/get_corporate_sub_account_id_response_plan_info_credits_wp_subscribers.py +32 -0
- brevo/master_account/types/get_corporate_sub_account_id_response_plan_info_features.py +58 -0
- brevo/master_account/types/get_corporate_sub_account_id_response_plan_info_features_inbox.py +32 -0
- brevo/master_account/types/get_corporate_sub_account_id_response_plan_info_features_landing_page.py +32 -0
- brevo/master_account/types/get_corporate_sub_account_id_response_plan_info_features_sales_users.py +33 -0
- brevo/master_account/types/get_corporate_sub_account_id_response_plan_info_features_users.py +32 -0
- brevo/master_account/types/get_corporate_sub_account_response.py +32 -0
- brevo/master_account/types/get_corporate_sub_account_response_sub_accounts_item.py +48 -0
- brevo/master_account/types/get_corporate_sub_account_response_sub_accounts_item_groups_item.py +28 -0
- brevo/master_account/types/get_corporate_user_permission_response.py +40 -0
- brevo/master_account/types/get_corporate_user_permission_response_feature_access.py +62 -0
- brevo/master_account/types/get_corporate_user_permission_response_groups_item.py +32 -0
- brevo/master_account/types/get_sub_account_groups_response_item.py +30 -0
- brevo/master_account/types/invite_admin_user_request_privileges_item.py +38 -0
- brevo/master_account/types/invite_admin_user_request_privileges_item_feature.py +18 -0
- brevo/master_account/types/invite_admin_user_request_privileges_item_permissions_item.py +7 -0
- brevo/master_account/types/invite_admin_user_response.py +20 -0
- brevo/master_account/types/post_corporate_group_response.py +20 -0
- brevo/master_account/types/post_corporate_sub_account_key_response.py +28 -0
- brevo/master_account/types/post_corporate_sub_account_request_language.py +5 -0
- brevo/master_account/types/post_corporate_sub_account_response.py +23 -0
- brevo/master_account/types/post_corporate_sub_account_sso_token_request_target.py +17 -0
- brevo/master_account/types/put_corporate_sub_account_id_plan_request_credits.py +59 -0
- brevo/master_account/types/put_corporate_sub_account_id_plan_request_features.py +44 -0
- brevo/master_account/types/put_corporate_sub_accounts_plan_request_credits.py +59 -0
- brevo/master_account/types/put_corporate_sub_accounts_plan_request_features.py +39 -0
- brevo/master_account/types/put_corporate_user_email_permissions_request_privileges_item.py +42 -0
- brevo/master_account/types/put_corporate_user_email_permissions_request_privileges_item_feature.py +18 -0
- brevo/master_account/types/put_corporate_user_email_permissions_request_privileges_item_permissions_item.py +10 -0
- brevo/master_account/types/put_corporate_user_invitation_action_email_request_action.py +5 -0
- brevo/master_account/types/put_corporate_user_invitation_action_email_response.py +23 -0
- brevo/notes/__init__.py +38 -0
- brevo/notes/client.py +548 -0
- brevo/notes/raw_client.py +766 -0
- brevo/notes/types/__init__.py +40 -0
- brevo/notes/types/get_crm_notes_request_entity.py +5 -0
- brevo/notes/types/get_crm_notes_request_sort.py +5 -0
- brevo/notes/types/post_crm_notes_response.py +27 -0
- brevo/payments/__init__.py +38 -0
- brevo/payments/client.py +315 -0
- brevo/payments/raw_client.py +532 -0
- brevo/payments/types/__init__.py +40 -0
- brevo/payments/types/create_payment_request_response.py +28 -0
- brevo/payments/types/get_payment_request_response.py +47 -0
- brevo/payments/types/get_payment_request_response_status.py +5 -0
- brevo/process/__init__.py +79 -0
- brevo/process/client.py +304 -0
- brevo/process/raw_client.py +372 -0
- brevo/process/types/__init__.py +77 -0
- brevo/process/types/get_process_response.py +62 -0
- brevo/process/types/get_process_response_info.py +36 -0
- brevo/process/types/get_process_response_info_export.py +32 -0
- brevo/process/types/get_process_response_info_import.py +57 -0
- brevo/process/types/get_process_response_name.py +16 -0
- brevo/process/types/get_process_response_status.py +7 -0
- brevo/process/types/get_processes_request_sort.py +5 -0
- brevo/process/types/get_processes_response.py +29 -0
- brevo/process/types/get_processes_response_processes_item.py +62 -0
- brevo/process/types/get_processes_response_processes_item_info.py +36 -0
- brevo/process/types/get_processes_response_processes_item_info_export.py +32 -0
- brevo/process/types/get_processes_response_processes_item_info_import.py +57 -0
- brevo/process/types/get_processes_response_processes_item_name.py +16 -0
- brevo/process/types/get_processes_response_processes_item_status.py +7 -0
- brevo/program/__init__.py +67 -0
- brevo/program/client.py +1128 -0
- brevo/program/raw_client.py +2526 -0
- brevo/program/types/__init__.py +67 -0
- brevo/program/types/get_lp_list_request_sort_field.py +5 -0
- brevo/program/types/get_lp_list_response.py +24 -0
- brevo/program/types/get_parameter_subscription_info_response.py +44 -0
- brevo/program/types/get_parameter_subscription_info_response_balance.py +41 -0
- brevo/program/types/get_parameter_subscription_info_response_balance_balances_item.py +30 -0
- brevo/program/types/get_parameter_subscription_info_response_members_item.py +36 -0
- brevo/program/types/get_parameter_subscription_info_response_reward_item.py +66 -0
- brevo/program/types/get_parameter_subscription_info_response_tier_item.py +56 -0
- brevo/program/types/subscribe_member_to_a_subscription_response.py +46 -0
- brevo/program/types/subscribe_to_loyalty_program_response.py +56 -0
- brevo/py.typed +0 -0
- brevo/reward/__init__.py +115 -0
- brevo/reward/client.py +1285 -0
- brevo/reward/raw_client.py +2564 -0
- brevo/reward/types/__init__.py +139 -0
- brevo/reward/types/create_reward_response.py +64 -0
- brevo/reward/types/create_voucher_response.py +76 -0
- brevo/reward/types/get_code_count_response.py +23 -0
- brevo/reward/types/get_loyalty_offer_programs_pid_offers_request_version.py +5 -0
- brevo/reward/types/get_loyalty_offer_programs_pid_offers_response.py +34 -0
- brevo/reward/types/get_loyalty_offer_programs_pid_offers_response_items_item.py +67 -0
- brevo/reward/types/get_loyalty_offer_programs_pid_rewards_rid_request_version.py +5 -0
- brevo/reward/types/get_loyalty_offer_programs_pid_rewards_rid_response.py +269 -0
- brevo/reward/types/get_loyalty_offer_programs_pid_rewards_rid_response_expiration_modifier.py +7 -0
- brevo/reward/types/get_loyalty_offer_programs_pid_rewards_rid_response_generator.py +52 -0
- brevo/reward/types/get_loyalty_offer_programs_pid_rewards_rid_response_limits_item.py +68 -0
- brevo/reward/types/get_loyalty_offer_programs_pid_rewards_rid_response_products_item.py +40 -0
- brevo/reward/types/get_loyalty_offer_programs_pid_rewards_rid_response_reward_configs.py +33 -0
- brevo/reward/types/get_loyalty_offer_programs_pid_rewards_rid_response_rule.py +101 -0
- brevo/reward/types/get_loyalty_offer_programs_pid_rewards_rid_response_rule_event.py +28 -0
- brevo/reward/types/get_loyalty_offer_programs_pid_rewards_rid_response_rule_results_item.py +43 -0
- brevo/reward/types/get_loyalty_offer_programs_pid_rewards_rid_response_rule_results_item_parameters_item.py +37 -0
- brevo/reward/types/get_loyalty_offer_programs_pid_vouchers_request_sort.py +5 -0
- brevo/reward/types/get_loyalty_offer_programs_pid_vouchers_request_sort_field.py +5 -0
- brevo/reward/types/get_loyalty_offer_programs_pid_vouchers_response.py +49 -0
- brevo/reward/types/get_loyalty_offer_programs_pid_vouchers_response_contact_rewards_item.py +70 -0
- brevo/reward/types/redeem_voucher_request_order.py +85 -0
- brevo/reward/types/redeem_voucher_request_order_billing.py +55 -0
- brevo/reward/types/redeem_voucher_request_order_identifiers.py +28 -0
- brevo/reward/types/redeem_voucher_request_order_products_item.py +46 -0
- brevo/reward/types/validate_reward_response.py +23 -0
- brevo/senders/__init__.py +67 -0
- brevo/senders/client.py +808 -0
- brevo/senders/raw_client.py +1089 -0
- brevo/senders/types/__init__.py +65 -0
- brevo/senders/types/create_sender_request_ips_item.py +36 -0
- brevo/senders/types/create_sender_response.py +42 -0
- brevo/senders/types/get_ips_from_sender_response.py +25 -0
- brevo/senders/types/get_ips_from_sender_response_ips_item.py +38 -0
- brevo/senders/types/get_ips_response.py +25 -0
- brevo/senders/types/get_ips_response_ips_item.py +38 -0
- brevo/senders/types/get_senders_response.py +24 -0
- brevo/senders/types/get_senders_response_senders_item.py +46 -0
- brevo/senders/types/get_senders_response_senders_item_ips_item.py +33 -0
- brevo/senders/types/update_sender_request_ips_item.py +36 -0
- brevo/sms_campaigns/__init__.py +73 -0
- brevo/sms_campaigns/client.py +1078 -0
- brevo/sms_campaigns/raw_client.py +1501 -0
- brevo/sms_campaigns/types/__init__.py +71 -0
- brevo/sms_campaigns/types/create_sms_campaign_request_recipients.py +33 -0
- brevo/sms_campaigns/types/create_sms_campaign_response.py +23 -0
- brevo/sms_campaigns/types/get_sms_campaign_response.py +74 -0
- brevo/sms_campaigns/types/get_sms_campaign_response_status.py +7 -0
- brevo/sms_campaigns/types/get_sms_campaigns_request_sort.py +5 -0
- brevo/sms_campaigns/types/get_sms_campaigns_request_status.py +7 -0
- brevo/sms_campaigns/types/get_sms_campaigns_response.py +25 -0
- brevo/sms_campaigns/types/get_sms_campaigns_response_campaigns_item.py +74 -0
- brevo/sms_campaigns/types/get_sms_campaigns_response_campaigns_item_status.py +7 -0
- brevo/sms_campaigns/types/request_sms_recipient_export_request_recipients_type.py +7 -0
- brevo/sms_campaigns/types/request_sms_recipient_export_response.py +26 -0
- brevo/sms_campaigns/types/update_sms_campaign_request_recipients.py +33 -0
- brevo/sms_templates/__init__.py +49 -0
- brevo/sms_templates/client.py +133 -0
- brevo/sms_templates/raw_client.py +151 -0
- brevo/sms_templates/types/__init__.py +47 -0
- brevo/sms_templates/types/get_sms_templates_request_sort.py +5 -0
- brevo/sms_templates/types/get_sms_templates_response.py +26 -0
- brevo/sms_templates/types/get_sms_templates_response_templates_item.py +86 -0
- brevo/sms_templates/types/get_sms_templates_response_templates_item_compliance.py +37 -0
- brevo/tasks/__init__.py +55 -0
- brevo/tasks/client.py +814 -0
- brevo/tasks/raw_client.py +992 -0
- brevo/tasks/types/__init__.py +53 -0
- brevo/tasks/types/get_crm_tasks_request_filter_date.py +5 -0
- brevo/tasks/types/get_crm_tasks_request_filter_status.py +5 -0
- brevo/tasks/types/get_crm_tasks_request_sort.py +5 -0
- brevo/tasks/types/get_crm_tasks_response.py +28 -0
- brevo/tasks/types/get_crm_tasktypes_response.py +32 -0
- brevo/tasks/types/post_crm_tasks_response.py +27 -0
- brevo/tier/__init__.py +79 -0
- brevo/tier/client.py +1144 -0
- brevo/tier/raw_client.py +2360 -0
- brevo/tier/types/__init__.py +79 -0
- brevo/tier/types/add_subscription_to_tier_response.py +53 -0
- brevo/tier/types/create_tier_for_tier_group_request_access_conditions_item.py +31 -0
- brevo/tier/types/create_tier_for_tier_group_request_tier_rewards_item.py +26 -0
- brevo/tier/types/create_tier_group_request_downgrade_strategy.py +7 -0
- brevo/tier/types/create_tier_group_request_upgrade_strategy.py +7 -0
- brevo/tier/types/get_list_of_tier_groups_request_version.py +5 -0
- brevo/tier/types/get_list_of_tier_groups_response.py +21 -0
- brevo/tier/types/get_loyalty_program_tier_request_version.py +5 -0
- brevo/tier/types/get_loyalty_program_tier_response.py +21 -0
- brevo/tier/types/get_tier_group_request_version.py +5 -0
- brevo/tier/types/update_tier_group_request_downgrade_strategy.py +7 -0
- brevo/tier/types/update_tier_group_request_upgrade_strategy.py +7 -0
- brevo/tier/types/update_tier_request_access_conditions_item.py +31 -0
- brevo/tier/types/update_tier_request_tier_rewards_item.py +26 -0
- brevo/transactional_emails/__init__.py +175 -0
- brevo/transactional_emails/client.py +2544 -0
- brevo/transactional_emails/raw_client.py +3240 -0
- brevo/transactional_emails/types/__init__.py +189 -0
- brevo/transactional_emails/types/create_smtp_template_request_sender.py +37 -0
- brevo/transactional_emails/types/create_smtp_template_response.py +23 -0
- brevo/transactional_emails/types/get_aggregated_smtp_report_response.py +85 -0
- brevo/transactional_emails/types/get_blocked_domains_response.py +23 -0
- brevo/transactional_emails/types/get_email_event_report_request_event.py +23 -0
- brevo/transactional_emails/types/get_email_event_report_request_sort.py +5 -0
- brevo/transactional_emails/types/get_email_event_report_response.py +21 -0
- brevo/transactional_emails/types/get_email_event_report_response_events_item.py +79 -0
- brevo/transactional_emails/types/get_email_event_report_response_events_item_event.py +23 -0
- brevo/transactional_emails/types/get_scheduled_email_by_id_request_sort.py +5 -0
- brevo/transactional_emails/types/get_scheduled_email_by_id_request_status.py +5 -0
- brevo/transactional_emails/types/get_scheduled_email_by_id_response.py +10 -0
- brevo/transactional_emails/types/get_scheduled_email_by_id_response_batches.py +25 -0
- brevo/transactional_emails/types/get_scheduled_email_by_id_response_batches_batches_item.py +39 -0
- brevo/transactional_emails/types/get_scheduled_email_by_id_response_batches_batches_item_status.py +7 -0
- brevo/transactional_emails/types/get_scheduled_email_by_id_response_created_at.py +37 -0
- brevo/transactional_emails/types/get_scheduled_email_by_id_response_created_at_status.py +7 -0
- brevo/transactional_emails/types/get_smtp_report_request_sort.py +5 -0
- brevo/transactional_emails/types/get_smtp_report_response.py +21 -0
- brevo/transactional_emails/types/get_smtp_report_response_reports_item.py +86 -0
- brevo/transactional_emails/types/get_smtp_templates_request_sort.py +5 -0
- brevo/transactional_emails/types/get_smtp_templates_response.py +26 -0
- brevo/transactional_emails/types/get_transac_blocked_contacts_request_sort.py +5 -0
- brevo/transactional_emails/types/get_transac_blocked_contacts_response.py +25 -0
- brevo/transactional_emails/types/get_transac_blocked_contacts_response_contacts_item.py +44 -0
- brevo/transactional_emails/types/get_transac_blocked_contacts_response_contacts_item_reason.py +35 -0
- brevo/transactional_emails/types/get_transac_blocked_contacts_response_contacts_item_reason_code.py +15 -0
- brevo/transactional_emails/types/get_transac_email_content_response.py +57 -0
- brevo/transactional_emails/types/get_transac_email_content_response_events_item.py +28 -0
- brevo/transactional_emails/types/get_transac_emails_list_request_sort.py +5 -0
- brevo/transactional_emails/types/get_transac_emails_list_response.py +34 -0
- brevo/transactional_emails/types/get_transac_emails_list_response_transactional_emails_item.py +61 -0
- brevo/transactional_emails/types/post_preview_smtp_email_templates_response.py +49 -0
- brevo/transactional_emails/types/send_transac_email_request_attachment_item.py +33 -0
- brevo/transactional_emails/types/send_transac_email_request_bcc_item.py +28 -0
- brevo/transactional_emails/types/send_transac_email_request_cc_item.py +28 -0
- brevo/transactional_emails/types/send_transac_email_request_message_versions_item.py +73 -0
- brevo/transactional_emails/types/send_transac_email_request_message_versions_item_bcc_item.py +28 -0
- brevo/transactional_emails/types/send_transac_email_request_message_versions_item_cc_item.py +28 -0
- brevo/transactional_emails/types/send_transac_email_request_message_versions_item_reply_to.py +32 -0
- brevo/transactional_emails/types/send_transac_email_request_message_versions_item_to_item.py +28 -0
- brevo/transactional_emails/types/send_transac_email_request_reply_to.py +32 -0
- brevo/transactional_emails/types/send_transac_email_request_sender.py +37 -0
- brevo/transactional_emails/types/send_transac_email_request_to_item.py +28 -0
- brevo/transactional_emails/types/send_transac_email_response.py +29 -0
- brevo/transactional_emails/types/update_smtp_template_request_sender.py +37 -0
- brevo/transactional_sms/__init__.py +70 -0
- brevo/transactional_sms/client.py +726 -0
- brevo/transactional_sms/raw_client.py +913 -0
- brevo/transactional_sms/types/__init__.py +68 -0
- brevo/transactional_sms/types/get_sms_events_request_event.py +20 -0
- brevo/transactional_sms/types/get_sms_events_request_sort.py +5 -0
- brevo/transactional_sms/types/get_sms_events_response.py +21 -0
- brevo/transactional_sms/types/get_sms_events_response_events_item.py +52 -0
- brevo/transactional_sms/types/get_sms_events_response_events_item_event.py +20 -0
- brevo/transactional_sms/types/get_transac_aggregated_sms_report_response.py +75 -0
- brevo/transactional_sms/types/get_transac_sms_report_request_sort.py +5 -0
- brevo/transactional_sms/types/get_transac_sms_report_response.py +21 -0
- brevo/transactional_sms/types/get_transac_sms_report_response_reports_item.py +76 -0
- brevo/transactional_sms/types/send_async_transactional_sms_response.py +22 -0
- brevo/transactional_sms/types/send_transac_sms_response.py +38 -0
- brevo/transactional_whats_app/__init__.py +64 -0
- brevo/transactional_whats_app/client.py +283 -0
- brevo/transactional_whats_app/raw_client.py +326 -0
- brevo/transactional_whats_app/types/__init__.py +62 -0
- brevo/transactional_whats_app/types/get_whatsapp_event_report_request_event.py +7 -0
- brevo/transactional_whats_app/types/get_whatsapp_event_report_request_sort.py +5 -0
- brevo/transactional_whats_app/types/get_whatsapp_event_report_response.py +21 -0
- brevo/transactional_whats_app/types/get_whatsapp_event_report_response_events_item.py +65 -0
- brevo/transactional_whats_app/types/get_whatsapp_event_report_response_events_item_event.py +7 -0
- brevo/transactional_whats_app/types/send_whatsapp_message_request.py +8 -0
- brevo/transactional_whats_app/types/send_whatsapp_message_request_params.py +41 -0
- brevo/transactional_whats_app/types/send_whatsapp_message_request_text.py +35 -0
- brevo/transactional_whats_app/types/send_whatsapp_message_response.py +26 -0
- brevo/types/__init__.py +373 -0
- brevo/types/ab_test_version_clicks.py +7 -0
- brevo/types/ab_test_version_clicks_item.py +35 -0
- brevo/types/ab_test_version_stats.py +35 -0
- brevo/types/bad_request_error_body.py +29 -0
- brevo/types/bad_request_error_body_code.py +45 -0
- brevo/types/balance_definition.py +139 -0
- brevo/types/balance_definition_balance_availability_duration_modifier.py +7 -0
- brevo/types/balance_limit.py +78 -0
- brevo/types/cart.py +38 -0
- brevo/types/company.py +45 -0
- brevo/types/configuration.py +30 -0
- brevo/types/contact_error_model.py +34 -0
- brevo/types/contact_error_model_code.py +16 -0
- brevo/types/conversations_message.py +187 -0
- brevo/types/conversations_message_attachments_item.py +50 -0
- brevo/types/conversations_message_bcc_item.py +21 -0
- brevo/types/conversations_message_cc_item.py +21 -0
- brevo/types/conversations_message_file.py +46 -0
- brevo/types/conversations_message_file_image_info.py +39 -0
- brevo/types/conversations_message_forwarded_to_source_status.py +29 -0
- brevo/types/conversations_message_from.py +25 -0
- brevo/types/conversations_message_reply_to.py +25 -0
- brevo/types/conversations_message_to_item.py +21 -0
- brevo/types/conversations_message_type.py +5 -0
- brevo/types/conversion_source_metrics.py +35 -0
- brevo/types/conversion_source_metrics_conversion_source.py +7 -0
- brevo/types/create_update_folder.py +23 -0
- brevo/types/deal.py +45 -0
- brevo/types/error_model.py +28 -0
- brevo/types/file_data.py +60 -0
- brevo/types/forbidden_error_body.py +29 -0
- brevo/types/forbidden_error_body_code.py +45 -0
- brevo/types/get_campaign_recipients.py +25 -0
- brevo/types/get_campaign_stats.py +130 -0
- brevo/types/get_category_details.py +54 -0
- brevo/types/get_contact_details.py +75 -0
- brevo/types/get_contact_details_attributes.py +22 -0
- brevo/types/get_contacts.py +25 -0
- brevo/types/get_coupon_collection.py +75 -0
- brevo/types/get_device_browser_stats.py +44 -0
- brevo/types/get_extended_campaign_overview.py +230 -0
- brevo/types/get_extended_campaign_overview_sender.py +33 -0
- brevo/types/get_extended_campaign_overview_status.py +7 -0
- brevo/types/get_extended_campaign_overview_type.py +5 -0
- brevo/types/get_extended_campaign_stats.py +63 -0
- brevo/types/get_extended_campaign_stats_links_stats.py +22 -0
- brevo/types/get_extended_campaign_stats_stats_by_device.py +39 -0
- brevo/types/get_folder.py +46 -0
- brevo/types/get_list.py +46 -0
- brevo/types/get_product_details.py +115 -0
- brevo/types/get_sms_campaign_overview.py +69 -0
- brevo/types/get_sms_campaign_overview_status.py +7 -0
- brevo/types/get_sms_campaign_stats.py +55 -0
- brevo/types/get_smtp_template_overview.py +93 -0
- brevo/types/get_smtp_template_overview_sender.py +33 -0
- brevo/types/get_sso_token.py +23 -0
- brevo/types/get_webhook.py +74 -0
- brevo/types/get_webhook_channel.py +5 -0
- brevo/types/get_webhook_type.py +5 -0
- brevo/types/inviteuser.py +31 -0
- brevo/types/inviteuser_privileges_item.py +34 -0
- brevo/types/inviteuser_privileges_item_feature.py +24 -0
- brevo/types/inviteuser_privileges_item_permissions_item.py +39 -0
- brevo/types/loyalty_program.py +82 -0
- brevo/types/loyalty_program_state.py +5 -0
- brevo/types/node_response.py +63 -0
- brevo/types/not_found_error_body.py +29 -0
- brevo/types/not_found_error_body_code.py +45 -0
- brevo/types/note.py +61 -0
- brevo/types/note_data.py +44 -0
- brevo/types/notification.py +32 -0
- brevo/types/order.py +85 -0
- brevo/types/order_billing.py +66 -0
- brevo/types/order_identifiers.py +42 -0
- brevo/types/order_meta_info_value.py +5 -0
- brevo/types/order_products_item.py +43 -0
- brevo/types/pipeline.py +38 -0
- brevo/types/pipeline_stages_item.py +32 -0
- brevo/types/pipelines.py +7 -0
- brevo/types/post_contact_info.py +21 -0
- brevo/types/post_contact_info_contacts.py +37 -0
- brevo/types/post_contact_info_contacts_failure.py +5 -0
- brevo/types/post_contact_info_contacts_success.py +5 -0
- brevo/types/post_send_failed.py +46 -0
- brevo/types/redeem.py +92 -0
- brevo/types/rule_condition_response.py +52 -0
- brevo/types/send_report.py +30 -0
- brevo/types/send_report_email.py +32 -0
- brevo/types/send_report_language.py +5 -0
- brevo/types/send_test_email.py +29 -0
- brevo/types/send_transac_sms.py +66 -0
- brevo/types/send_transac_sms_tag.py +28 -0
- brevo/types/send_transac_sms_tag_field.py +5 -0
- brevo/types/send_transac_sms_type.py +5 -0
- brevo/types/task.py +55 -0
- brevo/types/task_reminder.py +39 -0
- brevo/types/task_reminder_types_item.py +5 -0
- brevo/types/task_reminder_unit.py +5 -0
- brevo/types/tier.py +63 -0
- brevo/types/tier_access_conditions_item.py +38 -0
- brevo/types/tier_group.py +70 -0
- brevo/types/tier_group_downgrade_strategy.py +7 -0
- brevo/types/tier_group_upgrade_strategy.py +7 -0
- brevo/types/tier_tier_rewards_item.py +33 -0
- brevo/types/transaction.py +110 -0
- brevo/types/unauthorized_error_body.py +29 -0
- brevo/types/unauthorized_error_body_code.py +45 -0
- brevo/types/update_campaign_status.py +28 -0
- brevo/types/update_campaign_status_status.py +8 -0
- brevo/types/value_response.py +67 -0
- brevo/types/variables_items.py +22 -0
- brevo/types/whatsapp_camp_stats.py +26 -0
- brevo/user/__init__.py +67 -0
- brevo/user/client.py +806 -0
- brevo/user/raw_client.py +977 -0
- brevo/user/types/__init__.py +67 -0
- brevo/user/types/edit_user_permission_response.py +33 -0
- brevo/user/types/get_invited_users_list_response.py +24 -0
- brevo/user/types/get_invited_users_list_response_users_item.py +39 -0
- brevo/user/types/get_invited_users_list_response_users_item_feature_access.py +37 -0
- brevo/user/types/get_user_permission_response.py +38 -0
- brevo/user/types/get_user_permission_response_privileges_item.py +21 -0
- brevo/user/types/inviteuser_response.py +28 -0
- brevo/user/types/put_revoke_user_permission_response.py +28 -0
- brevo/user/types/putresendcancelinvitation_request_action.py +5 -0
- brevo/user/types/putresendcancelinvitation_response.py +28 -0
- brevo/version.py +3 -0
- brevo/webhooks/__init__.py +82 -0
- brevo/webhooks/client.py +982 -0
- brevo/webhooks/raw_client.py +1211 -0
- brevo/webhooks/types/__init__.py +80 -0
- brevo/webhooks/types/create_webhook_request_auth.py +32 -0
- brevo/webhooks/types/create_webhook_request_channel.py +5 -0
- brevo/webhooks/types/create_webhook_request_events_item.py +26 -0
- brevo/webhooks/types/create_webhook_request_headers_item.py +28 -0
- brevo/webhooks/types/create_webhook_request_type.py +5 -0
- brevo/webhooks/types/create_webhook_response.py +23 -0
- brevo/webhooks/types/export_webhooks_history_request_event.py +26 -0
- brevo/webhooks/types/export_webhooks_history_request_type.py +5 -0
- brevo/webhooks/types/export_webhooks_history_response.py +26 -0
- brevo/webhooks/types/get_webhooks_request_sort.py +5 -0
- brevo/webhooks/types/get_webhooks_request_type.py +5 -0
- brevo/webhooks/types/get_webhooks_response.py +21 -0
- brevo/webhooks/types/update_webhook_request_auth.py +32 -0
- brevo/webhooks/types/update_webhook_request_events_item.py +26 -0
- brevo/webhooks/types/update_webhook_request_headers_item.py +28 -0
- brevo/whats_app_campaigns/__init__.py +106 -0
- brevo/whats_app_campaigns/client.py +1064 -0
- brevo/whats_app_campaigns/raw_client.py +1311 -0
- brevo/whats_app_campaigns/types/__init__.py +110 -0
- brevo/whats_app_campaigns/types/create_whats_app_campaign_request_recipients.py +41 -0
- brevo/whats_app_campaigns/types/create_whats_app_campaign_response.py +23 -0
- brevo/whats_app_campaigns/types/create_whats_app_template_request_category.py +5 -0
- brevo/whats_app_campaigns/types/create_whats_app_template_request_source.py +5 -0
- brevo/whats_app_campaigns/types/create_whats_app_template_response.py +23 -0
- brevo/whats_app_campaigns/types/get_whats_app_campaign_response.py +69 -0
- brevo/whats_app_campaigns/types/get_whats_app_campaign_response_campaign_status.py +7 -0
- brevo/whats_app_campaigns/types/get_whats_app_campaign_response_template.py +61 -0
- brevo/whats_app_campaigns/types/get_whats_app_campaign_response_template_components_item.py +21 -0
- brevo/whats_app_campaigns/types/get_whats_app_campaigns_request_sort.py +5 -0
- brevo/whats_app_campaigns/types/get_whats_app_campaigns_response.py +25 -0
- brevo/whats_app_campaigns/types/get_whats_app_campaigns_response_campaigns_item.py +84 -0
- brevo/whats_app_campaigns/types/get_whats_app_campaigns_response_campaigns_item_campaign_status.py +7 -0
- brevo/whats_app_campaigns/types/get_whats_app_config_response.py +63 -0
- brevo/whats_app_campaigns/types/get_whats_app_config_response_phone_number_name_status.py +7 -0
- brevo/whats_app_campaigns/types/get_whats_app_config_response_phone_number_quality.py +5 -0
- brevo/whats_app_campaigns/types/get_whats_app_config_response_whatsapp_business_account_status.py +7 -0
- brevo/whats_app_campaigns/types/get_whats_app_templates_request_sort.py +5 -0
- brevo/whats_app_campaigns/types/get_whats_app_templates_request_source.py +5 -0
- brevo/whats_app_campaigns/types/get_whats_app_templates_response.py +26 -0
- brevo/whats_app_campaigns/types/get_whats_app_templates_response_templates_item.py +65 -0
- brevo/whats_app_campaigns/types/update_whats_app_campaign_request_campaign_status.py +5 -0
- brevo/whats_app_campaigns/types/update_whats_app_campaign_request_recipients.py +41 -0
- brevo_python-4.0.1.dist-info/METADATA +1072 -0
- brevo_python-4.0.1.dist-info/RECORD +843 -0
- brevo_python-4.0.1.dist-info/WHEEL +4 -0
|
@@ -0,0 +1,2176 @@
|
|
|
1
|
+
# This file was auto-generated by Fern from our API Definition.
|
|
2
|
+
|
|
3
|
+
import datetime as dt
|
|
4
|
+
import typing
|
|
5
|
+
|
|
6
|
+
from ..core.client_wrapper import AsyncClientWrapper, SyncClientWrapper
|
|
7
|
+
from ..core.request_options import RequestOptions
|
|
8
|
+
from ..types.get_category_details import GetCategoryDetails
|
|
9
|
+
from ..types.get_product_details import GetProductDetails
|
|
10
|
+
from ..types.order import Order
|
|
11
|
+
from ..types.order_billing import OrderBilling
|
|
12
|
+
from ..types.order_identifiers import OrderIdentifiers
|
|
13
|
+
from ..types.order_meta_info_value import OrderMetaInfoValue
|
|
14
|
+
from ..types.order_products_item import OrderProductsItem
|
|
15
|
+
from .raw_client import AsyncRawEcommerceClient, RawEcommerceClient
|
|
16
|
+
from .types.create_batch_order_response import CreateBatchOrderResponse
|
|
17
|
+
from .types.create_product_alert_request_contact_identifiers import CreateProductAlertRequestContactIdentifiers
|
|
18
|
+
from .types.create_update_batch_category_request_categories_item import CreateUpdateBatchCategoryRequestCategoriesItem
|
|
19
|
+
from .types.create_update_batch_category_response import CreateUpdateBatchCategoryResponse
|
|
20
|
+
from .types.create_update_batch_products_request_products_item import CreateUpdateBatchProductsRequestProductsItem
|
|
21
|
+
from .types.create_update_batch_products_response import CreateUpdateBatchProductsResponse
|
|
22
|
+
from .types.create_update_category_response import CreateUpdateCategoryResponse
|
|
23
|
+
from .types.create_update_product_request_meta_info_value import CreateUpdateProductRequestMetaInfoValue
|
|
24
|
+
from .types.create_update_product_response import CreateUpdateProductResponse
|
|
25
|
+
from .types.get_categories_request_sort import GetCategoriesRequestSort
|
|
26
|
+
from .types.get_categories_response import GetCategoriesResponse
|
|
27
|
+
from .types.get_ecommerce_attribution_metrics_conversion_source_conversion_source_id_request_conversion_source import (
|
|
28
|
+
GetEcommerceAttributionMetricsConversionSourceConversionSourceIdRequestConversionSource,
|
|
29
|
+
)
|
|
30
|
+
from .types.get_ecommerce_attribution_metrics_conversion_source_conversion_source_id_response import (
|
|
31
|
+
GetEcommerceAttributionMetricsConversionSourceConversionSourceIdResponse,
|
|
32
|
+
)
|
|
33
|
+
from .types.get_ecommerce_attribution_metrics_response import GetEcommerceAttributionMetricsResponse
|
|
34
|
+
from .types.get_ecommerce_attribution_products_conversion_source_conversion_source_id_request_conversion_source import (
|
|
35
|
+
GetEcommerceAttributionProductsConversionSourceConversionSourceIdRequestConversionSource,
|
|
36
|
+
)
|
|
37
|
+
from .types.get_ecommerce_attribution_products_conversion_source_conversion_source_id_response import (
|
|
38
|
+
GetEcommerceAttributionProductsConversionSourceConversionSourceIdResponse,
|
|
39
|
+
)
|
|
40
|
+
from .types.get_ecommerce_config_display_currency_response import GetEcommerceConfigDisplayCurrencyResponse
|
|
41
|
+
from .types.get_orders_request_sort import GetOrdersRequestSort
|
|
42
|
+
from .types.get_products_request_sort import GetProductsRequestSort
|
|
43
|
+
from .types.get_products_response import GetProductsResponse
|
|
44
|
+
from .types.set_config_display_currency_response import SetConfigDisplayCurrencyResponse
|
|
45
|
+
|
|
46
|
+
# this is used as the default value for optional parameters
|
|
47
|
+
OMIT = typing.cast(typing.Any, ...)
|
|
48
|
+
|
|
49
|
+
|
|
50
|
+
class EcommerceClient:
|
|
51
|
+
def __init__(self, *, client_wrapper: SyncClientWrapper):
|
|
52
|
+
self._raw_client = RawEcommerceClient(client_wrapper=client_wrapper)
|
|
53
|
+
|
|
54
|
+
@property
|
|
55
|
+
def with_raw_response(self) -> RawEcommerceClient:
|
|
56
|
+
"""
|
|
57
|
+
Retrieves a raw implementation of this client that returns raw responses.
|
|
58
|
+
|
|
59
|
+
Returns
|
|
60
|
+
-------
|
|
61
|
+
RawEcommerceClient
|
|
62
|
+
"""
|
|
63
|
+
return self._raw_client
|
|
64
|
+
|
|
65
|
+
def get_categories(
|
|
66
|
+
self,
|
|
67
|
+
*,
|
|
68
|
+
limit: typing.Optional[int] = None,
|
|
69
|
+
offset: typing.Optional[int] = None,
|
|
70
|
+
sort: typing.Optional[GetCategoriesRequestSort] = None,
|
|
71
|
+
ids: typing.Optional[typing.Union[str, typing.Sequence[str]]] = None,
|
|
72
|
+
name: typing.Optional[str] = None,
|
|
73
|
+
modified_since: typing.Optional[str] = None,
|
|
74
|
+
created_since: typing.Optional[str] = None,
|
|
75
|
+
is_deleted: typing.Optional[str] = None,
|
|
76
|
+
request_options: typing.Optional[RequestOptions] = None,
|
|
77
|
+
) -> GetCategoriesResponse:
|
|
78
|
+
"""
|
|
79
|
+
Parameters
|
|
80
|
+
----------
|
|
81
|
+
limit : typing.Optional[int]
|
|
82
|
+
Number of documents per page
|
|
83
|
+
|
|
84
|
+
offset : typing.Optional[int]
|
|
85
|
+
Index of the first document in the page
|
|
86
|
+
|
|
87
|
+
sort : typing.Optional[GetCategoriesRequestSort]
|
|
88
|
+
Sort the results in the ascending/descending order of record creation. Default order is **descending** if `sort` is not passed
|
|
89
|
+
|
|
90
|
+
ids : typing.Optional[typing.Union[str, typing.Sequence[str]]]
|
|
91
|
+
Filter by category ids
|
|
92
|
+
|
|
93
|
+
name : typing.Optional[str]
|
|
94
|
+
Filter by category name
|
|
95
|
+
|
|
96
|
+
modified_since : typing.Optional[str]
|
|
97
|
+
Filter (urlencoded) the categories modified after a given UTC date-time (YYYY-MM-DDTHH:mm:ss.SSSZ). **Prefer to pass your timezone in date-time format for accurate result.**
|
|
98
|
+
|
|
99
|
+
created_since : typing.Optional[str]
|
|
100
|
+
Filter (urlencoded) the categories created after a given UTC date-time (YYYY-MM-DDTHH:mm:ss.SSSZ). **Prefer to pass your timezone in date-time format for accurate result.**
|
|
101
|
+
|
|
102
|
+
is_deleted : typing.Optional[str]
|
|
103
|
+
Filter categories by their deletion status. If `false` is passed, only categories that are not deleted will be returned.
|
|
104
|
+
|
|
105
|
+
request_options : typing.Optional[RequestOptions]
|
|
106
|
+
Request-specific configuration.
|
|
107
|
+
|
|
108
|
+
Returns
|
|
109
|
+
-------
|
|
110
|
+
GetCategoriesResponse
|
|
111
|
+
All categories listed
|
|
112
|
+
|
|
113
|
+
Examples
|
|
114
|
+
--------
|
|
115
|
+
from brevo import Brevo
|
|
116
|
+
|
|
117
|
+
client = Brevo(
|
|
118
|
+
api_key="YOUR_API_KEY",
|
|
119
|
+
)
|
|
120
|
+
client.ecommerce.get_categories()
|
|
121
|
+
"""
|
|
122
|
+
_response = self._raw_client.get_categories(
|
|
123
|
+
limit=limit,
|
|
124
|
+
offset=offset,
|
|
125
|
+
sort=sort,
|
|
126
|
+
ids=ids,
|
|
127
|
+
name=name,
|
|
128
|
+
modified_since=modified_since,
|
|
129
|
+
created_since=created_since,
|
|
130
|
+
is_deleted=is_deleted,
|
|
131
|
+
request_options=request_options,
|
|
132
|
+
)
|
|
133
|
+
return _response.data
|
|
134
|
+
|
|
135
|
+
def create_update_category(
|
|
136
|
+
self,
|
|
137
|
+
*,
|
|
138
|
+
id: str,
|
|
139
|
+
deleted_at: typing.Optional[str] = OMIT,
|
|
140
|
+
is_deleted: typing.Optional[bool] = OMIT,
|
|
141
|
+
name: typing.Optional[str] = OMIT,
|
|
142
|
+
update_enabled: typing.Optional[bool] = OMIT,
|
|
143
|
+
url: typing.Optional[str] = OMIT,
|
|
144
|
+
request_options: typing.Optional[RequestOptions] = None,
|
|
145
|
+
) -> CreateUpdateCategoryResponse:
|
|
146
|
+
"""
|
|
147
|
+
Parameters
|
|
148
|
+
----------
|
|
149
|
+
id : str
|
|
150
|
+
Unique Category ID as saved in the shop
|
|
151
|
+
|
|
152
|
+
deleted_at : typing.Optional[str]
|
|
153
|
+
UTC date-time (YYYY-MM-DDTHH:mm:ss.SSSZ) of the category deleted from the shop's database
|
|
154
|
+
|
|
155
|
+
is_deleted : typing.Optional[bool]
|
|
156
|
+
category deleted from the shop's database
|
|
157
|
+
|
|
158
|
+
name : typing.Optional[str]
|
|
159
|
+
**Mandatory in case of creation**. Name of the Category, as displayed in the shop
|
|
160
|
+
|
|
161
|
+
update_enabled : typing.Optional[bool]
|
|
162
|
+
Facilitate to update the existing category in the same request (updateEnabled = true)
|
|
163
|
+
|
|
164
|
+
url : typing.Optional[str]
|
|
165
|
+
URL to the category
|
|
166
|
+
|
|
167
|
+
request_options : typing.Optional[RequestOptions]
|
|
168
|
+
Request-specific configuration.
|
|
169
|
+
|
|
170
|
+
Returns
|
|
171
|
+
-------
|
|
172
|
+
CreateUpdateCategoryResponse
|
|
173
|
+
Category created
|
|
174
|
+
|
|
175
|
+
Examples
|
|
176
|
+
--------
|
|
177
|
+
from brevo import Brevo
|
|
178
|
+
|
|
179
|
+
client = Brevo(
|
|
180
|
+
api_key="YOUR_API_KEY",
|
|
181
|
+
)
|
|
182
|
+
client.ecommerce.create_update_category(
|
|
183
|
+
id="CAT123",
|
|
184
|
+
)
|
|
185
|
+
"""
|
|
186
|
+
_response = self._raw_client.create_update_category(
|
|
187
|
+
id=id,
|
|
188
|
+
deleted_at=deleted_at,
|
|
189
|
+
is_deleted=is_deleted,
|
|
190
|
+
name=name,
|
|
191
|
+
update_enabled=update_enabled,
|
|
192
|
+
url=url,
|
|
193
|
+
request_options=request_options,
|
|
194
|
+
)
|
|
195
|
+
return _response.data
|
|
196
|
+
|
|
197
|
+
def create_update_batch_category(
|
|
198
|
+
self,
|
|
199
|
+
*,
|
|
200
|
+
categories: typing.Sequence[CreateUpdateBatchCategoryRequestCategoriesItem],
|
|
201
|
+
update_enabled: typing.Optional[bool] = OMIT,
|
|
202
|
+
request_options: typing.Optional[RequestOptions] = None,
|
|
203
|
+
) -> CreateUpdateBatchCategoryResponse:
|
|
204
|
+
"""
|
|
205
|
+
Parameters
|
|
206
|
+
----------
|
|
207
|
+
categories : typing.Sequence[CreateUpdateBatchCategoryRequestCategoriesItem]
|
|
208
|
+
array of categories objects
|
|
209
|
+
|
|
210
|
+
update_enabled : typing.Optional[bool]
|
|
211
|
+
Facilitate to update the existing categories in the same request (updateEnabled = true)
|
|
212
|
+
|
|
213
|
+
request_options : typing.Optional[RequestOptions]
|
|
214
|
+
Request-specific configuration.
|
|
215
|
+
|
|
216
|
+
Returns
|
|
217
|
+
-------
|
|
218
|
+
CreateUpdateBatchCategoryResponse
|
|
219
|
+
Category created and updated
|
|
220
|
+
|
|
221
|
+
Examples
|
|
222
|
+
--------
|
|
223
|
+
from brevo import Brevo
|
|
224
|
+
from brevo.ecommerce import CreateUpdateBatchCategoryRequestCategoriesItem
|
|
225
|
+
|
|
226
|
+
client = Brevo(
|
|
227
|
+
api_key="YOUR_API_KEY",
|
|
228
|
+
)
|
|
229
|
+
client.ecommerce.create_update_batch_category(
|
|
230
|
+
categories=[
|
|
231
|
+
CreateUpdateBatchCategoryRequestCategoriesItem(
|
|
232
|
+
id="CAT123",
|
|
233
|
+
)
|
|
234
|
+
],
|
|
235
|
+
)
|
|
236
|
+
"""
|
|
237
|
+
_response = self._raw_client.create_update_batch_category(
|
|
238
|
+
categories=categories, update_enabled=update_enabled, request_options=request_options
|
|
239
|
+
)
|
|
240
|
+
return _response.data
|
|
241
|
+
|
|
242
|
+
def get_category_info(
|
|
243
|
+
self, id: str, *, request_options: typing.Optional[RequestOptions] = None
|
|
244
|
+
) -> GetCategoryDetails:
|
|
245
|
+
"""
|
|
246
|
+
Parameters
|
|
247
|
+
----------
|
|
248
|
+
id : str
|
|
249
|
+
Category ID
|
|
250
|
+
|
|
251
|
+
request_options : typing.Optional[RequestOptions]
|
|
252
|
+
Request-specific configuration.
|
|
253
|
+
|
|
254
|
+
Returns
|
|
255
|
+
-------
|
|
256
|
+
GetCategoryDetails
|
|
257
|
+
Category informations
|
|
258
|
+
|
|
259
|
+
Examples
|
|
260
|
+
--------
|
|
261
|
+
from brevo import Brevo
|
|
262
|
+
|
|
263
|
+
client = Brevo(
|
|
264
|
+
api_key="YOUR_API_KEY",
|
|
265
|
+
)
|
|
266
|
+
client.ecommerce.get_category_info(
|
|
267
|
+
id="id",
|
|
268
|
+
)
|
|
269
|
+
"""
|
|
270
|
+
_response = self._raw_client.get_category_info(id, request_options=request_options)
|
|
271
|
+
return _response.data
|
|
272
|
+
|
|
273
|
+
def activate_the_e_commerce_app(self, *, request_options: typing.Optional[RequestOptions] = None) -> None:
|
|
274
|
+
"""
|
|
275
|
+
Getting access to Brevo eCommerce.
|
|
276
|
+
|
|
277
|
+
Parameters
|
|
278
|
+
----------
|
|
279
|
+
request_options : typing.Optional[RequestOptions]
|
|
280
|
+
Request-specific configuration.
|
|
281
|
+
|
|
282
|
+
Returns
|
|
283
|
+
-------
|
|
284
|
+
None
|
|
285
|
+
|
|
286
|
+
Examples
|
|
287
|
+
--------
|
|
288
|
+
from brevo import Brevo
|
|
289
|
+
|
|
290
|
+
client = Brevo(
|
|
291
|
+
api_key="YOUR_API_KEY",
|
|
292
|
+
)
|
|
293
|
+
client.ecommerce.activate_the_e_commerce_app()
|
|
294
|
+
"""
|
|
295
|
+
_response = self._raw_client.activate_the_e_commerce_app(request_options=request_options)
|
|
296
|
+
return _response.data
|
|
297
|
+
|
|
298
|
+
def get_attribution_metrics_for_one_or_more_brevo_campaigns_or_workflows(
|
|
299
|
+
self,
|
|
300
|
+
*,
|
|
301
|
+
period_from: typing.Optional[dt.datetime] = None,
|
|
302
|
+
period_to: typing.Optional[dt.datetime] = None,
|
|
303
|
+
email_campaign_id_array: typing.Optional[typing.Union[str, typing.Sequence[str]]] = None,
|
|
304
|
+
sms_campaign_id_array: typing.Optional[typing.Union[str, typing.Sequence[str]]] = None,
|
|
305
|
+
automation_workflow_email_id_array: typing.Optional[typing.Union[str, typing.Sequence[str]]] = None,
|
|
306
|
+
automation_workflow_sms_id_array: typing.Optional[typing.Union[str, typing.Sequence[str]]] = None,
|
|
307
|
+
request_options: typing.Optional[RequestOptions] = None,
|
|
308
|
+
) -> GetEcommerceAttributionMetricsResponse:
|
|
309
|
+
"""
|
|
310
|
+
Parameters
|
|
311
|
+
----------
|
|
312
|
+
period_from : typing.Optional[dt.datetime]
|
|
313
|
+
When getting metrics for a specific period, define the starting datetime in RFC3339 format
|
|
314
|
+
|
|
315
|
+
period_to : typing.Optional[dt.datetime]
|
|
316
|
+
When getting metrics for a specific period, define the end datetime in RFC3339 format
|
|
317
|
+
|
|
318
|
+
email_campaign_id_array : typing.Optional[typing.Union[str, typing.Sequence[str]]]
|
|
319
|
+
The email campaign ID(s) to get metrics for
|
|
320
|
+
|
|
321
|
+
sms_campaign_id_array : typing.Optional[typing.Union[str, typing.Sequence[str]]]
|
|
322
|
+
The SMS campaign ID(s) to get metrics for
|
|
323
|
+
|
|
324
|
+
automation_workflow_email_id_array : typing.Optional[typing.Union[str, typing.Sequence[str]]]
|
|
325
|
+
The automation workflow ID(s) to get email attribution metrics for
|
|
326
|
+
|
|
327
|
+
automation_workflow_sms_id_array : typing.Optional[typing.Union[str, typing.Sequence[str]]]
|
|
328
|
+
The automation workflow ID(s) to get SMS attribution metrics for
|
|
329
|
+
|
|
330
|
+
request_options : typing.Optional[RequestOptions]
|
|
331
|
+
Request-specific configuration.
|
|
332
|
+
|
|
333
|
+
Returns
|
|
334
|
+
-------
|
|
335
|
+
GetEcommerceAttributionMetricsResponse
|
|
336
|
+
OK
|
|
337
|
+
|
|
338
|
+
Examples
|
|
339
|
+
--------
|
|
340
|
+
import datetime
|
|
341
|
+
|
|
342
|
+
from brevo import Brevo
|
|
343
|
+
|
|
344
|
+
client = Brevo(
|
|
345
|
+
api_key="YOUR_API_KEY",
|
|
346
|
+
)
|
|
347
|
+
client.ecommerce.get_attribution_metrics_for_one_or_more_brevo_campaigns_or_workflows(
|
|
348
|
+
period_from=datetime.datetime.fromisoformat(
|
|
349
|
+
"2022-01-02 00:00:00+00:00",
|
|
350
|
+
),
|
|
351
|
+
period_to=datetime.datetime.fromisoformat(
|
|
352
|
+
"2022-01-03 00:00:00+00:00",
|
|
353
|
+
),
|
|
354
|
+
)
|
|
355
|
+
"""
|
|
356
|
+
_response = self._raw_client.get_attribution_metrics_for_one_or_more_brevo_campaigns_or_workflows(
|
|
357
|
+
period_from=period_from,
|
|
358
|
+
period_to=period_to,
|
|
359
|
+
email_campaign_id_array=email_campaign_id_array,
|
|
360
|
+
sms_campaign_id_array=sms_campaign_id_array,
|
|
361
|
+
automation_workflow_email_id_array=automation_workflow_email_id_array,
|
|
362
|
+
automation_workflow_sms_id_array=automation_workflow_sms_id_array,
|
|
363
|
+
request_options=request_options,
|
|
364
|
+
)
|
|
365
|
+
return _response.data
|
|
366
|
+
|
|
367
|
+
def get_detailed_attribution_metrics_for_a_single_brevo_campaign_or_workflow(
|
|
368
|
+
self,
|
|
369
|
+
conversion_source: GetEcommerceAttributionMetricsConversionSourceConversionSourceIdRequestConversionSource,
|
|
370
|
+
conversion_source_id: str,
|
|
371
|
+
*,
|
|
372
|
+
request_options: typing.Optional[RequestOptions] = None,
|
|
373
|
+
) -> GetEcommerceAttributionMetricsConversionSourceConversionSourceIdResponse:
|
|
374
|
+
"""
|
|
375
|
+
Parameters
|
|
376
|
+
----------
|
|
377
|
+
conversion_source : GetEcommerceAttributionMetricsConversionSourceConversionSourceIdRequestConversionSource
|
|
378
|
+
The Brevo campaign type or workflow type for which data will be retrieved
|
|
379
|
+
|
|
380
|
+
conversion_source_id : str
|
|
381
|
+
The Brevo campaign or automation workflow id for which data will be retrieved
|
|
382
|
+
|
|
383
|
+
request_options : typing.Optional[RequestOptions]
|
|
384
|
+
Request-specific configuration.
|
|
385
|
+
|
|
386
|
+
Returns
|
|
387
|
+
-------
|
|
388
|
+
GetEcommerceAttributionMetricsConversionSourceConversionSourceIdResponse
|
|
389
|
+
OK
|
|
390
|
+
|
|
391
|
+
Examples
|
|
392
|
+
--------
|
|
393
|
+
from brevo import Brevo
|
|
394
|
+
|
|
395
|
+
client = Brevo(
|
|
396
|
+
api_key="YOUR_API_KEY",
|
|
397
|
+
)
|
|
398
|
+
client.ecommerce.get_detailed_attribution_metrics_for_a_single_brevo_campaign_or_workflow(
|
|
399
|
+
conversion_source="email_campaign",
|
|
400
|
+
conversion_source_id="sale",
|
|
401
|
+
)
|
|
402
|
+
"""
|
|
403
|
+
_response = self._raw_client.get_detailed_attribution_metrics_for_a_single_brevo_campaign_or_workflow(
|
|
404
|
+
conversion_source, conversion_source_id, request_options=request_options
|
|
405
|
+
)
|
|
406
|
+
return _response.data
|
|
407
|
+
|
|
408
|
+
def get_attributed_product_sales_for_a_single_brevo_campaign_or_workflow(
|
|
409
|
+
self,
|
|
410
|
+
conversion_source: GetEcommerceAttributionProductsConversionSourceConversionSourceIdRequestConversionSource,
|
|
411
|
+
conversion_source_id: str,
|
|
412
|
+
*,
|
|
413
|
+
request_options: typing.Optional[RequestOptions] = None,
|
|
414
|
+
) -> GetEcommerceAttributionProductsConversionSourceConversionSourceIdResponse:
|
|
415
|
+
"""
|
|
416
|
+
Parameters
|
|
417
|
+
----------
|
|
418
|
+
conversion_source : GetEcommerceAttributionProductsConversionSourceConversionSourceIdRequestConversionSource
|
|
419
|
+
The Brevo campaign or automation workflow type for which data will be retrieved
|
|
420
|
+
|
|
421
|
+
conversion_source_id : str
|
|
422
|
+
The Brevo campaign or automation workflow id for which data will be retrieved
|
|
423
|
+
|
|
424
|
+
request_options : typing.Optional[RequestOptions]
|
|
425
|
+
Request-specific configuration.
|
|
426
|
+
|
|
427
|
+
Returns
|
|
428
|
+
-------
|
|
429
|
+
GetEcommerceAttributionProductsConversionSourceConversionSourceIdResponse
|
|
430
|
+
OK
|
|
431
|
+
|
|
432
|
+
Examples
|
|
433
|
+
--------
|
|
434
|
+
from brevo import Brevo
|
|
435
|
+
|
|
436
|
+
client = Brevo(
|
|
437
|
+
api_key="YOUR_API_KEY",
|
|
438
|
+
)
|
|
439
|
+
client.ecommerce.get_attributed_product_sales_for_a_single_brevo_campaign_or_workflow(
|
|
440
|
+
conversion_source="email_campaign",
|
|
441
|
+
conversion_source_id="sale",
|
|
442
|
+
)
|
|
443
|
+
"""
|
|
444
|
+
_response = self._raw_client.get_attributed_product_sales_for_a_single_brevo_campaign_or_workflow(
|
|
445
|
+
conversion_source, conversion_source_id, request_options=request_options
|
|
446
|
+
)
|
|
447
|
+
return _response.data
|
|
448
|
+
|
|
449
|
+
def get_the_iso4217compliant_display_currency_code_for_your_brevo_account(
|
|
450
|
+
self, *, request_options: typing.Optional[RequestOptions] = None
|
|
451
|
+
) -> GetEcommerceConfigDisplayCurrencyResponse:
|
|
452
|
+
"""
|
|
453
|
+
Parameters
|
|
454
|
+
----------
|
|
455
|
+
request_options : typing.Optional[RequestOptions]
|
|
456
|
+
Request-specific configuration.
|
|
457
|
+
|
|
458
|
+
Returns
|
|
459
|
+
-------
|
|
460
|
+
GetEcommerceConfigDisplayCurrencyResponse
|
|
461
|
+
OK
|
|
462
|
+
|
|
463
|
+
Examples
|
|
464
|
+
--------
|
|
465
|
+
from brevo import Brevo
|
|
466
|
+
|
|
467
|
+
client = Brevo(
|
|
468
|
+
api_key="YOUR_API_KEY",
|
|
469
|
+
)
|
|
470
|
+
client.ecommerce.get_the_iso4217compliant_display_currency_code_for_your_brevo_account()
|
|
471
|
+
"""
|
|
472
|
+
_response = self._raw_client.get_the_iso4217compliant_display_currency_code_for_your_brevo_account(
|
|
473
|
+
request_options=request_options
|
|
474
|
+
)
|
|
475
|
+
return _response.data
|
|
476
|
+
|
|
477
|
+
def set_config_display_currency(
|
|
478
|
+
self, *, code: str, request_options: typing.Optional[RequestOptions] = None
|
|
479
|
+
) -> SetConfigDisplayCurrencyResponse:
|
|
480
|
+
"""
|
|
481
|
+
Parameters
|
|
482
|
+
----------
|
|
483
|
+
code : str
|
|
484
|
+
ISO 4217 compliant display currency code
|
|
485
|
+
|
|
486
|
+
request_options : typing.Optional[RequestOptions]
|
|
487
|
+
Request-specific configuration.
|
|
488
|
+
|
|
489
|
+
Returns
|
|
490
|
+
-------
|
|
491
|
+
SetConfigDisplayCurrencyResponse
|
|
492
|
+
OK
|
|
493
|
+
|
|
494
|
+
Examples
|
|
495
|
+
--------
|
|
496
|
+
from brevo import Brevo
|
|
497
|
+
|
|
498
|
+
client = Brevo(
|
|
499
|
+
api_key="YOUR_API_KEY",
|
|
500
|
+
)
|
|
501
|
+
client.ecommerce.set_config_display_currency(
|
|
502
|
+
code="EUR",
|
|
503
|
+
)
|
|
504
|
+
"""
|
|
505
|
+
_response = self._raw_client.set_config_display_currency(code=code, request_options=request_options)
|
|
506
|
+
return _response.data
|
|
507
|
+
|
|
508
|
+
def get_orders(
|
|
509
|
+
self,
|
|
510
|
+
*,
|
|
511
|
+
limit: typing.Optional[int] = None,
|
|
512
|
+
offset: typing.Optional[int] = None,
|
|
513
|
+
sort: typing.Optional[GetOrdersRequestSort] = None,
|
|
514
|
+
modified_since: typing.Optional[str] = None,
|
|
515
|
+
created_since: typing.Optional[str] = None,
|
|
516
|
+
request_options: typing.Optional[RequestOptions] = None,
|
|
517
|
+
) -> typing.Any:
|
|
518
|
+
"""
|
|
519
|
+
Get all the orders
|
|
520
|
+
|
|
521
|
+
Parameters
|
|
522
|
+
----------
|
|
523
|
+
limit : typing.Optional[int]
|
|
524
|
+
Number of documents per page
|
|
525
|
+
|
|
526
|
+
offset : typing.Optional[int]
|
|
527
|
+
Index of the first document in the page
|
|
528
|
+
|
|
529
|
+
sort : typing.Optional[GetOrdersRequestSort]
|
|
530
|
+
Sort the results in the ascending/descending order of record creation. Default order is **descending** if `sort` is not passed
|
|
531
|
+
|
|
532
|
+
modified_since : typing.Optional[str]
|
|
533
|
+
Filter (urlencoded) the orders modified after a given UTC date-time (YYYY-MM-DDTHH:mm:ss.SSSZ). **Prefer to pass your timezone in date-time format for accurate result.**
|
|
534
|
+
|
|
535
|
+
created_since : typing.Optional[str]
|
|
536
|
+
Filter (urlencoded) the orders created after a given UTC date-time (YYYY-MM-DDTHH:mm:ss.SSSZ). **Prefer to pass your timezone in date-time format for accurate result.**
|
|
537
|
+
|
|
538
|
+
request_options : typing.Optional[RequestOptions]
|
|
539
|
+
Request-specific configuration.
|
|
540
|
+
|
|
541
|
+
Returns
|
|
542
|
+
-------
|
|
543
|
+
typing.Any
|
|
544
|
+
orders fetched successfully
|
|
545
|
+
|
|
546
|
+
Examples
|
|
547
|
+
--------
|
|
548
|
+
from brevo import Brevo
|
|
549
|
+
|
|
550
|
+
client = Brevo(
|
|
551
|
+
api_key="YOUR_API_KEY",
|
|
552
|
+
)
|
|
553
|
+
client.ecommerce.get_orders()
|
|
554
|
+
"""
|
|
555
|
+
_response = self._raw_client.get_orders(
|
|
556
|
+
limit=limit,
|
|
557
|
+
offset=offset,
|
|
558
|
+
sort=sort,
|
|
559
|
+
modified_since=modified_since,
|
|
560
|
+
created_since=created_since,
|
|
561
|
+
request_options=request_options,
|
|
562
|
+
)
|
|
563
|
+
return _response.data
|
|
564
|
+
|
|
565
|
+
def create_order(
|
|
566
|
+
self,
|
|
567
|
+
*,
|
|
568
|
+
amount: float,
|
|
569
|
+
created_at: str,
|
|
570
|
+
id: str,
|
|
571
|
+
products: typing.Sequence[OrderProductsItem],
|
|
572
|
+
status: str,
|
|
573
|
+
updated_at: str,
|
|
574
|
+
billing: typing.Optional[OrderBilling] = OMIT,
|
|
575
|
+
coupons: typing.Optional[typing.Sequence[str]] = OMIT,
|
|
576
|
+
identifiers: typing.Optional[OrderIdentifiers] = OMIT,
|
|
577
|
+
meta_info: typing.Optional[typing.Dict[str, OrderMetaInfoValue]] = OMIT,
|
|
578
|
+
store_id: typing.Optional[str] = OMIT,
|
|
579
|
+
request_options: typing.Optional[RequestOptions] = None,
|
|
580
|
+
) -> None:
|
|
581
|
+
"""
|
|
582
|
+
Manages the transactional status of the order
|
|
583
|
+
|
|
584
|
+
Parameters
|
|
585
|
+
----------
|
|
586
|
+
amount : float
|
|
587
|
+
Total amount of the order, including all shipping expenses, tax and the price of items.
|
|
588
|
+
|
|
589
|
+
created_at : str
|
|
590
|
+
Event occurrence UTC date-time (YYYY-MM-DDTHH:mm:ssZ), when order is actually created.
|
|
591
|
+
|
|
592
|
+
id : str
|
|
593
|
+
Unique ID of the order.
|
|
594
|
+
|
|
595
|
+
products : typing.Sequence[OrderProductsItem]
|
|
596
|
+
|
|
597
|
+
status : str
|
|
598
|
+
State of the order.
|
|
599
|
+
|
|
600
|
+
updated_at : str
|
|
601
|
+
Event updated UTC date-time (YYYY-MM-DDTHH:mm:ssZ), when the status of the order is actually changed/updated.
|
|
602
|
+
|
|
603
|
+
billing : typing.Optional[OrderBilling]
|
|
604
|
+
Billing details of an order.
|
|
605
|
+
|
|
606
|
+
coupons : typing.Optional[typing.Sequence[str]]
|
|
607
|
+
Coupons applied to the order. Stored case insensitive.
|
|
608
|
+
|
|
609
|
+
identifiers : typing.Optional[OrderIdentifiers]
|
|
610
|
+
Identifies the contact associated with the order.
|
|
611
|
+
|
|
612
|
+
meta_info : typing.Optional[typing.Dict[str, OrderMetaInfoValue]]
|
|
613
|
+
Meta data of order to store additional detal such as custom message, customer type, source.
|
|
614
|
+
|
|
615
|
+
store_id : typing.Optional[str]
|
|
616
|
+
ID of store where the order is placed
|
|
617
|
+
|
|
618
|
+
request_options : typing.Optional[RequestOptions]
|
|
619
|
+
Request-specific configuration.
|
|
620
|
+
|
|
621
|
+
Returns
|
|
622
|
+
-------
|
|
623
|
+
None
|
|
624
|
+
|
|
625
|
+
Examples
|
|
626
|
+
--------
|
|
627
|
+
from brevo import Brevo, OrderProductsItem
|
|
628
|
+
|
|
629
|
+
client = Brevo(
|
|
630
|
+
api_key="YOUR_API_KEY",
|
|
631
|
+
)
|
|
632
|
+
client.ecommerce.create_order(
|
|
633
|
+
amount=308.42,
|
|
634
|
+
created_at="2021-07-29T20:59:23.383Z",
|
|
635
|
+
id="14",
|
|
636
|
+
products=[
|
|
637
|
+
OrderProductsItem(
|
|
638
|
+
price=99.99,
|
|
639
|
+
product_id="P1",
|
|
640
|
+
quantity=10.0,
|
|
641
|
+
)
|
|
642
|
+
],
|
|
643
|
+
status="completed",
|
|
644
|
+
updated_at="2021-07-30T10:59:23.383Z",
|
|
645
|
+
)
|
|
646
|
+
"""
|
|
647
|
+
_response = self._raw_client.create_order(
|
|
648
|
+
amount=amount,
|
|
649
|
+
created_at=created_at,
|
|
650
|
+
id=id,
|
|
651
|
+
products=products,
|
|
652
|
+
status=status,
|
|
653
|
+
updated_at=updated_at,
|
|
654
|
+
billing=billing,
|
|
655
|
+
coupons=coupons,
|
|
656
|
+
identifiers=identifiers,
|
|
657
|
+
meta_info=meta_info,
|
|
658
|
+
store_id=store_id,
|
|
659
|
+
request_options=request_options,
|
|
660
|
+
)
|
|
661
|
+
return _response.data
|
|
662
|
+
|
|
663
|
+
def create_batch_order(
|
|
664
|
+
self,
|
|
665
|
+
*,
|
|
666
|
+
orders: typing.Sequence[Order],
|
|
667
|
+
historical: typing.Optional[bool] = OMIT,
|
|
668
|
+
notify_url: typing.Optional[str] = OMIT,
|
|
669
|
+
request_options: typing.Optional[RequestOptions] = None,
|
|
670
|
+
) -> CreateBatchOrderResponse:
|
|
671
|
+
"""
|
|
672
|
+
Create multiple orders at one time instead of one order at a time
|
|
673
|
+
|
|
674
|
+
Parameters
|
|
675
|
+
----------
|
|
676
|
+
orders : typing.Sequence[Order]
|
|
677
|
+
array of order objects
|
|
678
|
+
|
|
679
|
+
historical : typing.Optional[bool]
|
|
680
|
+
Defines wether you want your orders to be considered as live data or as historical data (import of past data, synchronising data). True: orders will not trigger any automation workflows. False: orders will trigger workflows as usual.
|
|
681
|
+
|
|
682
|
+
notify_url : typing.Optional[str]
|
|
683
|
+
Notify Url provided by client_dev to get the status of batch request
|
|
684
|
+
|
|
685
|
+
request_options : typing.Optional[RequestOptions]
|
|
686
|
+
Request-specific configuration.
|
|
687
|
+
|
|
688
|
+
Returns
|
|
689
|
+
-------
|
|
690
|
+
CreateBatchOrderResponse
|
|
691
|
+
batch id created
|
|
692
|
+
|
|
693
|
+
Examples
|
|
694
|
+
--------
|
|
695
|
+
from brevo import Brevo, Order, OrderProductsItem
|
|
696
|
+
|
|
697
|
+
client = Brevo(
|
|
698
|
+
api_key="YOUR_API_KEY",
|
|
699
|
+
)
|
|
700
|
+
client.ecommerce.create_batch_order(
|
|
701
|
+
orders=[
|
|
702
|
+
Order(
|
|
703
|
+
amount=308.42,
|
|
704
|
+
created_at="2021-07-29T20:59:23.383Z",
|
|
705
|
+
id="14",
|
|
706
|
+
products=[
|
|
707
|
+
OrderProductsItem(
|
|
708
|
+
price=99.99,
|
|
709
|
+
product_id="P1",
|
|
710
|
+
quantity=10.0,
|
|
711
|
+
)
|
|
712
|
+
],
|
|
713
|
+
status="completed",
|
|
714
|
+
updated_at="2021-07-30T10:59:23.383Z",
|
|
715
|
+
)
|
|
716
|
+
],
|
|
717
|
+
)
|
|
718
|
+
"""
|
|
719
|
+
_response = self._raw_client.create_batch_order(
|
|
720
|
+
orders=orders, historical=historical, notify_url=notify_url, request_options=request_options
|
|
721
|
+
)
|
|
722
|
+
return _response.data
|
|
723
|
+
|
|
724
|
+
def get_products(
|
|
725
|
+
self,
|
|
726
|
+
*,
|
|
727
|
+
limit: typing.Optional[int] = None,
|
|
728
|
+
offset: typing.Optional[int] = None,
|
|
729
|
+
sort: typing.Optional[GetProductsRequestSort] = None,
|
|
730
|
+
ids: typing.Optional[typing.Union[str, typing.Sequence[str]]] = None,
|
|
731
|
+
name: typing.Optional[str] = None,
|
|
732
|
+
price_lte: typing.Optional[float] = None,
|
|
733
|
+
price_gte: typing.Optional[float] = None,
|
|
734
|
+
price_lt: typing.Optional[float] = None,
|
|
735
|
+
price_gt: typing.Optional[float] = None,
|
|
736
|
+
price_eq: typing.Optional[float] = None,
|
|
737
|
+
price_ne: typing.Optional[float] = None,
|
|
738
|
+
categories: typing.Optional[typing.Union[str, typing.Sequence[str]]] = None,
|
|
739
|
+
modified_since: typing.Optional[str] = None,
|
|
740
|
+
created_since: typing.Optional[str] = None,
|
|
741
|
+
is_deleted: typing.Optional[str] = None,
|
|
742
|
+
request_options: typing.Optional[RequestOptions] = None,
|
|
743
|
+
) -> GetProductsResponse:
|
|
744
|
+
"""
|
|
745
|
+
Parameters
|
|
746
|
+
----------
|
|
747
|
+
limit : typing.Optional[int]
|
|
748
|
+
Number of documents per page
|
|
749
|
+
|
|
750
|
+
offset : typing.Optional[int]
|
|
751
|
+
Index of the first document in the page
|
|
752
|
+
|
|
753
|
+
sort : typing.Optional[GetProductsRequestSort]
|
|
754
|
+
Sort the results in the ascending/descending order of record creation. Default order is **descending** if `sort` is not passed
|
|
755
|
+
|
|
756
|
+
ids : typing.Optional[typing.Union[str, typing.Sequence[str]]]
|
|
757
|
+
Filter by product ids
|
|
758
|
+
|
|
759
|
+
name : typing.Optional[str]
|
|
760
|
+
Filter by product name, minimum 3 characters should be present for search.
|
|
761
|
+
|
|
762
|
+
price_lte : typing.Optional[float]
|
|
763
|
+
Price filter for products less than and equals to particular amount
|
|
764
|
+
|
|
765
|
+
price_gte : typing.Optional[float]
|
|
766
|
+
Price filter for products greater than and equals to particular amount
|
|
767
|
+
|
|
768
|
+
price_lt : typing.Optional[float]
|
|
769
|
+
Price filter for products less than particular amount
|
|
770
|
+
|
|
771
|
+
price_gt : typing.Optional[float]
|
|
772
|
+
Price filter for products greater than particular amount
|
|
773
|
+
|
|
774
|
+
price_eq : typing.Optional[float]
|
|
775
|
+
Price filter for products equals to particular amount
|
|
776
|
+
|
|
777
|
+
price_ne : typing.Optional[float]
|
|
778
|
+
Price filter for products not equals to particular amount
|
|
779
|
+
|
|
780
|
+
categories : typing.Optional[typing.Union[str, typing.Sequence[str]]]
|
|
781
|
+
Filter by categories ids
|
|
782
|
+
|
|
783
|
+
modified_since : typing.Optional[str]
|
|
784
|
+
Filter (urlencoded) the orders modified after a given UTC date-time (YYYY-MM-DDTHH:mm:ss.SSSZ). **Prefer to pass your timezone in date-time format for accurate result.**
|
|
785
|
+
|
|
786
|
+
created_since : typing.Optional[str]
|
|
787
|
+
Filter (urlencoded) the orders created after a given UTC date-time (YYYY-MM-DDTHH:mm:ss.SSSZ). **Prefer to pass your timezone in date-time format for accurate result.**
|
|
788
|
+
|
|
789
|
+
is_deleted : typing.Optional[str]
|
|
790
|
+
Filter products by their deletion status. If `false` is passed, only products that are not deleted will be returned.
|
|
791
|
+
|
|
792
|
+
request_options : typing.Optional[RequestOptions]
|
|
793
|
+
Request-specific configuration.
|
|
794
|
+
|
|
795
|
+
Returns
|
|
796
|
+
-------
|
|
797
|
+
GetProductsResponse
|
|
798
|
+
All products listed
|
|
799
|
+
|
|
800
|
+
Examples
|
|
801
|
+
--------
|
|
802
|
+
from brevo import Brevo
|
|
803
|
+
|
|
804
|
+
client = Brevo(
|
|
805
|
+
api_key="YOUR_API_KEY",
|
|
806
|
+
)
|
|
807
|
+
client.ecommerce.get_products()
|
|
808
|
+
"""
|
|
809
|
+
_response = self._raw_client.get_products(
|
|
810
|
+
limit=limit,
|
|
811
|
+
offset=offset,
|
|
812
|
+
sort=sort,
|
|
813
|
+
ids=ids,
|
|
814
|
+
name=name,
|
|
815
|
+
price_lte=price_lte,
|
|
816
|
+
price_gte=price_gte,
|
|
817
|
+
price_lt=price_lt,
|
|
818
|
+
price_gt=price_gt,
|
|
819
|
+
price_eq=price_eq,
|
|
820
|
+
price_ne=price_ne,
|
|
821
|
+
categories=categories,
|
|
822
|
+
modified_since=modified_since,
|
|
823
|
+
created_since=created_since,
|
|
824
|
+
is_deleted=is_deleted,
|
|
825
|
+
request_options=request_options,
|
|
826
|
+
)
|
|
827
|
+
return _response.data
|
|
828
|
+
|
|
829
|
+
def create_update_product(
|
|
830
|
+
self,
|
|
831
|
+
*,
|
|
832
|
+
id: str,
|
|
833
|
+
name: str,
|
|
834
|
+
categories: typing.Optional[typing.Sequence[str]] = OMIT,
|
|
835
|
+
deleted_at: typing.Optional[str] = OMIT,
|
|
836
|
+
image_url: typing.Optional[str] = OMIT,
|
|
837
|
+
is_deleted: typing.Optional[bool] = OMIT,
|
|
838
|
+
meta_info: typing.Optional[typing.Dict[str, CreateUpdateProductRequestMetaInfoValue]] = OMIT,
|
|
839
|
+
parent_id: typing.Optional[str] = OMIT,
|
|
840
|
+
price: typing.Optional[float] = OMIT,
|
|
841
|
+
sku: typing.Optional[str] = OMIT,
|
|
842
|
+
stock: typing.Optional[float] = OMIT,
|
|
843
|
+
update_enabled: typing.Optional[bool] = OMIT,
|
|
844
|
+
url: typing.Optional[str] = OMIT,
|
|
845
|
+
request_options: typing.Optional[RequestOptions] = None,
|
|
846
|
+
) -> CreateUpdateProductResponse:
|
|
847
|
+
"""
|
|
848
|
+
Parameters
|
|
849
|
+
----------
|
|
850
|
+
id : str
|
|
851
|
+
Product ID for which you requested the details
|
|
852
|
+
|
|
853
|
+
name : str
|
|
854
|
+
Mandatory in case of creation**. Name of the product for which you requested the details
|
|
855
|
+
|
|
856
|
+
categories : typing.Optional[typing.Sequence[str]]
|
|
857
|
+
Category ID-s of the product
|
|
858
|
+
|
|
859
|
+
deleted_at : typing.Optional[str]
|
|
860
|
+
UTC date-time (YYYY-MM-DDTHH:mm:ss.SSSZ) of the product deleted from the shop's database
|
|
861
|
+
|
|
862
|
+
image_url : typing.Optional[str]
|
|
863
|
+
Absolute URL to the cover image of the product
|
|
864
|
+
|
|
865
|
+
is_deleted : typing.Optional[bool]
|
|
866
|
+
product deleted from the shop's database
|
|
867
|
+
|
|
868
|
+
meta_info : typing.Optional[typing.Dict[str, CreateUpdateProductRequestMetaInfoValue]]
|
|
869
|
+
Meta data of product such as description, vendor, producer, stock level. The size of cumulative metaInfo shall not exceed **1000 KB**. Maximum length of metaInfo object can be 20.
|
|
870
|
+
|
|
871
|
+
parent_id : typing.Optional[str]
|
|
872
|
+
Parent product id of the product
|
|
873
|
+
|
|
874
|
+
price : typing.Optional[float]
|
|
875
|
+
Price of the product
|
|
876
|
+
|
|
877
|
+
sku : typing.Optional[str]
|
|
878
|
+
Product identifier from the shop
|
|
879
|
+
|
|
880
|
+
stock : typing.Optional[float]
|
|
881
|
+
Current stock value of the product from the shop's database
|
|
882
|
+
|
|
883
|
+
update_enabled : typing.Optional[bool]
|
|
884
|
+
Facilitate to update the existing category in the same request (updateEnabled = true)
|
|
885
|
+
|
|
886
|
+
url : typing.Optional[str]
|
|
887
|
+
URL to the product
|
|
888
|
+
|
|
889
|
+
request_options : typing.Optional[RequestOptions]
|
|
890
|
+
Request-specific configuration.
|
|
891
|
+
|
|
892
|
+
Returns
|
|
893
|
+
-------
|
|
894
|
+
CreateUpdateProductResponse
|
|
895
|
+
Product created
|
|
896
|
+
|
|
897
|
+
Examples
|
|
898
|
+
--------
|
|
899
|
+
from brevo import Brevo
|
|
900
|
+
|
|
901
|
+
client = Brevo(
|
|
902
|
+
api_key="YOUR_API_KEY",
|
|
903
|
+
)
|
|
904
|
+
client.ecommerce.create_update_product(
|
|
905
|
+
id="P11",
|
|
906
|
+
name="Iphone 11",
|
|
907
|
+
)
|
|
908
|
+
"""
|
|
909
|
+
_response = self._raw_client.create_update_product(
|
|
910
|
+
id=id,
|
|
911
|
+
name=name,
|
|
912
|
+
categories=categories,
|
|
913
|
+
deleted_at=deleted_at,
|
|
914
|
+
image_url=image_url,
|
|
915
|
+
is_deleted=is_deleted,
|
|
916
|
+
meta_info=meta_info,
|
|
917
|
+
parent_id=parent_id,
|
|
918
|
+
price=price,
|
|
919
|
+
sku=sku,
|
|
920
|
+
stock=stock,
|
|
921
|
+
update_enabled=update_enabled,
|
|
922
|
+
url=url,
|
|
923
|
+
request_options=request_options,
|
|
924
|
+
)
|
|
925
|
+
return _response.data
|
|
926
|
+
|
|
927
|
+
def create_update_batch_products(
|
|
928
|
+
self,
|
|
929
|
+
*,
|
|
930
|
+
products: typing.Sequence[CreateUpdateBatchProductsRequestProductsItem],
|
|
931
|
+
update_enabled: typing.Optional[bool] = OMIT,
|
|
932
|
+
request_options: typing.Optional[RequestOptions] = None,
|
|
933
|
+
) -> CreateUpdateBatchProductsResponse:
|
|
934
|
+
"""
|
|
935
|
+
Parameters
|
|
936
|
+
----------
|
|
937
|
+
products : typing.Sequence[CreateUpdateBatchProductsRequestProductsItem]
|
|
938
|
+
array of products objects
|
|
939
|
+
|
|
940
|
+
update_enabled : typing.Optional[bool]
|
|
941
|
+
Facilitate to update the existing categories in the same request (updateEnabled = true)
|
|
942
|
+
|
|
943
|
+
request_options : typing.Optional[RequestOptions]
|
|
944
|
+
Request-specific configuration.
|
|
945
|
+
|
|
946
|
+
Returns
|
|
947
|
+
-------
|
|
948
|
+
CreateUpdateBatchProductsResponse
|
|
949
|
+
Products created and updated
|
|
950
|
+
|
|
951
|
+
Examples
|
|
952
|
+
--------
|
|
953
|
+
from brevo import Brevo
|
|
954
|
+
from brevo.ecommerce import CreateUpdateBatchProductsRequestProductsItem
|
|
955
|
+
|
|
956
|
+
client = Brevo(
|
|
957
|
+
api_key="YOUR_API_KEY",
|
|
958
|
+
)
|
|
959
|
+
client.ecommerce.create_update_batch_products(
|
|
960
|
+
products=[
|
|
961
|
+
CreateUpdateBatchProductsRequestProductsItem(
|
|
962
|
+
id="P11",
|
|
963
|
+
name="Iphone 11",
|
|
964
|
+
)
|
|
965
|
+
],
|
|
966
|
+
)
|
|
967
|
+
"""
|
|
968
|
+
_response = self._raw_client.create_update_batch_products(
|
|
969
|
+
products=products, update_enabled=update_enabled, request_options=request_options
|
|
970
|
+
)
|
|
971
|
+
return _response.data
|
|
972
|
+
|
|
973
|
+
def get_product_info(
|
|
974
|
+
self, id: str, *, request_options: typing.Optional[RequestOptions] = None
|
|
975
|
+
) -> GetProductDetails:
|
|
976
|
+
"""
|
|
977
|
+
Parameters
|
|
978
|
+
----------
|
|
979
|
+
id : str
|
|
980
|
+
Product ID
|
|
981
|
+
|
|
982
|
+
request_options : typing.Optional[RequestOptions]
|
|
983
|
+
Request-specific configuration.
|
|
984
|
+
|
|
985
|
+
Returns
|
|
986
|
+
-------
|
|
987
|
+
GetProductDetails
|
|
988
|
+
Product informations
|
|
989
|
+
|
|
990
|
+
Examples
|
|
991
|
+
--------
|
|
992
|
+
from brevo import Brevo
|
|
993
|
+
|
|
994
|
+
client = Brevo(
|
|
995
|
+
api_key="YOUR_API_KEY",
|
|
996
|
+
)
|
|
997
|
+
client.ecommerce.get_product_info(
|
|
998
|
+
id="id",
|
|
999
|
+
)
|
|
1000
|
+
"""
|
|
1001
|
+
_response = self._raw_client.get_product_info(id, request_options=request_options)
|
|
1002
|
+
return _response.data
|
|
1003
|
+
|
|
1004
|
+
def create_product_alert(
|
|
1005
|
+
self,
|
|
1006
|
+
id: str,
|
|
1007
|
+
*,
|
|
1008
|
+
contact_identifiers: typing.Optional[CreateProductAlertRequestContactIdentifiers] = OMIT,
|
|
1009
|
+
request_options: typing.Optional[RequestOptions] = None,
|
|
1010
|
+
) -> None:
|
|
1011
|
+
"""
|
|
1012
|
+
Parameters
|
|
1013
|
+
----------
|
|
1014
|
+
id : str
|
|
1015
|
+
Product ID
|
|
1016
|
+
|
|
1017
|
+
contact_identifiers : typing.Optional[CreateProductAlertRequestContactIdentifiers]
|
|
1018
|
+
|
|
1019
|
+
request_options : typing.Optional[RequestOptions]
|
|
1020
|
+
Request-specific configuration.
|
|
1021
|
+
|
|
1022
|
+
Returns
|
|
1023
|
+
-------
|
|
1024
|
+
None
|
|
1025
|
+
|
|
1026
|
+
Examples
|
|
1027
|
+
--------
|
|
1028
|
+
from brevo import Brevo
|
|
1029
|
+
|
|
1030
|
+
client = Brevo(
|
|
1031
|
+
api_key="YOUR_API_KEY",
|
|
1032
|
+
)
|
|
1033
|
+
client.ecommerce.create_product_alert(
|
|
1034
|
+
id="id",
|
|
1035
|
+
)
|
|
1036
|
+
"""
|
|
1037
|
+
_response = self._raw_client.create_product_alert(
|
|
1038
|
+
id, contact_identifiers=contact_identifiers, request_options=request_options
|
|
1039
|
+
)
|
|
1040
|
+
return _response.data
|
|
1041
|
+
|
|
1042
|
+
|
|
1043
|
+
class AsyncEcommerceClient:
|
|
1044
|
+
def __init__(self, *, client_wrapper: AsyncClientWrapper):
|
|
1045
|
+
self._raw_client = AsyncRawEcommerceClient(client_wrapper=client_wrapper)
|
|
1046
|
+
|
|
1047
|
+
@property
|
|
1048
|
+
def with_raw_response(self) -> AsyncRawEcommerceClient:
|
|
1049
|
+
"""
|
|
1050
|
+
Retrieves a raw implementation of this client that returns raw responses.
|
|
1051
|
+
|
|
1052
|
+
Returns
|
|
1053
|
+
-------
|
|
1054
|
+
AsyncRawEcommerceClient
|
|
1055
|
+
"""
|
|
1056
|
+
return self._raw_client
|
|
1057
|
+
|
|
1058
|
+
async def get_categories(
|
|
1059
|
+
self,
|
|
1060
|
+
*,
|
|
1061
|
+
limit: typing.Optional[int] = None,
|
|
1062
|
+
offset: typing.Optional[int] = None,
|
|
1063
|
+
sort: typing.Optional[GetCategoriesRequestSort] = None,
|
|
1064
|
+
ids: typing.Optional[typing.Union[str, typing.Sequence[str]]] = None,
|
|
1065
|
+
name: typing.Optional[str] = None,
|
|
1066
|
+
modified_since: typing.Optional[str] = None,
|
|
1067
|
+
created_since: typing.Optional[str] = None,
|
|
1068
|
+
is_deleted: typing.Optional[str] = None,
|
|
1069
|
+
request_options: typing.Optional[RequestOptions] = None,
|
|
1070
|
+
) -> GetCategoriesResponse:
|
|
1071
|
+
"""
|
|
1072
|
+
Parameters
|
|
1073
|
+
----------
|
|
1074
|
+
limit : typing.Optional[int]
|
|
1075
|
+
Number of documents per page
|
|
1076
|
+
|
|
1077
|
+
offset : typing.Optional[int]
|
|
1078
|
+
Index of the first document in the page
|
|
1079
|
+
|
|
1080
|
+
sort : typing.Optional[GetCategoriesRequestSort]
|
|
1081
|
+
Sort the results in the ascending/descending order of record creation. Default order is **descending** if `sort` is not passed
|
|
1082
|
+
|
|
1083
|
+
ids : typing.Optional[typing.Union[str, typing.Sequence[str]]]
|
|
1084
|
+
Filter by category ids
|
|
1085
|
+
|
|
1086
|
+
name : typing.Optional[str]
|
|
1087
|
+
Filter by category name
|
|
1088
|
+
|
|
1089
|
+
modified_since : typing.Optional[str]
|
|
1090
|
+
Filter (urlencoded) the categories modified after a given UTC date-time (YYYY-MM-DDTHH:mm:ss.SSSZ). **Prefer to pass your timezone in date-time format for accurate result.**
|
|
1091
|
+
|
|
1092
|
+
created_since : typing.Optional[str]
|
|
1093
|
+
Filter (urlencoded) the categories created after a given UTC date-time (YYYY-MM-DDTHH:mm:ss.SSSZ). **Prefer to pass your timezone in date-time format for accurate result.**
|
|
1094
|
+
|
|
1095
|
+
is_deleted : typing.Optional[str]
|
|
1096
|
+
Filter categories by their deletion status. If `false` is passed, only categories that are not deleted will be returned.
|
|
1097
|
+
|
|
1098
|
+
request_options : typing.Optional[RequestOptions]
|
|
1099
|
+
Request-specific configuration.
|
|
1100
|
+
|
|
1101
|
+
Returns
|
|
1102
|
+
-------
|
|
1103
|
+
GetCategoriesResponse
|
|
1104
|
+
All categories listed
|
|
1105
|
+
|
|
1106
|
+
Examples
|
|
1107
|
+
--------
|
|
1108
|
+
import asyncio
|
|
1109
|
+
|
|
1110
|
+
from brevo import AsyncBrevo
|
|
1111
|
+
|
|
1112
|
+
client = AsyncBrevo(
|
|
1113
|
+
api_key="YOUR_API_KEY",
|
|
1114
|
+
)
|
|
1115
|
+
|
|
1116
|
+
|
|
1117
|
+
async def main() -> None:
|
|
1118
|
+
await client.ecommerce.get_categories()
|
|
1119
|
+
|
|
1120
|
+
|
|
1121
|
+
asyncio.run(main())
|
|
1122
|
+
"""
|
|
1123
|
+
_response = await self._raw_client.get_categories(
|
|
1124
|
+
limit=limit,
|
|
1125
|
+
offset=offset,
|
|
1126
|
+
sort=sort,
|
|
1127
|
+
ids=ids,
|
|
1128
|
+
name=name,
|
|
1129
|
+
modified_since=modified_since,
|
|
1130
|
+
created_since=created_since,
|
|
1131
|
+
is_deleted=is_deleted,
|
|
1132
|
+
request_options=request_options,
|
|
1133
|
+
)
|
|
1134
|
+
return _response.data
|
|
1135
|
+
|
|
1136
|
+
async def create_update_category(
|
|
1137
|
+
self,
|
|
1138
|
+
*,
|
|
1139
|
+
id: str,
|
|
1140
|
+
deleted_at: typing.Optional[str] = OMIT,
|
|
1141
|
+
is_deleted: typing.Optional[bool] = OMIT,
|
|
1142
|
+
name: typing.Optional[str] = OMIT,
|
|
1143
|
+
update_enabled: typing.Optional[bool] = OMIT,
|
|
1144
|
+
url: typing.Optional[str] = OMIT,
|
|
1145
|
+
request_options: typing.Optional[RequestOptions] = None,
|
|
1146
|
+
) -> CreateUpdateCategoryResponse:
|
|
1147
|
+
"""
|
|
1148
|
+
Parameters
|
|
1149
|
+
----------
|
|
1150
|
+
id : str
|
|
1151
|
+
Unique Category ID as saved in the shop
|
|
1152
|
+
|
|
1153
|
+
deleted_at : typing.Optional[str]
|
|
1154
|
+
UTC date-time (YYYY-MM-DDTHH:mm:ss.SSSZ) of the category deleted from the shop's database
|
|
1155
|
+
|
|
1156
|
+
is_deleted : typing.Optional[bool]
|
|
1157
|
+
category deleted from the shop's database
|
|
1158
|
+
|
|
1159
|
+
name : typing.Optional[str]
|
|
1160
|
+
**Mandatory in case of creation**. Name of the Category, as displayed in the shop
|
|
1161
|
+
|
|
1162
|
+
update_enabled : typing.Optional[bool]
|
|
1163
|
+
Facilitate to update the existing category in the same request (updateEnabled = true)
|
|
1164
|
+
|
|
1165
|
+
url : typing.Optional[str]
|
|
1166
|
+
URL to the category
|
|
1167
|
+
|
|
1168
|
+
request_options : typing.Optional[RequestOptions]
|
|
1169
|
+
Request-specific configuration.
|
|
1170
|
+
|
|
1171
|
+
Returns
|
|
1172
|
+
-------
|
|
1173
|
+
CreateUpdateCategoryResponse
|
|
1174
|
+
Category created
|
|
1175
|
+
|
|
1176
|
+
Examples
|
|
1177
|
+
--------
|
|
1178
|
+
import asyncio
|
|
1179
|
+
|
|
1180
|
+
from brevo import AsyncBrevo
|
|
1181
|
+
|
|
1182
|
+
client = AsyncBrevo(
|
|
1183
|
+
api_key="YOUR_API_KEY",
|
|
1184
|
+
)
|
|
1185
|
+
|
|
1186
|
+
|
|
1187
|
+
async def main() -> None:
|
|
1188
|
+
await client.ecommerce.create_update_category(
|
|
1189
|
+
id="CAT123",
|
|
1190
|
+
)
|
|
1191
|
+
|
|
1192
|
+
|
|
1193
|
+
asyncio.run(main())
|
|
1194
|
+
"""
|
|
1195
|
+
_response = await self._raw_client.create_update_category(
|
|
1196
|
+
id=id,
|
|
1197
|
+
deleted_at=deleted_at,
|
|
1198
|
+
is_deleted=is_deleted,
|
|
1199
|
+
name=name,
|
|
1200
|
+
update_enabled=update_enabled,
|
|
1201
|
+
url=url,
|
|
1202
|
+
request_options=request_options,
|
|
1203
|
+
)
|
|
1204
|
+
return _response.data
|
|
1205
|
+
|
|
1206
|
+
async def create_update_batch_category(
|
|
1207
|
+
self,
|
|
1208
|
+
*,
|
|
1209
|
+
categories: typing.Sequence[CreateUpdateBatchCategoryRequestCategoriesItem],
|
|
1210
|
+
update_enabled: typing.Optional[bool] = OMIT,
|
|
1211
|
+
request_options: typing.Optional[RequestOptions] = None,
|
|
1212
|
+
) -> CreateUpdateBatchCategoryResponse:
|
|
1213
|
+
"""
|
|
1214
|
+
Parameters
|
|
1215
|
+
----------
|
|
1216
|
+
categories : typing.Sequence[CreateUpdateBatchCategoryRequestCategoriesItem]
|
|
1217
|
+
array of categories objects
|
|
1218
|
+
|
|
1219
|
+
update_enabled : typing.Optional[bool]
|
|
1220
|
+
Facilitate to update the existing categories in the same request (updateEnabled = true)
|
|
1221
|
+
|
|
1222
|
+
request_options : typing.Optional[RequestOptions]
|
|
1223
|
+
Request-specific configuration.
|
|
1224
|
+
|
|
1225
|
+
Returns
|
|
1226
|
+
-------
|
|
1227
|
+
CreateUpdateBatchCategoryResponse
|
|
1228
|
+
Category created and updated
|
|
1229
|
+
|
|
1230
|
+
Examples
|
|
1231
|
+
--------
|
|
1232
|
+
import asyncio
|
|
1233
|
+
|
|
1234
|
+
from brevo import AsyncBrevo
|
|
1235
|
+
from brevo.ecommerce import CreateUpdateBatchCategoryRequestCategoriesItem
|
|
1236
|
+
|
|
1237
|
+
client = AsyncBrevo(
|
|
1238
|
+
api_key="YOUR_API_KEY",
|
|
1239
|
+
)
|
|
1240
|
+
|
|
1241
|
+
|
|
1242
|
+
async def main() -> None:
|
|
1243
|
+
await client.ecommerce.create_update_batch_category(
|
|
1244
|
+
categories=[
|
|
1245
|
+
CreateUpdateBatchCategoryRequestCategoriesItem(
|
|
1246
|
+
id="CAT123",
|
|
1247
|
+
)
|
|
1248
|
+
],
|
|
1249
|
+
)
|
|
1250
|
+
|
|
1251
|
+
|
|
1252
|
+
asyncio.run(main())
|
|
1253
|
+
"""
|
|
1254
|
+
_response = await self._raw_client.create_update_batch_category(
|
|
1255
|
+
categories=categories, update_enabled=update_enabled, request_options=request_options
|
|
1256
|
+
)
|
|
1257
|
+
return _response.data
|
|
1258
|
+
|
|
1259
|
+
async def get_category_info(
|
|
1260
|
+
self, id: str, *, request_options: typing.Optional[RequestOptions] = None
|
|
1261
|
+
) -> GetCategoryDetails:
|
|
1262
|
+
"""
|
|
1263
|
+
Parameters
|
|
1264
|
+
----------
|
|
1265
|
+
id : str
|
|
1266
|
+
Category ID
|
|
1267
|
+
|
|
1268
|
+
request_options : typing.Optional[RequestOptions]
|
|
1269
|
+
Request-specific configuration.
|
|
1270
|
+
|
|
1271
|
+
Returns
|
|
1272
|
+
-------
|
|
1273
|
+
GetCategoryDetails
|
|
1274
|
+
Category informations
|
|
1275
|
+
|
|
1276
|
+
Examples
|
|
1277
|
+
--------
|
|
1278
|
+
import asyncio
|
|
1279
|
+
|
|
1280
|
+
from brevo import AsyncBrevo
|
|
1281
|
+
|
|
1282
|
+
client = AsyncBrevo(
|
|
1283
|
+
api_key="YOUR_API_KEY",
|
|
1284
|
+
)
|
|
1285
|
+
|
|
1286
|
+
|
|
1287
|
+
async def main() -> None:
|
|
1288
|
+
await client.ecommerce.get_category_info(
|
|
1289
|
+
id="id",
|
|
1290
|
+
)
|
|
1291
|
+
|
|
1292
|
+
|
|
1293
|
+
asyncio.run(main())
|
|
1294
|
+
"""
|
|
1295
|
+
_response = await self._raw_client.get_category_info(id, request_options=request_options)
|
|
1296
|
+
return _response.data
|
|
1297
|
+
|
|
1298
|
+
async def activate_the_e_commerce_app(self, *, request_options: typing.Optional[RequestOptions] = None) -> None:
|
|
1299
|
+
"""
|
|
1300
|
+
Getting access to Brevo eCommerce.
|
|
1301
|
+
|
|
1302
|
+
Parameters
|
|
1303
|
+
----------
|
|
1304
|
+
request_options : typing.Optional[RequestOptions]
|
|
1305
|
+
Request-specific configuration.
|
|
1306
|
+
|
|
1307
|
+
Returns
|
|
1308
|
+
-------
|
|
1309
|
+
None
|
|
1310
|
+
|
|
1311
|
+
Examples
|
|
1312
|
+
--------
|
|
1313
|
+
import asyncio
|
|
1314
|
+
|
|
1315
|
+
from brevo import AsyncBrevo
|
|
1316
|
+
|
|
1317
|
+
client = AsyncBrevo(
|
|
1318
|
+
api_key="YOUR_API_KEY",
|
|
1319
|
+
)
|
|
1320
|
+
|
|
1321
|
+
|
|
1322
|
+
async def main() -> None:
|
|
1323
|
+
await client.ecommerce.activate_the_e_commerce_app()
|
|
1324
|
+
|
|
1325
|
+
|
|
1326
|
+
asyncio.run(main())
|
|
1327
|
+
"""
|
|
1328
|
+
_response = await self._raw_client.activate_the_e_commerce_app(request_options=request_options)
|
|
1329
|
+
return _response.data
|
|
1330
|
+
|
|
1331
|
+
async def get_attribution_metrics_for_one_or_more_brevo_campaigns_or_workflows(
|
|
1332
|
+
self,
|
|
1333
|
+
*,
|
|
1334
|
+
period_from: typing.Optional[dt.datetime] = None,
|
|
1335
|
+
period_to: typing.Optional[dt.datetime] = None,
|
|
1336
|
+
email_campaign_id_array: typing.Optional[typing.Union[str, typing.Sequence[str]]] = None,
|
|
1337
|
+
sms_campaign_id_array: typing.Optional[typing.Union[str, typing.Sequence[str]]] = None,
|
|
1338
|
+
automation_workflow_email_id_array: typing.Optional[typing.Union[str, typing.Sequence[str]]] = None,
|
|
1339
|
+
automation_workflow_sms_id_array: typing.Optional[typing.Union[str, typing.Sequence[str]]] = None,
|
|
1340
|
+
request_options: typing.Optional[RequestOptions] = None,
|
|
1341
|
+
) -> GetEcommerceAttributionMetricsResponse:
|
|
1342
|
+
"""
|
|
1343
|
+
Parameters
|
|
1344
|
+
----------
|
|
1345
|
+
period_from : typing.Optional[dt.datetime]
|
|
1346
|
+
When getting metrics for a specific period, define the starting datetime in RFC3339 format
|
|
1347
|
+
|
|
1348
|
+
period_to : typing.Optional[dt.datetime]
|
|
1349
|
+
When getting metrics for a specific period, define the end datetime in RFC3339 format
|
|
1350
|
+
|
|
1351
|
+
email_campaign_id_array : typing.Optional[typing.Union[str, typing.Sequence[str]]]
|
|
1352
|
+
The email campaign ID(s) to get metrics for
|
|
1353
|
+
|
|
1354
|
+
sms_campaign_id_array : typing.Optional[typing.Union[str, typing.Sequence[str]]]
|
|
1355
|
+
The SMS campaign ID(s) to get metrics for
|
|
1356
|
+
|
|
1357
|
+
automation_workflow_email_id_array : typing.Optional[typing.Union[str, typing.Sequence[str]]]
|
|
1358
|
+
The automation workflow ID(s) to get email attribution metrics for
|
|
1359
|
+
|
|
1360
|
+
automation_workflow_sms_id_array : typing.Optional[typing.Union[str, typing.Sequence[str]]]
|
|
1361
|
+
The automation workflow ID(s) to get SMS attribution metrics for
|
|
1362
|
+
|
|
1363
|
+
request_options : typing.Optional[RequestOptions]
|
|
1364
|
+
Request-specific configuration.
|
|
1365
|
+
|
|
1366
|
+
Returns
|
|
1367
|
+
-------
|
|
1368
|
+
GetEcommerceAttributionMetricsResponse
|
|
1369
|
+
OK
|
|
1370
|
+
|
|
1371
|
+
Examples
|
|
1372
|
+
--------
|
|
1373
|
+
import asyncio
|
|
1374
|
+
import datetime
|
|
1375
|
+
|
|
1376
|
+
from brevo import AsyncBrevo
|
|
1377
|
+
|
|
1378
|
+
client = AsyncBrevo(
|
|
1379
|
+
api_key="YOUR_API_KEY",
|
|
1380
|
+
)
|
|
1381
|
+
|
|
1382
|
+
|
|
1383
|
+
async def main() -> None:
|
|
1384
|
+
await client.ecommerce.get_attribution_metrics_for_one_or_more_brevo_campaigns_or_workflows(
|
|
1385
|
+
period_from=datetime.datetime.fromisoformat(
|
|
1386
|
+
"2022-01-02 00:00:00+00:00",
|
|
1387
|
+
),
|
|
1388
|
+
period_to=datetime.datetime.fromisoformat(
|
|
1389
|
+
"2022-01-03 00:00:00+00:00",
|
|
1390
|
+
),
|
|
1391
|
+
)
|
|
1392
|
+
|
|
1393
|
+
|
|
1394
|
+
asyncio.run(main())
|
|
1395
|
+
"""
|
|
1396
|
+
_response = await self._raw_client.get_attribution_metrics_for_one_or_more_brevo_campaigns_or_workflows(
|
|
1397
|
+
period_from=period_from,
|
|
1398
|
+
period_to=period_to,
|
|
1399
|
+
email_campaign_id_array=email_campaign_id_array,
|
|
1400
|
+
sms_campaign_id_array=sms_campaign_id_array,
|
|
1401
|
+
automation_workflow_email_id_array=automation_workflow_email_id_array,
|
|
1402
|
+
automation_workflow_sms_id_array=automation_workflow_sms_id_array,
|
|
1403
|
+
request_options=request_options,
|
|
1404
|
+
)
|
|
1405
|
+
return _response.data
|
|
1406
|
+
|
|
1407
|
+
async def get_detailed_attribution_metrics_for_a_single_brevo_campaign_or_workflow(
|
|
1408
|
+
self,
|
|
1409
|
+
conversion_source: GetEcommerceAttributionMetricsConversionSourceConversionSourceIdRequestConversionSource,
|
|
1410
|
+
conversion_source_id: str,
|
|
1411
|
+
*,
|
|
1412
|
+
request_options: typing.Optional[RequestOptions] = None,
|
|
1413
|
+
) -> GetEcommerceAttributionMetricsConversionSourceConversionSourceIdResponse:
|
|
1414
|
+
"""
|
|
1415
|
+
Parameters
|
|
1416
|
+
----------
|
|
1417
|
+
conversion_source : GetEcommerceAttributionMetricsConversionSourceConversionSourceIdRequestConversionSource
|
|
1418
|
+
The Brevo campaign type or workflow type for which data will be retrieved
|
|
1419
|
+
|
|
1420
|
+
conversion_source_id : str
|
|
1421
|
+
The Brevo campaign or automation workflow id for which data will be retrieved
|
|
1422
|
+
|
|
1423
|
+
request_options : typing.Optional[RequestOptions]
|
|
1424
|
+
Request-specific configuration.
|
|
1425
|
+
|
|
1426
|
+
Returns
|
|
1427
|
+
-------
|
|
1428
|
+
GetEcommerceAttributionMetricsConversionSourceConversionSourceIdResponse
|
|
1429
|
+
OK
|
|
1430
|
+
|
|
1431
|
+
Examples
|
|
1432
|
+
--------
|
|
1433
|
+
import asyncio
|
|
1434
|
+
|
|
1435
|
+
from brevo import AsyncBrevo
|
|
1436
|
+
|
|
1437
|
+
client = AsyncBrevo(
|
|
1438
|
+
api_key="YOUR_API_KEY",
|
|
1439
|
+
)
|
|
1440
|
+
|
|
1441
|
+
|
|
1442
|
+
async def main() -> None:
|
|
1443
|
+
await client.ecommerce.get_detailed_attribution_metrics_for_a_single_brevo_campaign_or_workflow(
|
|
1444
|
+
conversion_source="email_campaign",
|
|
1445
|
+
conversion_source_id="sale",
|
|
1446
|
+
)
|
|
1447
|
+
|
|
1448
|
+
|
|
1449
|
+
asyncio.run(main())
|
|
1450
|
+
"""
|
|
1451
|
+
_response = await self._raw_client.get_detailed_attribution_metrics_for_a_single_brevo_campaign_or_workflow(
|
|
1452
|
+
conversion_source, conversion_source_id, request_options=request_options
|
|
1453
|
+
)
|
|
1454
|
+
return _response.data
|
|
1455
|
+
|
|
1456
|
+
async def get_attributed_product_sales_for_a_single_brevo_campaign_or_workflow(
|
|
1457
|
+
self,
|
|
1458
|
+
conversion_source: GetEcommerceAttributionProductsConversionSourceConversionSourceIdRequestConversionSource,
|
|
1459
|
+
conversion_source_id: str,
|
|
1460
|
+
*,
|
|
1461
|
+
request_options: typing.Optional[RequestOptions] = None,
|
|
1462
|
+
) -> GetEcommerceAttributionProductsConversionSourceConversionSourceIdResponse:
|
|
1463
|
+
"""
|
|
1464
|
+
Parameters
|
|
1465
|
+
----------
|
|
1466
|
+
conversion_source : GetEcommerceAttributionProductsConversionSourceConversionSourceIdRequestConversionSource
|
|
1467
|
+
The Brevo campaign or automation workflow type for which data will be retrieved
|
|
1468
|
+
|
|
1469
|
+
conversion_source_id : str
|
|
1470
|
+
The Brevo campaign or automation workflow id for which data will be retrieved
|
|
1471
|
+
|
|
1472
|
+
request_options : typing.Optional[RequestOptions]
|
|
1473
|
+
Request-specific configuration.
|
|
1474
|
+
|
|
1475
|
+
Returns
|
|
1476
|
+
-------
|
|
1477
|
+
GetEcommerceAttributionProductsConversionSourceConversionSourceIdResponse
|
|
1478
|
+
OK
|
|
1479
|
+
|
|
1480
|
+
Examples
|
|
1481
|
+
--------
|
|
1482
|
+
import asyncio
|
|
1483
|
+
|
|
1484
|
+
from brevo import AsyncBrevo
|
|
1485
|
+
|
|
1486
|
+
client = AsyncBrevo(
|
|
1487
|
+
api_key="YOUR_API_KEY",
|
|
1488
|
+
)
|
|
1489
|
+
|
|
1490
|
+
|
|
1491
|
+
async def main() -> None:
|
|
1492
|
+
await client.ecommerce.get_attributed_product_sales_for_a_single_brevo_campaign_or_workflow(
|
|
1493
|
+
conversion_source="email_campaign",
|
|
1494
|
+
conversion_source_id="sale",
|
|
1495
|
+
)
|
|
1496
|
+
|
|
1497
|
+
|
|
1498
|
+
asyncio.run(main())
|
|
1499
|
+
"""
|
|
1500
|
+
_response = await self._raw_client.get_attributed_product_sales_for_a_single_brevo_campaign_or_workflow(
|
|
1501
|
+
conversion_source, conversion_source_id, request_options=request_options
|
|
1502
|
+
)
|
|
1503
|
+
return _response.data
|
|
1504
|
+
|
|
1505
|
+
async def get_the_iso4217compliant_display_currency_code_for_your_brevo_account(
|
|
1506
|
+
self, *, request_options: typing.Optional[RequestOptions] = None
|
|
1507
|
+
) -> GetEcommerceConfigDisplayCurrencyResponse:
|
|
1508
|
+
"""
|
|
1509
|
+
Parameters
|
|
1510
|
+
----------
|
|
1511
|
+
request_options : typing.Optional[RequestOptions]
|
|
1512
|
+
Request-specific configuration.
|
|
1513
|
+
|
|
1514
|
+
Returns
|
|
1515
|
+
-------
|
|
1516
|
+
GetEcommerceConfigDisplayCurrencyResponse
|
|
1517
|
+
OK
|
|
1518
|
+
|
|
1519
|
+
Examples
|
|
1520
|
+
--------
|
|
1521
|
+
import asyncio
|
|
1522
|
+
|
|
1523
|
+
from brevo import AsyncBrevo
|
|
1524
|
+
|
|
1525
|
+
client = AsyncBrevo(
|
|
1526
|
+
api_key="YOUR_API_KEY",
|
|
1527
|
+
)
|
|
1528
|
+
|
|
1529
|
+
|
|
1530
|
+
async def main() -> None:
|
|
1531
|
+
await client.ecommerce.get_the_iso4217compliant_display_currency_code_for_your_brevo_account()
|
|
1532
|
+
|
|
1533
|
+
|
|
1534
|
+
asyncio.run(main())
|
|
1535
|
+
"""
|
|
1536
|
+
_response = await self._raw_client.get_the_iso4217compliant_display_currency_code_for_your_brevo_account(
|
|
1537
|
+
request_options=request_options
|
|
1538
|
+
)
|
|
1539
|
+
return _response.data
|
|
1540
|
+
|
|
1541
|
+
async def set_config_display_currency(
|
|
1542
|
+
self, *, code: str, request_options: typing.Optional[RequestOptions] = None
|
|
1543
|
+
) -> SetConfigDisplayCurrencyResponse:
|
|
1544
|
+
"""
|
|
1545
|
+
Parameters
|
|
1546
|
+
----------
|
|
1547
|
+
code : str
|
|
1548
|
+
ISO 4217 compliant display currency code
|
|
1549
|
+
|
|
1550
|
+
request_options : typing.Optional[RequestOptions]
|
|
1551
|
+
Request-specific configuration.
|
|
1552
|
+
|
|
1553
|
+
Returns
|
|
1554
|
+
-------
|
|
1555
|
+
SetConfigDisplayCurrencyResponse
|
|
1556
|
+
OK
|
|
1557
|
+
|
|
1558
|
+
Examples
|
|
1559
|
+
--------
|
|
1560
|
+
import asyncio
|
|
1561
|
+
|
|
1562
|
+
from brevo import AsyncBrevo
|
|
1563
|
+
|
|
1564
|
+
client = AsyncBrevo(
|
|
1565
|
+
api_key="YOUR_API_KEY",
|
|
1566
|
+
)
|
|
1567
|
+
|
|
1568
|
+
|
|
1569
|
+
async def main() -> None:
|
|
1570
|
+
await client.ecommerce.set_config_display_currency(
|
|
1571
|
+
code="EUR",
|
|
1572
|
+
)
|
|
1573
|
+
|
|
1574
|
+
|
|
1575
|
+
asyncio.run(main())
|
|
1576
|
+
"""
|
|
1577
|
+
_response = await self._raw_client.set_config_display_currency(code=code, request_options=request_options)
|
|
1578
|
+
return _response.data
|
|
1579
|
+
|
|
1580
|
+
async def get_orders(
|
|
1581
|
+
self,
|
|
1582
|
+
*,
|
|
1583
|
+
limit: typing.Optional[int] = None,
|
|
1584
|
+
offset: typing.Optional[int] = None,
|
|
1585
|
+
sort: typing.Optional[GetOrdersRequestSort] = None,
|
|
1586
|
+
modified_since: typing.Optional[str] = None,
|
|
1587
|
+
created_since: typing.Optional[str] = None,
|
|
1588
|
+
request_options: typing.Optional[RequestOptions] = None,
|
|
1589
|
+
) -> typing.Any:
|
|
1590
|
+
"""
|
|
1591
|
+
Get all the orders
|
|
1592
|
+
|
|
1593
|
+
Parameters
|
|
1594
|
+
----------
|
|
1595
|
+
limit : typing.Optional[int]
|
|
1596
|
+
Number of documents per page
|
|
1597
|
+
|
|
1598
|
+
offset : typing.Optional[int]
|
|
1599
|
+
Index of the first document in the page
|
|
1600
|
+
|
|
1601
|
+
sort : typing.Optional[GetOrdersRequestSort]
|
|
1602
|
+
Sort the results in the ascending/descending order of record creation. Default order is **descending** if `sort` is not passed
|
|
1603
|
+
|
|
1604
|
+
modified_since : typing.Optional[str]
|
|
1605
|
+
Filter (urlencoded) the orders modified after a given UTC date-time (YYYY-MM-DDTHH:mm:ss.SSSZ). **Prefer to pass your timezone in date-time format for accurate result.**
|
|
1606
|
+
|
|
1607
|
+
created_since : typing.Optional[str]
|
|
1608
|
+
Filter (urlencoded) the orders created after a given UTC date-time (YYYY-MM-DDTHH:mm:ss.SSSZ). **Prefer to pass your timezone in date-time format for accurate result.**
|
|
1609
|
+
|
|
1610
|
+
request_options : typing.Optional[RequestOptions]
|
|
1611
|
+
Request-specific configuration.
|
|
1612
|
+
|
|
1613
|
+
Returns
|
|
1614
|
+
-------
|
|
1615
|
+
typing.Any
|
|
1616
|
+
orders fetched successfully
|
|
1617
|
+
|
|
1618
|
+
Examples
|
|
1619
|
+
--------
|
|
1620
|
+
import asyncio
|
|
1621
|
+
|
|
1622
|
+
from brevo import AsyncBrevo
|
|
1623
|
+
|
|
1624
|
+
client = AsyncBrevo(
|
|
1625
|
+
api_key="YOUR_API_KEY",
|
|
1626
|
+
)
|
|
1627
|
+
|
|
1628
|
+
|
|
1629
|
+
async def main() -> None:
|
|
1630
|
+
await client.ecommerce.get_orders()
|
|
1631
|
+
|
|
1632
|
+
|
|
1633
|
+
asyncio.run(main())
|
|
1634
|
+
"""
|
|
1635
|
+
_response = await self._raw_client.get_orders(
|
|
1636
|
+
limit=limit,
|
|
1637
|
+
offset=offset,
|
|
1638
|
+
sort=sort,
|
|
1639
|
+
modified_since=modified_since,
|
|
1640
|
+
created_since=created_since,
|
|
1641
|
+
request_options=request_options,
|
|
1642
|
+
)
|
|
1643
|
+
return _response.data
|
|
1644
|
+
|
|
1645
|
+
async def create_order(
|
|
1646
|
+
self,
|
|
1647
|
+
*,
|
|
1648
|
+
amount: float,
|
|
1649
|
+
created_at: str,
|
|
1650
|
+
id: str,
|
|
1651
|
+
products: typing.Sequence[OrderProductsItem],
|
|
1652
|
+
status: str,
|
|
1653
|
+
updated_at: str,
|
|
1654
|
+
billing: typing.Optional[OrderBilling] = OMIT,
|
|
1655
|
+
coupons: typing.Optional[typing.Sequence[str]] = OMIT,
|
|
1656
|
+
identifiers: typing.Optional[OrderIdentifiers] = OMIT,
|
|
1657
|
+
meta_info: typing.Optional[typing.Dict[str, OrderMetaInfoValue]] = OMIT,
|
|
1658
|
+
store_id: typing.Optional[str] = OMIT,
|
|
1659
|
+
request_options: typing.Optional[RequestOptions] = None,
|
|
1660
|
+
) -> None:
|
|
1661
|
+
"""
|
|
1662
|
+
Manages the transactional status of the order
|
|
1663
|
+
|
|
1664
|
+
Parameters
|
|
1665
|
+
----------
|
|
1666
|
+
amount : float
|
|
1667
|
+
Total amount of the order, including all shipping expenses, tax and the price of items.
|
|
1668
|
+
|
|
1669
|
+
created_at : str
|
|
1670
|
+
Event occurrence UTC date-time (YYYY-MM-DDTHH:mm:ssZ), when order is actually created.
|
|
1671
|
+
|
|
1672
|
+
id : str
|
|
1673
|
+
Unique ID of the order.
|
|
1674
|
+
|
|
1675
|
+
products : typing.Sequence[OrderProductsItem]
|
|
1676
|
+
|
|
1677
|
+
status : str
|
|
1678
|
+
State of the order.
|
|
1679
|
+
|
|
1680
|
+
updated_at : str
|
|
1681
|
+
Event updated UTC date-time (YYYY-MM-DDTHH:mm:ssZ), when the status of the order is actually changed/updated.
|
|
1682
|
+
|
|
1683
|
+
billing : typing.Optional[OrderBilling]
|
|
1684
|
+
Billing details of an order.
|
|
1685
|
+
|
|
1686
|
+
coupons : typing.Optional[typing.Sequence[str]]
|
|
1687
|
+
Coupons applied to the order. Stored case insensitive.
|
|
1688
|
+
|
|
1689
|
+
identifiers : typing.Optional[OrderIdentifiers]
|
|
1690
|
+
Identifies the contact associated with the order.
|
|
1691
|
+
|
|
1692
|
+
meta_info : typing.Optional[typing.Dict[str, OrderMetaInfoValue]]
|
|
1693
|
+
Meta data of order to store additional detal such as custom message, customer type, source.
|
|
1694
|
+
|
|
1695
|
+
store_id : typing.Optional[str]
|
|
1696
|
+
ID of store where the order is placed
|
|
1697
|
+
|
|
1698
|
+
request_options : typing.Optional[RequestOptions]
|
|
1699
|
+
Request-specific configuration.
|
|
1700
|
+
|
|
1701
|
+
Returns
|
|
1702
|
+
-------
|
|
1703
|
+
None
|
|
1704
|
+
|
|
1705
|
+
Examples
|
|
1706
|
+
--------
|
|
1707
|
+
import asyncio
|
|
1708
|
+
|
|
1709
|
+
from brevo import AsyncBrevo, OrderProductsItem
|
|
1710
|
+
|
|
1711
|
+
client = AsyncBrevo(
|
|
1712
|
+
api_key="YOUR_API_KEY",
|
|
1713
|
+
)
|
|
1714
|
+
|
|
1715
|
+
|
|
1716
|
+
async def main() -> None:
|
|
1717
|
+
await client.ecommerce.create_order(
|
|
1718
|
+
amount=308.42,
|
|
1719
|
+
created_at="2021-07-29T20:59:23.383Z",
|
|
1720
|
+
id="14",
|
|
1721
|
+
products=[
|
|
1722
|
+
OrderProductsItem(
|
|
1723
|
+
price=99.99,
|
|
1724
|
+
product_id="P1",
|
|
1725
|
+
quantity=10.0,
|
|
1726
|
+
)
|
|
1727
|
+
],
|
|
1728
|
+
status="completed",
|
|
1729
|
+
updated_at="2021-07-30T10:59:23.383Z",
|
|
1730
|
+
)
|
|
1731
|
+
|
|
1732
|
+
|
|
1733
|
+
asyncio.run(main())
|
|
1734
|
+
"""
|
|
1735
|
+
_response = await self._raw_client.create_order(
|
|
1736
|
+
amount=amount,
|
|
1737
|
+
created_at=created_at,
|
|
1738
|
+
id=id,
|
|
1739
|
+
products=products,
|
|
1740
|
+
status=status,
|
|
1741
|
+
updated_at=updated_at,
|
|
1742
|
+
billing=billing,
|
|
1743
|
+
coupons=coupons,
|
|
1744
|
+
identifiers=identifiers,
|
|
1745
|
+
meta_info=meta_info,
|
|
1746
|
+
store_id=store_id,
|
|
1747
|
+
request_options=request_options,
|
|
1748
|
+
)
|
|
1749
|
+
return _response.data
|
|
1750
|
+
|
|
1751
|
+
async def create_batch_order(
|
|
1752
|
+
self,
|
|
1753
|
+
*,
|
|
1754
|
+
orders: typing.Sequence[Order],
|
|
1755
|
+
historical: typing.Optional[bool] = OMIT,
|
|
1756
|
+
notify_url: typing.Optional[str] = OMIT,
|
|
1757
|
+
request_options: typing.Optional[RequestOptions] = None,
|
|
1758
|
+
) -> CreateBatchOrderResponse:
|
|
1759
|
+
"""
|
|
1760
|
+
Create multiple orders at one time instead of one order at a time
|
|
1761
|
+
|
|
1762
|
+
Parameters
|
|
1763
|
+
----------
|
|
1764
|
+
orders : typing.Sequence[Order]
|
|
1765
|
+
array of order objects
|
|
1766
|
+
|
|
1767
|
+
historical : typing.Optional[bool]
|
|
1768
|
+
Defines wether you want your orders to be considered as live data or as historical data (import of past data, synchronising data). True: orders will not trigger any automation workflows. False: orders will trigger workflows as usual.
|
|
1769
|
+
|
|
1770
|
+
notify_url : typing.Optional[str]
|
|
1771
|
+
Notify Url provided by client_dev to get the status of batch request
|
|
1772
|
+
|
|
1773
|
+
request_options : typing.Optional[RequestOptions]
|
|
1774
|
+
Request-specific configuration.
|
|
1775
|
+
|
|
1776
|
+
Returns
|
|
1777
|
+
-------
|
|
1778
|
+
CreateBatchOrderResponse
|
|
1779
|
+
batch id created
|
|
1780
|
+
|
|
1781
|
+
Examples
|
|
1782
|
+
--------
|
|
1783
|
+
import asyncio
|
|
1784
|
+
|
|
1785
|
+
from brevo import AsyncBrevo, Order, OrderProductsItem
|
|
1786
|
+
|
|
1787
|
+
client = AsyncBrevo(
|
|
1788
|
+
api_key="YOUR_API_KEY",
|
|
1789
|
+
)
|
|
1790
|
+
|
|
1791
|
+
|
|
1792
|
+
async def main() -> None:
|
|
1793
|
+
await client.ecommerce.create_batch_order(
|
|
1794
|
+
orders=[
|
|
1795
|
+
Order(
|
|
1796
|
+
amount=308.42,
|
|
1797
|
+
created_at="2021-07-29T20:59:23.383Z",
|
|
1798
|
+
id="14",
|
|
1799
|
+
products=[
|
|
1800
|
+
OrderProductsItem(
|
|
1801
|
+
price=99.99,
|
|
1802
|
+
product_id="P1",
|
|
1803
|
+
quantity=10.0,
|
|
1804
|
+
)
|
|
1805
|
+
],
|
|
1806
|
+
status="completed",
|
|
1807
|
+
updated_at="2021-07-30T10:59:23.383Z",
|
|
1808
|
+
)
|
|
1809
|
+
],
|
|
1810
|
+
)
|
|
1811
|
+
|
|
1812
|
+
|
|
1813
|
+
asyncio.run(main())
|
|
1814
|
+
"""
|
|
1815
|
+
_response = await self._raw_client.create_batch_order(
|
|
1816
|
+
orders=orders, historical=historical, notify_url=notify_url, request_options=request_options
|
|
1817
|
+
)
|
|
1818
|
+
return _response.data
|
|
1819
|
+
|
|
1820
|
+
async def get_products(
|
|
1821
|
+
self,
|
|
1822
|
+
*,
|
|
1823
|
+
limit: typing.Optional[int] = None,
|
|
1824
|
+
offset: typing.Optional[int] = None,
|
|
1825
|
+
sort: typing.Optional[GetProductsRequestSort] = None,
|
|
1826
|
+
ids: typing.Optional[typing.Union[str, typing.Sequence[str]]] = None,
|
|
1827
|
+
name: typing.Optional[str] = None,
|
|
1828
|
+
price_lte: typing.Optional[float] = None,
|
|
1829
|
+
price_gte: typing.Optional[float] = None,
|
|
1830
|
+
price_lt: typing.Optional[float] = None,
|
|
1831
|
+
price_gt: typing.Optional[float] = None,
|
|
1832
|
+
price_eq: typing.Optional[float] = None,
|
|
1833
|
+
price_ne: typing.Optional[float] = None,
|
|
1834
|
+
categories: typing.Optional[typing.Union[str, typing.Sequence[str]]] = None,
|
|
1835
|
+
modified_since: typing.Optional[str] = None,
|
|
1836
|
+
created_since: typing.Optional[str] = None,
|
|
1837
|
+
is_deleted: typing.Optional[str] = None,
|
|
1838
|
+
request_options: typing.Optional[RequestOptions] = None,
|
|
1839
|
+
) -> GetProductsResponse:
|
|
1840
|
+
"""
|
|
1841
|
+
Parameters
|
|
1842
|
+
----------
|
|
1843
|
+
limit : typing.Optional[int]
|
|
1844
|
+
Number of documents per page
|
|
1845
|
+
|
|
1846
|
+
offset : typing.Optional[int]
|
|
1847
|
+
Index of the first document in the page
|
|
1848
|
+
|
|
1849
|
+
sort : typing.Optional[GetProductsRequestSort]
|
|
1850
|
+
Sort the results in the ascending/descending order of record creation. Default order is **descending** if `sort` is not passed
|
|
1851
|
+
|
|
1852
|
+
ids : typing.Optional[typing.Union[str, typing.Sequence[str]]]
|
|
1853
|
+
Filter by product ids
|
|
1854
|
+
|
|
1855
|
+
name : typing.Optional[str]
|
|
1856
|
+
Filter by product name, minimum 3 characters should be present for search.
|
|
1857
|
+
|
|
1858
|
+
price_lte : typing.Optional[float]
|
|
1859
|
+
Price filter for products less than and equals to particular amount
|
|
1860
|
+
|
|
1861
|
+
price_gte : typing.Optional[float]
|
|
1862
|
+
Price filter for products greater than and equals to particular amount
|
|
1863
|
+
|
|
1864
|
+
price_lt : typing.Optional[float]
|
|
1865
|
+
Price filter for products less than particular amount
|
|
1866
|
+
|
|
1867
|
+
price_gt : typing.Optional[float]
|
|
1868
|
+
Price filter for products greater than particular amount
|
|
1869
|
+
|
|
1870
|
+
price_eq : typing.Optional[float]
|
|
1871
|
+
Price filter for products equals to particular amount
|
|
1872
|
+
|
|
1873
|
+
price_ne : typing.Optional[float]
|
|
1874
|
+
Price filter for products not equals to particular amount
|
|
1875
|
+
|
|
1876
|
+
categories : typing.Optional[typing.Union[str, typing.Sequence[str]]]
|
|
1877
|
+
Filter by categories ids
|
|
1878
|
+
|
|
1879
|
+
modified_since : typing.Optional[str]
|
|
1880
|
+
Filter (urlencoded) the orders modified after a given UTC date-time (YYYY-MM-DDTHH:mm:ss.SSSZ). **Prefer to pass your timezone in date-time format for accurate result.**
|
|
1881
|
+
|
|
1882
|
+
created_since : typing.Optional[str]
|
|
1883
|
+
Filter (urlencoded) the orders created after a given UTC date-time (YYYY-MM-DDTHH:mm:ss.SSSZ). **Prefer to pass your timezone in date-time format for accurate result.**
|
|
1884
|
+
|
|
1885
|
+
is_deleted : typing.Optional[str]
|
|
1886
|
+
Filter products by their deletion status. If `false` is passed, only products that are not deleted will be returned.
|
|
1887
|
+
|
|
1888
|
+
request_options : typing.Optional[RequestOptions]
|
|
1889
|
+
Request-specific configuration.
|
|
1890
|
+
|
|
1891
|
+
Returns
|
|
1892
|
+
-------
|
|
1893
|
+
GetProductsResponse
|
|
1894
|
+
All products listed
|
|
1895
|
+
|
|
1896
|
+
Examples
|
|
1897
|
+
--------
|
|
1898
|
+
import asyncio
|
|
1899
|
+
|
|
1900
|
+
from brevo import AsyncBrevo
|
|
1901
|
+
|
|
1902
|
+
client = AsyncBrevo(
|
|
1903
|
+
api_key="YOUR_API_KEY",
|
|
1904
|
+
)
|
|
1905
|
+
|
|
1906
|
+
|
|
1907
|
+
async def main() -> None:
|
|
1908
|
+
await client.ecommerce.get_products()
|
|
1909
|
+
|
|
1910
|
+
|
|
1911
|
+
asyncio.run(main())
|
|
1912
|
+
"""
|
|
1913
|
+
_response = await self._raw_client.get_products(
|
|
1914
|
+
limit=limit,
|
|
1915
|
+
offset=offset,
|
|
1916
|
+
sort=sort,
|
|
1917
|
+
ids=ids,
|
|
1918
|
+
name=name,
|
|
1919
|
+
price_lte=price_lte,
|
|
1920
|
+
price_gte=price_gte,
|
|
1921
|
+
price_lt=price_lt,
|
|
1922
|
+
price_gt=price_gt,
|
|
1923
|
+
price_eq=price_eq,
|
|
1924
|
+
price_ne=price_ne,
|
|
1925
|
+
categories=categories,
|
|
1926
|
+
modified_since=modified_since,
|
|
1927
|
+
created_since=created_since,
|
|
1928
|
+
is_deleted=is_deleted,
|
|
1929
|
+
request_options=request_options,
|
|
1930
|
+
)
|
|
1931
|
+
return _response.data
|
|
1932
|
+
|
|
1933
|
+
async def create_update_product(
|
|
1934
|
+
self,
|
|
1935
|
+
*,
|
|
1936
|
+
id: str,
|
|
1937
|
+
name: str,
|
|
1938
|
+
categories: typing.Optional[typing.Sequence[str]] = OMIT,
|
|
1939
|
+
deleted_at: typing.Optional[str] = OMIT,
|
|
1940
|
+
image_url: typing.Optional[str] = OMIT,
|
|
1941
|
+
is_deleted: typing.Optional[bool] = OMIT,
|
|
1942
|
+
meta_info: typing.Optional[typing.Dict[str, CreateUpdateProductRequestMetaInfoValue]] = OMIT,
|
|
1943
|
+
parent_id: typing.Optional[str] = OMIT,
|
|
1944
|
+
price: typing.Optional[float] = OMIT,
|
|
1945
|
+
sku: typing.Optional[str] = OMIT,
|
|
1946
|
+
stock: typing.Optional[float] = OMIT,
|
|
1947
|
+
update_enabled: typing.Optional[bool] = OMIT,
|
|
1948
|
+
url: typing.Optional[str] = OMIT,
|
|
1949
|
+
request_options: typing.Optional[RequestOptions] = None,
|
|
1950
|
+
) -> CreateUpdateProductResponse:
|
|
1951
|
+
"""
|
|
1952
|
+
Parameters
|
|
1953
|
+
----------
|
|
1954
|
+
id : str
|
|
1955
|
+
Product ID for which you requested the details
|
|
1956
|
+
|
|
1957
|
+
name : str
|
|
1958
|
+
Mandatory in case of creation**. Name of the product for which you requested the details
|
|
1959
|
+
|
|
1960
|
+
categories : typing.Optional[typing.Sequence[str]]
|
|
1961
|
+
Category ID-s of the product
|
|
1962
|
+
|
|
1963
|
+
deleted_at : typing.Optional[str]
|
|
1964
|
+
UTC date-time (YYYY-MM-DDTHH:mm:ss.SSSZ) of the product deleted from the shop's database
|
|
1965
|
+
|
|
1966
|
+
image_url : typing.Optional[str]
|
|
1967
|
+
Absolute URL to the cover image of the product
|
|
1968
|
+
|
|
1969
|
+
is_deleted : typing.Optional[bool]
|
|
1970
|
+
product deleted from the shop's database
|
|
1971
|
+
|
|
1972
|
+
meta_info : typing.Optional[typing.Dict[str, CreateUpdateProductRequestMetaInfoValue]]
|
|
1973
|
+
Meta data of product such as description, vendor, producer, stock level. The size of cumulative metaInfo shall not exceed **1000 KB**. Maximum length of metaInfo object can be 20.
|
|
1974
|
+
|
|
1975
|
+
parent_id : typing.Optional[str]
|
|
1976
|
+
Parent product id of the product
|
|
1977
|
+
|
|
1978
|
+
price : typing.Optional[float]
|
|
1979
|
+
Price of the product
|
|
1980
|
+
|
|
1981
|
+
sku : typing.Optional[str]
|
|
1982
|
+
Product identifier from the shop
|
|
1983
|
+
|
|
1984
|
+
stock : typing.Optional[float]
|
|
1985
|
+
Current stock value of the product from the shop's database
|
|
1986
|
+
|
|
1987
|
+
update_enabled : typing.Optional[bool]
|
|
1988
|
+
Facilitate to update the existing category in the same request (updateEnabled = true)
|
|
1989
|
+
|
|
1990
|
+
url : typing.Optional[str]
|
|
1991
|
+
URL to the product
|
|
1992
|
+
|
|
1993
|
+
request_options : typing.Optional[RequestOptions]
|
|
1994
|
+
Request-specific configuration.
|
|
1995
|
+
|
|
1996
|
+
Returns
|
|
1997
|
+
-------
|
|
1998
|
+
CreateUpdateProductResponse
|
|
1999
|
+
Product created
|
|
2000
|
+
|
|
2001
|
+
Examples
|
|
2002
|
+
--------
|
|
2003
|
+
import asyncio
|
|
2004
|
+
|
|
2005
|
+
from brevo import AsyncBrevo
|
|
2006
|
+
|
|
2007
|
+
client = AsyncBrevo(
|
|
2008
|
+
api_key="YOUR_API_KEY",
|
|
2009
|
+
)
|
|
2010
|
+
|
|
2011
|
+
|
|
2012
|
+
async def main() -> None:
|
|
2013
|
+
await client.ecommerce.create_update_product(
|
|
2014
|
+
id="P11",
|
|
2015
|
+
name="Iphone 11",
|
|
2016
|
+
)
|
|
2017
|
+
|
|
2018
|
+
|
|
2019
|
+
asyncio.run(main())
|
|
2020
|
+
"""
|
|
2021
|
+
_response = await self._raw_client.create_update_product(
|
|
2022
|
+
id=id,
|
|
2023
|
+
name=name,
|
|
2024
|
+
categories=categories,
|
|
2025
|
+
deleted_at=deleted_at,
|
|
2026
|
+
image_url=image_url,
|
|
2027
|
+
is_deleted=is_deleted,
|
|
2028
|
+
meta_info=meta_info,
|
|
2029
|
+
parent_id=parent_id,
|
|
2030
|
+
price=price,
|
|
2031
|
+
sku=sku,
|
|
2032
|
+
stock=stock,
|
|
2033
|
+
update_enabled=update_enabled,
|
|
2034
|
+
url=url,
|
|
2035
|
+
request_options=request_options,
|
|
2036
|
+
)
|
|
2037
|
+
return _response.data
|
|
2038
|
+
|
|
2039
|
+
async def create_update_batch_products(
|
|
2040
|
+
self,
|
|
2041
|
+
*,
|
|
2042
|
+
products: typing.Sequence[CreateUpdateBatchProductsRequestProductsItem],
|
|
2043
|
+
update_enabled: typing.Optional[bool] = OMIT,
|
|
2044
|
+
request_options: typing.Optional[RequestOptions] = None,
|
|
2045
|
+
) -> CreateUpdateBatchProductsResponse:
|
|
2046
|
+
"""
|
|
2047
|
+
Parameters
|
|
2048
|
+
----------
|
|
2049
|
+
products : typing.Sequence[CreateUpdateBatchProductsRequestProductsItem]
|
|
2050
|
+
array of products objects
|
|
2051
|
+
|
|
2052
|
+
update_enabled : typing.Optional[bool]
|
|
2053
|
+
Facilitate to update the existing categories in the same request (updateEnabled = true)
|
|
2054
|
+
|
|
2055
|
+
request_options : typing.Optional[RequestOptions]
|
|
2056
|
+
Request-specific configuration.
|
|
2057
|
+
|
|
2058
|
+
Returns
|
|
2059
|
+
-------
|
|
2060
|
+
CreateUpdateBatchProductsResponse
|
|
2061
|
+
Products created and updated
|
|
2062
|
+
|
|
2063
|
+
Examples
|
|
2064
|
+
--------
|
|
2065
|
+
import asyncio
|
|
2066
|
+
|
|
2067
|
+
from brevo import AsyncBrevo
|
|
2068
|
+
from brevo.ecommerce import CreateUpdateBatchProductsRequestProductsItem
|
|
2069
|
+
|
|
2070
|
+
client = AsyncBrevo(
|
|
2071
|
+
api_key="YOUR_API_KEY",
|
|
2072
|
+
)
|
|
2073
|
+
|
|
2074
|
+
|
|
2075
|
+
async def main() -> None:
|
|
2076
|
+
await client.ecommerce.create_update_batch_products(
|
|
2077
|
+
products=[
|
|
2078
|
+
CreateUpdateBatchProductsRequestProductsItem(
|
|
2079
|
+
id="P11",
|
|
2080
|
+
name="Iphone 11",
|
|
2081
|
+
)
|
|
2082
|
+
],
|
|
2083
|
+
)
|
|
2084
|
+
|
|
2085
|
+
|
|
2086
|
+
asyncio.run(main())
|
|
2087
|
+
"""
|
|
2088
|
+
_response = await self._raw_client.create_update_batch_products(
|
|
2089
|
+
products=products, update_enabled=update_enabled, request_options=request_options
|
|
2090
|
+
)
|
|
2091
|
+
return _response.data
|
|
2092
|
+
|
|
2093
|
+
async def get_product_info(
|
|
2094
|
+
self, id: str, *, request_options: typing.Optional[RequestOptions] = None
|
|
2095
|
+
) -> GetProductDetails:
|
|
2096
|
+
"""
|
|
2097
|
+
Parameters
|
|
2098
|
+
----------
|
|
2099
|
+
id : str
|
|
2100
|
+
Product ID
|
|
2101
|
+
|
|
2102
|
+
request_options : typing.Optional[RequestOptions]
|
|
2103
|
+
Request-specific configuration.
|
|
2104
|
+
|
|
2105
|
+
Returns
|
|
2106
|
+
-------
|
|
2107
|
+
GetProductDetails
|
|
2108
|
+
Product informations
|
|
2109
|
+
|
|
2110
|
+
Examples
|
|
2111
|
+
--------
|
|
2112
|
+
import asyncio
|
|
2113
|
+
|
|
2114
|
+
from brevo import AsyncBrevo
|
|
2115
|
+
|
|
2116
|
+
client = AsyncBrevo(
|
|
2117
|
+
api_key="YOUR_API_KEY",
|
|
2118
|
+
)
|
|
2119
|
+
|
|
2120
|
+
|
|
2121
|
+
async def main() -> None:
|
|
2122
|
+
await client.ecommerce.get_product_info(
|
|
2123
|
+
id="id",
|
|
2124
|
+
)
|
|
2125
|
+
|
|
2126
|
+
|
|
2127
|
+
asyncio.run(main())
|
|
2128
|
+
"""
|
|
2129
|
+
_response = await self._raw_client.get_product_info(id, request_options=request_options)
|
|
2130
|
+
return _response.data
|
|
2131
|
+
|
|
2132
|
+
async def create_product_alert(
|
|
2133
|
+
self,
|
|
2134
|
+
id: str,
|
|
2135
|
+
*,
|
|
2136
|
+
contact_identifiers: typing.Optional[CreateProductAlertRequestContactIdentifiers] = OMIT,
|
|
2137
|
+
request_options: typing.Optional[RequestOptions] = None,
|
|
2138
|
+
) -> None:
|
|
2139
|
+
"""
|
|
2140
|
+
Parameters
|
|
2141
|
+
----------
|
|
2142
|
+
id : str
|
|
2143
|
+
Product ID
|
|
2144
|
+
|
|
2145
|
+
contact_identifiers : typing.Optional[CreateProductAlertRequestContactIdentifiers]
|
|
2146
|
+
|
|
2147
|
+
request_options : typing.Optional[RequestOptions]
|
|
2148
|
+
Request-specific configuration.
|
|
2149
|
+
|
|
2150
|
+
Returns
|
|
2151
|
+
-------
|
|
2152
|
+
None
|
|
2153
|
+
|
|
2154
|
+
Examples
|
|
2155
|
+
--------
|
|
2156
|
+
import asyncio
|
|
2157
|
+
|
|
2158
|
+
from brevo import AsyncBrevo
|
|
2159
|
+
|
|
2160
|
+
client = AsyncBrevo(
|
|
2161
|
+
api_key="YOUR_API_KEY",
|
|
2162
|
+
)
|
|
2163
|
+
|
|
2164
|
+
|
|
2165
|
+
async def main() -> None:
|
|
2166
|
+
await client.ecommerce.create_product_alert(
|
|
2167
|
+
id="id",
|
|
2168
|
+
)
|
|
2169
|
+
|
|
2170
|
+
|
|
2171
|
+
asyncio.run(main())
|
|
2172
|
+
"""
|
|
2173
|
+
_response = await self._raw_client.create_product_alert(
|
|
2174
|
+
id, contact_identifiers=contact_identifiers, request_options=request_options
|
|
2175
|
+
)
|
|
2176
|
+
return _response.data
|