hostinger-api-sdk 1.30.8 → 1.32.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (39) hide show
  1. package/README.md +2 -2
  2. package/api.ts +2234 -982
  3. package/base.ts +1 -1
  4. package/common.ts +1 -1
  5. package/configuration.ts +2 -2
  6. package/dist/api.d.ts +977 -49
  7. package/dist/api.js +683 -9
  8. package/dist/base.d.ts +1 -1
  9. package/dist/base.js +1 -1
  10. package/dist/common.d.ts +1 -1
  11. package/dist/common.js +1 -1
  12. package/dist/configuration.d.ts +1 -1
  13. package/dist/configuration.js +2 -2
  14. package/dist/esm/api.d.ts +977 -49
  15. package/dist/esm/api.js +667 -1
  16. package/dist/esm/base.d.ts +1 -1
  17. package/dist/esm/base.js +1 -1
  18. package/dist/esm/common.d.ts +1 -1
  19. package/dist/esm/common.js +1 -1
  20. package/dist/esm/configuration.d.ts +1 -1
  21. package/dist/esm/configuration.js +2 -2
  22. package/dist/esm/index.d.ts +1 -1
  23. package/dist/esm/index.js +1 -1
  24. package/dist/index.d.ts +1 -1
  25. package/dist/index.js +1 -1
  26. package/docs/ReachAutomationsApi.md +187 -0
  27. package/docs/ReachCampaignsApi.md +190 -0
  28. package/docs/ReachListAutomationsV1200Response.md +22 -0
  29. package/docs/ReachListCampaignsV1200Response.md +22 -0
  30. package/docs/ReachV1AutomationsAutomationEventsResource.md +27 -0
  31. package/docs/ReachV1AutomationsAutomationResource.md +34 -0
  32. package/docs/ReachV1AutomationsStepsAutomationStepResource.md +30 -0
  33. package/docs/ReachV1CampaignsCampaignDeliveryResource.md +25 -0
  34. package/docs/ReachV1CampaignsCampaignDetailsResource.md +52 -0
  35. package/docs/ReachV1CampaignsCampaignResource.md +44 -0
  36. package/docs/ReachV1CampaignsCampaignStatisticsResource.md +49 -0
  37. package/docs/ReachV1CampaignsCampaignSummaryStatisticsResource.md +27 -0
  38. package/index.ts +1 -1
  39. package/package.json +1 -1
package/api.ts CHANGED
@@ -3,7 +3,7 @@
3
3
  /**
4
4
  * Hostinger API
5
5
  *
6
- * API Version: 1.32.6
6
+ * API Version: 1.34.0
7
7
  *
8
8
  * NOTE: This file is auto-generated, DO NOT EDIT THIS FILE MANUALLY!
9
9
  * If you want to contribute or request a new feature, please create an issue or pull request on https://github.com/hostinger/api
@@ -7771,6 +7771,44 @@ export interface MailV1WebhooksWebhookTestResultResource {
7771
7771
  */
7772
7772
  'error': string | null;
7773
7773
  }
7774
+ /**
7775
+ *
7776
+ * @export
7777
+ * @interface ReachListAutomationsV1200Response
7778
+ */
7779
+ export interface ReachListAutomationsV1200Response {
7780
+ /**
7781
+ * Array of [`Reach.V1.Automations.AutomationResource`](#model/reachv1automationsautomationresource)
7782
+ * @type {Array<ReachV1AutomationsAutomationResource>}
7783
+ * @memberof ReachListAutomationsV1200Response
7784
+ */
7785
+ 'data': Array<ReachV1AutomationsAutomationResource>;
7786
+ /**
7787
+ *
7788
+ * @type {CommonSchemaPaginationMetaSchema}
7789
+ * @memberof ReachListAutomationsV1200Response
7790
+ */
7791
+ 'meta': CommonSchemaPaginationMetaSchema;
7792
+ }
7793
+ /**
7794
+ *
7795
+ * @export
7796
+ * @interface ReachListCampaignsV1200Response
7797
+ */
7798
+ export interface ReachListCampaignsV1200Response {
7799
+ /**
7800
+ * Array of [`Reach.V1.Campaigns.CampaignResource`](#model/reachv1campaignscampaignresource)
7801
+ * @type {Array<ReachV1CampaignsCampaignResource>}
7802
+ * @memberof ReachListCampaignsV1200Response
7803
+ */
7804
+ 'data': Array<ReachV1CampaignsCampaignResource>;
7805
+ /**
7806
+ *
7807
+ * @type {CommonSchemaPaginationMetaSchema}
7808
+ * @memberof ReachListCampaignsV1200Response
7809
+ */
7810
+ 'meta': CommonSchemaPaginationMetaSchema;
7811
+ }
7774
7812
  /**
7775
7813
  *
7776
7814
  * @export
@@ -7848,558 +7886,721 @@ export interface ReachListProfileSegmentsV1200Response {
7848
7886
  'meta': CommonSchemaPaginationMetaSchema;
7849
7887
  }
7850
7888
  /**
7851
- * Create many contacts in one call
7889
+ * Counts of contacts moving through the automation. These are not email engagement metrics. Automations expose no sent, open or click counters - use the campaign statistics endpoint for those.
7852
7890
  * @export
7853
- * @interface ReachV1ContactsBulkStoreRequest
7891
+ * @interface ReachV1AutomationsAutomationEventsResource
7854
7892
  */
7855
- export interface ReachV1ContactsBulkStoreRequest {
7893
+ export interface ReachV1AutomationsAutomationEventsResource {
7856
7894
  /**
7857
- *
7858
- * @type {Array<ReachV1ContactsBulkStoreRequestContactsInner>}
7859
- * @memberof ReachV1ContactsBulkStoreRequest
7895
+ * Contacts that ever entered the automation, including those that already left it.
7896
+ * @type {number}
7897
+ * @memberof ReachV1AutomationsAutomationEventsResource
7860
7898
  */
7861
- 'contacts': Array<ReachV1ContactsBulkStoreRequestContactsInner>;
7899
+ 'started': number;
7862
7900
  /**
7863
- * Existing tags to attach to every created contact
7864
- * @type {Array<string>}
7865
- * @memberof ReachV1ContactsBulkStoreRequest
7901
+ * Contacts currently moving through the automation, including those waiting on a delay step.
7902
+ * @type {number}
7903
+ * @memberof ReachV1AutomationsAutomationEventsResource
7866
7904
  */
7867
- 'tag_uuids': Array<string>;
7905
+ 'in_progress': number;
7868
7906
  /**
7869
- * Note applied to every created contact
7870
- * @type {string}
7871
- * @memberof ReachV1ContactsBulkStoreRequest
7907
+ * Contacts that reached the end of the workflow.
7908
+ * @type {number}
7909
+ * @memberof ReachV1AutomationsAutomationEventsResource
7872
7910
  */
7873
- 'note': string | null;
7911
+ 'completed': number;
7912
+ /**
7913
+ * Contacts whose journey through the automation errored and stopped.
7914
+ * @type {number}
7915
+ * @memberof ReachV1AutomationsAutomationEventsResource
7916
+ */
7917
+ 'failed': number;
7874
7918
  }
7875
7919
  /**
7876
7920
  *
7877
7921
  * @export
7878
- * @interface ReachV1ContactsBulkStoreRequestContactsInner
7922
+ * @interface ReachV1AutomationsAutomationResource
7879
7923
  */
7880
- export interface ReachV1ContactsBulkStoreRequestContactsInner {
7924
+ export interface ReachV1AutomationsAutomationResource {
7881
7925
  /**
7882
7926
  *
7883
7927
  * @type {string}
7884
- * @memberof ReachV1ContactsBulkStoreRequestContactsInner
7928
+ * @memberof ReachV1AutomationsAutomationResource
7885
7929
  */
7886
- 'email': string;
7930
+ 'uuid': string;
7887
7931
  /**
7888
7932
  *
7889
7933
  * @type {string}
7890
- * @memberof ReachV1ContactsBulkStoreRequestContactsInner
7934
+ * @memberof ReachV1AutomationsAutomationResource
7891
7935
  */
7892
- 'name': string | null;
7936
+ 'name': string;
7937
+ /**
7938
+ * There is no `completed` status. Use `events.completed` to see how many contacts finished.
7939
+ * @type {string}
7940
+ * @memberof ReachV1AutomationsAutomationResource
7941
+ */
7942
+ 'status': ReachV1AutomationsAutomationResourceStatusEnum;
7943
+ /**
7944
+ * What kind of workflow this is. `custom` automations are the ones built from scratch.
7945
+ * @type {string}
7946
+ * @memberof ReachV1AutomationsAutomationResource
7947
+ */
7948
+ 'type': ReachV1AutomationsAutomationResourceTypeEnum;
7949
+ /**
7950
+ * Trigger configuration of the automation. The shape depends on the type.
7951
+ * @type {object}
7952
+ * @memberof ReachV1AutomationsAutomationResource
7953
+ */
7954
+ 'config': object | null;
7955
+ /**
7956
+ *
7957
+ * @type {ReachV1AutomationsAutomationEventsResource}
7958
+ * @memberof ReachV1AutomationsAutomationResource
7959
+ */
7960
+ 'events': ReachV1AutomationsAutomationEventsResource;
7893
7961
  /**
7894
7962
  *
7895
7963
  * @type {string}
7896
- * @memberof ReachV1ContactsBulkStoreRequestContactsInner
7964
+ * @memberof ReachV1AutomationsAutomationResource
7897
7965
  */
7898
- 'surname': string | null;
7966
+ 'created_at': string | null;
7899
7967
  /**
7900
- * Phone number in E.164 format (leading \"+\" then 7-15 digits)
7968
+ *
7901
7969
  * @type {string}
7902
- * @memberof ReachV1ContactsBulkStoreRequestContactsInner
7970
+ * @memberof ReachV1AutomationsAutomationResource
7903
7971
  */
7904
- 'phone': string | null;
7972
+ 'updated_at': string | null;
7905
7973
  }
7974
+
7975
+ export const ReachV1AutomationsAutomationResourceStatusEnum = {
7976
+ Active: 'active',
7977
+ Paused: 'paused',
7978
+ Draft: 'draft'
7979
+ } as const;
7980
+
7981
+ export type ReachV1AutomationsAutomationResourceStatusEnum = typeof ReachV1AutomationsAutomationResourceStatusEnum[keyof typeof ReachV1AutomationsAutomationResourceStatusEnum];
7982
+ export const ReachV1AutomationsAutomationResourceTypeEnum = {
7983
+ Welcome: 'welcome',
7984
+ WelcomeSeries: 'welcome_series',
7985
+ PromotionalSeries: 'promotional_series',
7986
+ TrustBuildingSeries: 'trust_building_series',
7987
+ EcommerceAbandonedCart: 'ecommerce_abandoned_cart',
7988
+ EcommerceRecommendAfterPurchase: 'ecommerce_recommend_after_purchase',
7989
+ EcommercePostPurchase: 'ecommerce_post_purchase',
7990
+ EcommerceDiscountAfterPurchase: 'ecommerce_discount_after_purchase',
7991
+ ReEngagementNonOpeners: 're_engagement_non_openers',
7992
+ ReEngagementNonClickers: 're_engagement_non_clickers',
7993
+ FormSubmitted: 'form_submitted',
7994
+ Custom: 'custom'
7995
+ } as const;
7996
+
7997
+ export type ReachV1AutomationsAutomationResourceTypeEnum = typeof ReachV1AutomationsAutomationResourceTypeEnum[keyof typeof ReachV1AutomationsAutomationResourceTypeEnum];
7998
+
7906
7999
  /**
7907
8000
  *
7908
8001
  * @export
7909
- * @interface ReachV1ContactsContactDetailsResource
8002
+ * @interface ReachV1AutomationsStepsAutomationStepResource
7910
8003
  */
7911
- export interface ReachV1ContactsContactDetailsResource {
8004
+ export interface ReachV1AutomationsStepsAutomationStepResource {
7912
8005
  /**
7913
8006
  *
7914
8007
  * @type {string}
7915
- * @memberof ReachV1ContactsContactDetailsResource
8008
+ * @memberof ReachV1AutomationsStepsAutomationStepResource
7916
8009
  */
7917
8010
  'uuid': string;
7918
8011
  /**
7919
- *
8012
+ * The step this one branches from. Null for the entry point of the workflow.
7920
8013
  * @type {string}
7921
- * @memberof ReachV1ContactsContactDetailsResource
8014
+ * @memberof ReachV1AutomationsStepsAutomationStepResource
7922
8015
  */
7923
- 'email': string;
8016
+ 'parent_uuid': string | null;
7924
8017
  /**
7925
- *
7926
- * @type {string}
7927
- * @memberof ReachV1ContactsContactDetailsResource
8018
+ * Position of this step among the steps sharing its parent.
8019
+ * @type {number}
8020
+ * @memberof ReachV1AutomationsStepsAutomationStepResource
7928
8021
  */
7929
- 'name': string | null;
8022
+ 'step_order': number;
7930
8023
  /**
7931
- *
8024
+ * Role of the step in the workflow. A `conditional` step branches into several children.
7932
8025
  * @type {string}
7933
- * @memberof ReachV1ContactsContactDetailsResource
8026
+ * @memberof ReachV1AutomationsStepsAutomationStepResource
7934
8027
  */
7935
- 'surname': string | null;
8028
+ 'type': ReachV1AutomationsStepsAutomationStepResourceTypeEnum;
7936
8029
  /**
7937
- *
8030
+ * The concrete trigger, action, decision or delay this step performs.
7938
8031
  * @type {string}
7939
- * @memberof ReachV1ContactsContactDetailsResource
8032
+ * @memberof ReachV1AutomationsStepsAutomationStepResource
7940
8033
  */
7941
- 'phone': string | null;
8034
+ 'value': ReachV1AutomationsStepsAutomationStepResourceValueEnum;
7942
8035
  /**
7943
- *
7944
- * @type {string}
7945
- * @memberof ReachV1ContactsContactDetailsResource
8036
+ * Step configuration. The shape depends on the value, and is empty for steps that take none.
8037
+ * @type {object}
8038
+ * @memberof ReachV1AutomationsStepsAutomationStepResource
7946
8039
  */
7947
- 'subscription_status': ReachV1ContactsContactDetailsResourceSubscriptionStatusEnum;
8040
+ 'config': object | null;
8041
+ }
8042
+
8043
+ export const ReachV1AutomationsStepsAutomationStepResourceTypeEnum = {
8044
+ Trigger: 'trigger',
8045
+ Action: 'action',
8046
+ Conditional: 'conditional'
8047
+ } as const;
8048
+
8049
+ export type ReachV1AutomationsStepsAutomationStepResourceTypeEnum = typeof ReachV1AutomationsStepsAutomationStepResourceTypeEnum[keyof typeof ReachV1AutomationsStepsAutomationStepResourceTypeEnum];
8050
+ export const ReachV1AutomationsStepsAutomationStepResourceValueEnum = {
8051
+ NewContact: 'new_contact',
8052
+ NewSegmentContact: 'new_segment_contact',
8053
+ FormSubmitted: 'form_submitted',
8054
+ Webhook: 'webhook',
8055
+ SendWelcomeEmail: 'send_welcome_email',
8056
+ SendEmail: 'send_email',
8057
+ SendCampaign: 'send_campaign',
8058
+ Decision: 'decision',
8059
+ Delay: 'delay'
8060
+ } as const;
8061
+
8062
+ export type ReachV1AutomationsStepsAutomationStepResourceValueEnum = typeof ReachV1AutomationsStepsAutomationStepResourceValueEnum[keyof typeof ReachV1AutomationsStepsAutomationStepResourceValueEnum];
8063
+
8064
+ /**
8065
+ * Delivery progress. While the campaign is `sending`, `total_sent` climbs towards the estimate.
8066
+ * @export
8067
+ * @interface ReachV1CampaignsCampaignDeliveryResource
8068
+ */
8069
+ export interface ReachV1CampaignsCampaignDeliveryResource {
7948
8070
  /**
7949
- *
7950
- * @type {string}
7951
- * @memberof ReachV1ContactsContactDetailsResource
8071
+ * Emails sent so far.
8072
+ * @type {number}
8073
+ * @memberof ReachV1CampaignsCampaignDeliveryResource
7952
8074
  */
7953
- 'subscribed_at': string | null;
8075
+ 'total_sent': number;
7954
8076
  /**
7955
- *
7956
- * @type {string}
7957
- * @memberof ReachV1ContactsContactDetailsResource
8077
+ * Recipients this campaign was estimated to reach when sending started. Null for campaigns that have not started sending.
8078
+ * @type {number}
8079
+ * @memberof ReachV1CampaignsCampaignDeliveryResource
7958
8080
  */
7959
- 'unsubscribed_at': string | null;
8081
+ 'estimated_total_recipients': number | null;
8082
+ /**
8083
+ * Contacts currently targeted by this campaign.
8084
+ * @type {number}
8085
+ * @memberof ReachV1CampaignsCampaignDeliveryResource
8086
+ */
8087
+ 'subscribers_count': number;
8088
+ }
8089
+ /**
8090
+ *
8091
+ * @export
8092
+ * @interface ReachV1CampaignsCampaignDetailsResource
8093
+ */
8094
+ export interface ReachV1CampaignsCampaignDetailsResource {
7960
8095
  /**
7961
8096
  *
7962
8097
  * @type {string}
7963
- * @memberof ReachV1ContactsContactDetailsResource
8098
+ * @memberof ReachV1CampaignsCampaignDetailsResource
7964
8099
  */
7965
- 'created_at': string | null;
8100
+ 'uuid': string;
7966
8101
  /**
7967
8102
  *
7968
8103
  * @type {string}
7969
- * @memberof ReachV1ContactsContactDetailsResource
8104
+ * @memberof ReachV1CampaignsCampaignDetailsResource
7970
8105
  */
7971
- 'domain': string | null;
8106
+ 'title': string;
7972
8107
  /**
7973
8108
  *
7974
8109
  * @type {string}
7975
- * @memberof ReachV1ContactsContactDetailsResource
8110
+ * @memberof ReachV1CampaignsCampaignDetailsResource
7976
8111
  */
7977
- 'source': ReachV1ContactsContactDetailsResourceSourceEnum | null;
8112
+ 'subject': string;
7978
8113
  /**
7979
8114
  *
7980
8115
  * @type {string}
7981
- * @memberof ReachV1ContactsContactDetailsResource
8116
+ * @memberof ReachV1CampaignsCampaignDetailsResource
7982
8117
  */
7983
- 'note': string | null;
8118
+ 'sender_name': string;
7984
8119
  /**
7985
8120
  *
7986
- * @type {Array<ReachV1ContactsTagsTagResource>}
7987
- * @memberof ReachV1ContactsContactDetailsResource
8121
+ * @type {string}
8122
+ * @memberof ReachV1CampaignsCampaignDetailsResource
7988
8123
  */
7989
- 'tags': Array<ReachV1ContactsTagsTagResource>;
8124
+ 'sender_email': string;
7990
8125
  /**
7991
- * Custom field values held by this contact
7992
- * @type {Array<ReachV1ContactsFieldsContactFieldValueResource>}
7993
- * @memberof ReachV1ContactsContactDetailsResource
8126
+ * The email template this campaign uses. The template title is not exposed.
8127
+ * @type {string}
8128
+ * @memberof ReachV1CampaignsCampaignDetailsResource
7994
8129
  */
7995
- 'fields': Array<ReachV1ContactsFieldsContactFieldValueResource>;
7996
- }
7997
-
7998
- export const ReachV1ContactsContactDetailsResourceSubscriptionStatusEnum = {
7999
- Subscribed: 'subscribed',
8000
- Unsubscribed: 'unsubscribed',
8001
- Confirmed: 'confirmed',
8002
- Pending: 'pending'
8003
- } as const;
8004
-
8005
- export type ReachV1ContactsContactDetailsResourceSubscriptionStatusEnum = typeof ReachV1ContactsContactDetailsResourceSubscriptionStatusEnum[keyof typeof ReachV1ContactsContactDetailsResourceSubscriptionStatusEnum];
8006
- export const ReachV1ContactsContactDetailsResourceSourceEnum = {
8007
- Sync: 'sync',
8008
- Import: 'import',
8009
- Manual: 'manual',
8010
- Api: 'api',
8011
- Form: 'form',
8012
- Checkout: 'checkout',
8013
- Horizons: 'horizons'
8014
- } as const;
8015
-
8016
- export type ReachV1ContactsContactDetailsResourceSourceEnum = typeof ReachV1ContactsContactDetailsResourceSourceEnum[keyof typeof ReachV1ContactsContactDetailsResourceSourceEnum];
8017
-
8018
- /**
8019
- *
8020
- * @export
8021
- * @interface ReachV1ContactsContactResource
8022
- */
8023
- export interface ReachV1ContactsContactResource {
8130
+ 'template_uuid': string | null;
8024
8131
  /**
8025
- *
8132
+ * A fully sent campaign is `publish`. There is no `sent`, `paused` or `archived` status.
8026
8133
  * @type {string}
8027
- * @memberof ReachV1ContactsContactResource
8134
+ * @memberof ReachV1CampaignsCampaignDetailsResource
8028
8135
  */
8029
- 'uuid': string;
8136
+ 'status': ReachV1CampaignsCampaignDetailsResourceStatusEnum;
8030
8137
  /**
8031
8138
  *
8032
8139
  * @type {string}
8033
- * @memberof ReachV1ContactsContactResource
8140
+ * @memberof ReachV1CampaignsCampaignDetailsResource
8034
8141
  */
8035
- 'name': string | null;
8142
+ 'type': ReachV1CampaignsCampaignDetailsResourceTypeEnum;
8036
8143
  /**
8037
- *
8144
+ * Set only while the status is `failed`.
8038
8145
  * @type {string}
8039
- * @memberof ReachV1ContactsContactResource
8146
+ * @memberof ReachV1CampaignsCampaignDetailsResource
8040
8147
  */
8041
- 'surname': string | null;
8148
+ 'failure_reason': string | null;
8149
+ /**
8150
+ * Whether delivery time is picked per contact rather than sent to everyone at once.
8151
+ * @type {boolean}
8152
+ * @memberof ReachV1CampaignsCampaignDetailsResource
8153
+ */
8154
+ 'is_smart_send': boolean;
8155
+ /**
8156
+ * Whether the campaign targets every contact instead of the listed segments.
8157
+ * @type {boolean}
8158
+ * @memberof ReachV1CampaignsCampaignDetailsResource
8159
+ */
8160
+ 'is_all_contacts': boolean;
8042
8161
  /**
8043
8162
  *
8044
- * @type {string}
8045
- * @memberof ReachV1ContactsContactResource
8163
+ * @type {ReachV1CampaignsCampaignDeliveryResource}
8164
+ * @memberof ReachV1CampaignsCampaignDetailsResource
8046
8165
  */
8047
- 'email': string;
8166
+ 'delivery': ReachV1CampaignsCampaignDeliveryResource;
8167
+ /**
8168
+ * Segments this campaign targets. Empty when it targets all contacts.
8169
+ * @type {Array<string>}
8170
+ * @memberof ReachV1CampaignsCampaignDetailsResource
8171
+ */
8172
+ 'segment_uuids': Array<string>;
8048
8173
  /**
8049
8174
  *
8050
8175
  * @type {string}
8051
- * @memberof ReachV1ContactsContactResource
8176
+ * @memberof ReachV1CampaignsCampaignDetailsResource
8052
8177
  */
8053
- 'subscription_status': ReachV1ContactsContactResourceSubscriptionStatusEnum;
8178
+ 'created_at': string;
8054
8179
  /**
8055
8180
  *
8056
8181
  * @type {string}
8057
- * @memberof ReachV1ContactsContactResource
8182
+ * @memberof ReachV1CampaignsCampaignDetailsResource
8058
8183
  */
8059
- 'subscribed_at': string;
8184
+ 'updated_at': string | null;
8060
8185
  /**
8061
8186
  *
8062
8187
  * @type {string}
8063
- * @memberof ReachV1ContactsContactResource
8188
+ * @memberof ReachV1CampaignsCampaignDetailsResource
8064
8189
  */
8065
- 'source': ReachV1ContactsContactResourceSourceEnum | null;
8190
+ 'sent_at': string | null;
8066
8191
  /**
8067
8192
  *
8068
8193
  * @type {string}
8069
- * @memberof ReachV1ContactsContactResource
8194
+ * @memberof ReachV1CampaignsCampaignDetailsResource
8070
8195
  */
8071
- 'note': string | null;
8196
+ 'scheduled_at': string | null;
8072
8197
  }
8073
8198
 
8074
- export const ReachV1ContactsContactResourceSubscriptionStatusEnum = {
8075
- Subscribed: 'subscribed',
8076
- Unsubscribed: 'unsubscribed',
8077
- Confirmed: 'confirmed',
8078
- Pending: 'pending'
8199
+ export const ReachV1CampaignsCampaignDetailsResourceStatusEnum = {
8200
+ Draft: 'draft',
8201
+ Scheduled: 'scheduled',
8202
+ Sending: 'sending',
8203
+ Publish: 'publish',
8204
+ Failed: 'failed'
8079
8205
  } as const;
8080
8206
 
8081
- export type ReachV1ContactsContactResourceSubscriptionStatusEnum = typeof ReachV1ContactsContactResourceSubscriptionStatusEnum[keyof typeof ReachV1ContactsContactResourceSubscriptionStatusEnum];
8082
- export const ReachV1ContactsContactResourceSourceEnum = {
8083
- Sync: 'sync',
8084
- Import: 'import',
8085
- Manual: 'manual',
8086
- Api: 'api',
8087
- Form: 'form',
8088
- Checkout: 'checkout',
8089
- Horizons: 'horizons'
8207
+ export type ReachV1CampaignsCampaignDetailsResourceStatusEnum = typeof ReachV1CampaignsCampaignDetailsResourceStatusEnum[keyof typeof ReachV1CampaignsCampaignDetailsResourceStatusEnum];
8208
+ export const ReachV1CampaignsCampaignDetailsResourceTypeEnum = {
8209
+ Campaign: 'campaign',
8210
+ Automation: 'automation',
8211
+ DoubleOptIn: 'double_opt_in'
8090
8212
  } as const;
8091
8213
 
8092
- export type ReachV1ContactsContactResourceSourceEnum = typeof ReachV1ContactsContactResourceSourceEnum[keyof typeof ReachV1ContactsContactResourceSourceEnum];
8214
+ export type ReachV1CampaignsCampaignDetailsResourceTypeEnum = typeof ReachV1CampaignsCampaignDetailsResourceTypeEnum[keyof typeof ReachV1CampaignsCampaignDetailsResourceTypeEnum];
8093
8215
 
8094
8216
  /**
8095
8217
  *
8096
8218
  * @export
8097
- * @interface ReachV1ContactsFieldsContactFieldOptionResource
8219
+ * @interface ReachV1CampaignsCampaignResource
8098
8220
  */
8099
- export interface ReachV1ContactsFieldsContactFieldOptionResource {
8221
+ export interface ReachV1CampaignsCampaignResource {
8100
8222
  /**
8101
8223
  *
8102
8224
  * @type {string}
8103
- * @memberof ReachV1ContactsFieldsContactFieldOptionResource
8225
+ * @memberof ReachV1CampaignsCampaignResource
8104
8226
  */
8105
8227
  'uuid': string;
8106
8228
  /**
8107
8229
  *
8108
8230
  * @type {string}
8109
- * @memberof ReachV1ContactsFieldsContactFieldOptionResource
8231
+ * @memberof ReachV1CampaignsCampaignResource
8110
8232
  */
8111
- 'label': string;
8233
+ 'title': string;
8112
8234
  /**
8113
8235
  *
8114
- * @type {number}
8115
- * @memberof ReachV1ContactsFieldsContactFieldOptionResource
8236
+ * @type {string}
8237
+ * @memberof ReachV1CampaignsCampaignResource
8116
8238
  */
8117
- 'sort_order': number;
8118
- }
8119
- /**
8120
- *
8121
- * @export
8122
- * @interface ReachV1ContactsFieldsContactFieldResource
8123
- */
8124
- export interface ReachV1ContactsFieldsContactFieldResource {
8239
+ 'subject': string;
8125
8240
  /**
8126
8241
  *
8127
8242
  * @type {string}
8128
- * @memberof ReachV1ContactsFieldsContactFieldResource
8243
+ * @memberof ReachV1CampaignsCampaignResource
8129
8244
  */
8130
- 'uuid': string;
8245
+ 'sender_name': string;
8131
8246
  /**
8132
8247
  *
8133
8248
  * @type {string}
8134
- * @memberof ReachV1ContactsFieldsContactFieldResource
8249
+ * @memberof ReachV1CampaignsCampaignResource
8135
8250
  */
8136
- 'type': ReachV1ContactsFieldsContactFieldResourceTypeEnum;
8251
+ 'sender_email': string;
8137
8252
  /**
8138
- *
8253
+ * The email template this campaign uses. The template title is not exposed.
8139
8254
  * @type {string}
8140
- * @memberof ReachV1ContactsFieldsContactFieldResource
8255
+ * @memberof ReachV1CampaignsCampaignResource
8141
8256
  */
8142
- 'label': string;
8257
+ 'template_uuid': string | null;
8143
8258
  /**
8144
- * Derived from the label on creation and immutable afterwards
8259
+ * A fully sent campaign is `publish`. There is no `sent`, `paused` or `archived` status.
8145
8260
  * @type {string}
8146
- * @memberof ReachV1ContactsFieldsContactFieldResource
8261
+ * @memberof ReachV1CampaignsCampaignResource
8147
8262
  */
8148
- 'slug': string;
8263
+ 'status': ReachV1CampaignsCampaignResourceStatusEnum;
8149
8264
  /**
8150
- * Available choices. Always empty for the scalar field types.
8151
- * @type {Array<ReachV1ContactsFieldsContactFieldOptionResource>}
8152
- * @memberof ReachV1ContactsFieldsContactFieldResource
8265
+ *
8266
+ * @type {string}
8267
+ * @memberof ReachV1CampaignsCampaignResource
8153
8268
  */
8154
- 'options': Array<ReachV1ContactsFieldsContactFieldOptionResource>;
8269
+ 'type': ReachV1CampaignsCampaignResourceTypeEnum;
8155
8270
  /**
8156
8271
  *
8157
8272
  * @type {string}
8158
- * @memberof ReachV1ContactsFieldsContactFieldResource
8273
+ * @memberof ReachV1CampaignsCampaignResource
8159
8274
  */
8160
8275
  'created_at': string;
8276
+ /**
8277
+ *
8278
+ * @type {string}
8279
+ * @memberof ReachV1CampaignsCampaignResource
8280
+ */
8281
+ 'updated_at': string | null;
8282
+ /**
8283
+ *
8284
+ * @type {string}
8285
+ * @memberof ReachV1CampaignsCampaignResource
8286
+ */
8287
+ 'sent_at': string | null;
8288
+ /**
8289
+ *
8290
+ * @type {string}
8291
+ * @memberof ReachV1CampaignsCampaignResource
8292
+ */
8293
+ 'scheduled_at': string | null;
8294
+ /**
8295
+ *
8296
+ * @type {ReachV1CampaignsCampaignSummaryStatisticsResource}
8297
+ * @memberof ReachV1CampaignsCampaignResource
8298
+ */
8299
+ 'statistics': ReachV1CampaignsCampaignSummaryStatisticsResource;
8161
8300
  }
8162
8301
 
8163
- export const ReachV1ContactsFieldsContactFieldResourceTypeEnum = {
8164
- Text: 'text',
8165
- Number: 'number',
8166
- Date: 'date',
8167
- SingleChoice: 'single_choice',
8168
- MultiChoice: 'multi_choice'
8302
+ export const ReachV1CampaignsCampaignResourceStatusEnum = {
8303
+ Draft: 'draft',
8304
+ Scheduled: 'scheduled',
8305
+ Sending: 'sending',
8306
+ Publish: 'publish',
8307
+ Failed: 'failed'
8169
8308
  } as const;
8170
8309
 
8171
- export type ReachV1ContactsFieldsContactFieldResourceTypeEnum = typeof ReachV1ContactsFieldsContactFieldResourceTypeEnum[keyof typeof ReachV1ContactsFieldsContactFieldResourceTypeEnum];
8310
+ export type ReachV1CampaignsCampaignResourceStatusEnum = typeof ReachV1CampaignsCampaignResourceStatusEnum[keyof typeof ReachV1CampaignsCampaignResourceStatusEnum];
8311
+ export const ReachV1CampaignsCampaignResourceTypeEnum = {
8312
+ Campaign: 'campaign',
8313
+ Automation: 'automation',
8314
+ DoubleOptIn: 'double_opt_in'
8315
+ } as const;
8316
+
8317
+ export type ReachV1CampaignsCampaignResourceTypeEnum = typeof ReachV1CampaignsCampaignResourceTypeEnum[keyof typeof ReachV1CampaignsCampaignResourceTypeEnum];
8172
8318
 
8173
8319
  /**
8174
- * A custom contact field together with the value held by one contact
8320
+ * Campaign performance. Every count is unique contacts rather than raw events, so a contact who opens the same email five times is counted once.
8175
8321
  * @export
8176
- * @interface ReachV1ContactsFieldsContactFieldValueResource
8322
+ * @interface ReachV1CampaignsCampaignStatisticsResource
8177
8323
  */
8178
- export interface ReachV1ContactsFieldsContactFieldValueResource {
8324
+ export interface ReachV1CampaignsCampaignStatisticsResource {
8325
+ /**
8326
+ * Emails sent for this campaign, and the denominator of every rate below.
8327
+ * @type {number}
8328
+ * @memberof ReachV1CampaignsCampaignStatisticsResource
8329
+ */
8330
+ 'total_sent': number;
8331
+ /**
8332
+ * Recipients this campaign was estimated to reach when sending started. Null for campaigns that have not started sending.
8333
+ * @type {number}
8334
+ * @memberof ReachV1CampaignsCampaignStatisticsResource
8335
+ */
8336
+ 'estimated_total_recipients': number | null;
8179
8337
  /**
8180
8338
  *
8181
- * @type {string}
8182
- * @memberof ReachV1ContactsFieldsContactFieldValueResource
8339
+ * @type {number}
8340
+ * @memberof ReachV1CampaignsCampaignStatisticsResource
8183
8341
  */
8184
- 'uuid': string;
8342
+ 'processed_count': number;
8185
8343
  /**
8186
8344
  *
8187
- * @type {string}
8188
- * @memberof ReachV1ContactsFieldsContactFieldValueResource
8345
+ * @type {number}
8346
+ * @memberof ReachV1CampaignsCampaignStatisticsResource
8189
8347
  */
8190
- 'type': ReachV1ContactsFieldsContactFieldValueResourceTypeEnum;
8348
+ 'delivered_count': number;
8191
8349
  /**
8192
8350
  *
8193
- * @type {string}
8194
- * @memberof ReachV1ContactsFieldsContactFieldValueResource
8351
+ * @type {number}
8352
+ * @memberof ReachV1CampaignsCampaignStatisticsResource
8195
8353
  */
8196
- 'label': string;
8354
+ 'dropped_count': number;
8197
8355
  /**
8198
8356
  *
8199
- * @type {string}
8200
- * @memberof ReachV1ContactsFieldsContactFieldValueResource
8357
+ * @type {number}
8358
+ * @memberof ReachV1CampaignsCampaignStatisticsResource
8201
8359
  */
8202
- 'slug': string;
8360
+ 'bounced_count': number;
8203
8361
  /**
8204
- * Set for the scalar field types, null for the choice types
8205
- * @type {string}
8206
- * @memberof ReachV1ContactsFieldsContactFieldValueResource
8362
+ *
8363
+ * @type {number}
8364
+ * @memberof ReachV1CampaignsCampaignStatisticsResource
8207
8365
  */
8208
- 'value': string | null;
8366
+ 'soft_bounced_count': number;
8209
8367
  /**
8210
- * Chosen options for the choice field types, empty for the scalar types
8211
- * @type {Array<string>}
8212
- * @memberof ReachV1ContactsFieldsContactFieldValueResource
8368
+ * Contacts who opened this campaign.
8369
+ * @type {number}
8370
+ * @memberof ReachV1CampaignsCampaignStatisticsResource
8213
8371
  */
8214
- 'selected_option_uuids': Array<string>;
8372
+ 'opened_count': number;
8215
8373
  /**
8216
- * Every option the field offers, not only the selected ones
8217
- * @type {Array<ReachV1ContactsFieldsContactFieldOptionResource>}
8218
- * @memberof ReachV1ContactsFieldsContactFieldValueResource
8374
+ * Contacts who clicked a link. Only clicks from contacts who also registered an open count.
8375
+ * @type {number}
8376
+ * @memberof ReachV1CampaignsCampaignStatisticsResource
8219
8377
  */
8220
- 'options': Array<ReachV1ContactsFieldsContactFieldOptionResource>;
8378
+ 'clicked_count': number;
8379
+ /**
8380
+ * Contacts who unsubscribed through this campaign.
8381
+ * @type {number}
8382
+ * @memberof ReachV1CampaignsCampaignStatisticsResource
8383
+ */
8384
+ 'unsubscribed_count': number;
8385
+ /**
8386
+ * Percentage of sent emails that were opened.
8387
+ * @type {number}
8388
+ * @memberof ReachV1CampaignsCampaignStatisticsResource
8389
+ */
8390
+ 'open_rate': number;
8391
+ /**
8392
+ * Percentage of sent emails that got a click.
8393
+ * @type {number}
8394
+ * @memberof ReachV1CampaignsCampaignStatisticsResource
8395
+ */
8396
+ 'click_rate': number;
8397
+ /**
8398
+ * Percentage of the contacts who opened that went on to click.
8399
+ * @type {number}
8400
+ * @memberof ReachV1CampaignsCampaignStatisticsResource
8401
+ */
8402
+ 'click_to_open_rate': number;
8403
+ /**
8404
+ * Percentage of sent emails that led to an unsubscribe.
8405
+ * @type {number}
8406
+ * @memberof ReachV1CampaignsCampaignStatisticsResource
8407
+ */
8408
+ 'unsubscribe_rate': number;
8409
+ /**
8410
+ *
8411
+ * @type {boolean}
8412
+ * @memberof ReachV1CampaignsCampaignStatisticsResource
8413
+ */
8414
+ 'has_bounced_contacts': boolean;
8221
8415
  }
8222
-
8223
- export const ReachV1ContactsFieldsContactFieldValueResourceTypeEnum = {
8224
- Text: 'text',
8225
- Number: 'number',
8226
- Date: 'date',
8227
- SingleChoice: 'single_choice',
8228
- MultiChoice: 'multi_choice'
8229
- } as const;
8230
-
8231
- export type ReachV1ContactsFieldsContactFieldValueResourceTypeEnum = typeof ReachV1ContactsFieldsContactFieldValueResourceTypeEnum[keyof typeof ReachV1ContactsFieldsContactFieldValueResourceTypeEnum];
8232
-
8233
8416
  /**
8234
- * Define a custom contact field for the profile
8417
+ * Headline engagement rates. The statistics endpoint carries the full breakdown.
8235
8418
  * @export
8236
- * @interface ReachV1ContactsFieldsStoreRequest
8419
+ * @interface ReachV1CampaignsCampaignSummaryStatisticsResource
8237
8420
  */
8238
- export interface ReachV1ContactsFieldsStoreRequest {
8421
+ export interface ReachV1CampaignsCampaignSummaryStatisticsResource {
8239
8422
  /**
8240
- * Immutable once the field exists
8241
- * @type {string}
8242
- * @memberof ReachV1ContactsFieldsStoreRequest
8423
+ * Emails sent for this campaign, and the denominator of the rates below.
8424
+ * @type {number}
8425
+ * @memberof ReachV1CampaignsCampaignSummaryStatisticsResource
8243
8426
  */
8244
- 'type': ReachV1ContactsFieldsStoreRequestTypeEnum;
8427
+ 'total_sent': number;
8245
8428
  /**
8246
- *
8247
- * @type {string}
8248
- * @memberof ReachV1ContactsFieldsStoreRequest
8429
+ * Percentage of sent emails that were opened.
8430
+ * @type {number}
8431
+ * @memberof ReachV1CampaignsCampaignSummaryStatisticsResource
8249
8432
  */
8250
- 'label': string;
8433
+ 'open_rate': number;
8251
8434
  /**
8252
- * Required for single_choice and multi_choice, ignored for the scalar types. Labels must be unique regardless of casing.
8253
- * @type {Array<string>}
8254
- * @memberof ReachV1ContactsFieldsStoreRequest
8435
+ * Percentage of sent emails that got a click.
8436
+ * @type {number}
8437
+ * @memberof ReachV1CampaignsCampaignSummaryStatisticsResource
8255
8438
  */
8256
- 'options': Array<string>;
8439
+ 'click_rate': number;
8440
+ /**
8441
+ * Percentage of the contacts who opened that went on to click.
8442
+ * @type {number}
8443
+ * @memberof ReachV1CampaignsCampaignSummaryStatisticsResource
8444
+ */
8445
+ 'click_to_open_rate': number;
8257
8446
  }
8258
-
8259
- export const ReachV1ContactsFieldsStoreRequestTypeEnum = {
8260
- Text: 'text',
8261
- Number: 'number',
8262
- Date: 'date',
8263
- SingleChoice: 'single_choice',
8264
- MultiChoice: 'multi_choice'
8265
- } as const;
8266
-
8267
- export type ReachV1ContactsFieldsStoreRequestTypeEnum = typeof ReachV1ContactsFieldsStoreRequestTypeEnum[keyof typeof ReachV1ContactsFieldsStoreRequestTypeEnum];
8268
-
8269
8447
  /**
8270
- * Rename a custom contact field and, for the choice types, replace its option set. The field type and slug are immutable.
8448
+ * Create many contacts in one call
8271
8449
  * @export
8272
- * @interface ReachV1ContactsFieldsUpdateRequest
8450
+ * @interface ReachV1ContactsBulkStoreRequest
8273
8451
  */
8274
- export interface ReachV1ContactsFieldsUpdateRequest {
8452
+ export interface ReachV1ContactsBulkStoreRequest {
8275
8453
  /**
8276
8454
  *
8277
- * @type {string}
8278
- * @memberof ReachV1ContactsFieldsUpdateRequest
8455
+ * @type {Array<ReachV1ContactsBulkStoreRequestContactsInner>}
8456
+ * @memberof ReachV1ContactsBulkStoreRequest
8279
8457
  */
8280
- 'label': string;
8458
+ 'contacts': Array<ReachV1ContactsBulkStoreRequestContactsInner>;
8281
8459
  /**
8282
- * Replaces the option set when provided. Entries carrying a uuid are kept and relabelled, entries without one are created, and any existing option missing from the list is deleted along with the values contacts hold for it.
8283
- * @type {Array<ReachV1ContactsFieldsUpdateRequestOptionsInner>}
8284
- * @memberof ReachV1ContactsFieldsUpdateRequest
8460
+ * Existing tags to attach to every created contact
8461
+ * @type {Array<string>}
8462
+ * @memberof ReachV1ContactsBulkStoreRequest
8285
8463
  */
8286
- 'options': Array<ReachV1ContactsFieldsUpdateRequestOptionsInner> | null;
8464
+ 'tag_uuids': Array<string>;
8465
+ /**
8466
+ * Note applied to every created contact
8467
+ * @type {string}
8468
+ * @memberof ReachV1ContactsBulkStoreRequest
8469
+ */
8470
+ 'note': string | null;
8287
8471
  }
8288
8472
  /**
8289
8473
  *
8290
8474
  * @export
8291
- * @interface ReachV1ContactsFieldsUpdateRequestOptionsInner
8475
+ * @interface ReachV1ContactsBulkStoreRequestContactsInner
8292
8476
  */
8293
- export interface ReachV1ContactsFieldsUpdateRequestOptionsInner {
8477
+ export interface ReachV1ContactsBulkStoreRequestContactsInner {
8294
8478
  /**
8295
8479
  *
8296
8480
  * @type {string}
8297
- * @memberof ReachV1ContactsFieldsUpdateRequestOptionsInner
8481
+ * @memberof ReachV1ContactsBulkStoreRequestContactsInner
8298
8482
  */
8299
- 'uuid': string | null;
8483
+ 'email': string;
8300
8484
  /**
8301
8485
  *
8302
8486
  * @type {string}
8303
- * @memberof ReachV1ContactsFieldsUpdateRequestOptionsInner
8487
+ * @memberof ReachV1ContactsBulkStoreRequestContactsInner
8304
8488
  */
8305
- 'label': string;
8306
- }
8307
- /**
8308
- *
8309
- * @export
8310
- * @interface ReachV1ContactsGroupsContactGroupResource
8311
- */
8312
- export interface ReachV1ContactsGroupsContactGroupResource {
8489
+ 'name': string | null;
8313
8490
  /**
8314
8491
  *
8315
8492
  * @type {string}
8316
- * @memberof ReachV1ContactsGroupsContactGroupResource
8493
+ * @memberof ReachV1ContactsBulkStoreRequestContactsInner
8317
8494
  */
8318
- 'uuid': string;
8495
+ 'surname': string | null;
8319
8496
  /**
8320
- *
8497
+ * Phone number in E.164 format (leading \"+\" then 7-15 digits)
8321
8498
  * @type {string}
8322
- * @memberof ReachV1ContactsGroupsContactGroupResource
8499
+ * @memberof ReachV1ContactsBulkStoreRequestContactsInner
8323
8500
  */
8324
- 'title': string;
8501
+ 'phone': string | null;
8325
8502
  }
8326
8503
  /**
8327
8504
  *
8328
8505
  * @export
8329
- * @interface ReachV1ContactsProfileContactResource
8506
+ * @interface ReachV1ContactsContactDetailsResource
8330
8507
  */
8331
- export interface ReachV1ContactsProfileContactResource {
8508
+ export interface ReachV1ContactsContactDetailsResource {
8332
8509
  /**
8333
8510
  *
8334
8511
  * @type {string}
8335
- * @memberof ReachV1ContactsProfileContactResource
8512
+ * @memberof ReachV1ContactsContactDetailsResource
8336
8513
  */
8337
8514
  'uuid': string;
8338
8515
  /**
8339
8516
  *
8340
8517
  * @type {string}
8341
- * @memberof ReachV1ContactsProfileContactResource
8518
+ * @memberof ReachV1ContactsContactDetailsResource
8342
8519
  */
8343
- 'name': string | null;
8520
+ 'email': string;
8344
8521
  /**
8345
8522
  *
8346
8523
  * @type {string}
8347
- * @memberof ReachV1ContactsProfileContactResource
8524
+ * @memberof ReachV1ContactsContactDetailsResource
8348
8525
  */
8349
- 'surname': string | null;
8526
+ 'name': string | null;
8350
8527
  /**
8351
8528
  *
8352
8529
  * @type {string}
8353
- * @memberof ReachV1ContactsProfileContactResource
8530
+ * @memberof ReachV1ContactsContactDetailsResource
8354
8531
  */
8355
- 'email': string;
8532
+ 'surname': string | null;
8356
8533
  /**
8357
8534
  *
8358
8535
  * @type {string}
8359
- * @memberof ReachV1ContactsProfileContactResource
8536
+ * @memberof ReachV1ContactsContactDetailsResource
8360
8537
  */
8361
8538
  'phone': string | null;
8362
8539
  /**
8363
8540
  *
8364
8541
  * @type {string}
8365
- * @memberof ReachV1ContactsProfileContactResource
8542
+ * @memberof ReachV1ContactsContactDetailsResource
8366
8543
  */
8367
- 'subscription_status': ReachV1ContactsProfileContactResourceSubscriptionStatusEnum;
8544
+ 'subscription_status': ReachV1ContactsContactDetailsResourceSubscriptionStatusEnum;
8368
8545
  /**
8369
8546
  *
8370
8547
  * @type {string}
8371
- * @memberof ReachV1ContactsProfileContactResource
8548
+ * @memberof ReachV1ContactsContactDetailsResource
8372
8549
  */
8373
8550
  'subscribed_at': string | null;
8374
8551
  /**
8375
8552
  *
8376
8553
  * @type {string}
8377
- * @memberof ReachV1ContactsProfileContactResource
8554
+ * @memberof ReachV1ContactsContactDetailsResource
8378
8555
  */
8379
8556
  'unsubscribed_at': string | null;
8380
8557
  /**
8381
8558
  *
8382
8559
  * @type {string}
8383
- * @memberof ReachV1ContactsProfileContactResource
8560
+ * @memberof ReachV1ContactsContactDetailsResource
8384
8561
  */
8385
- 'source': ReachV1ContactsProfileContactResourceSourceEnum | null;
8562
+ 'created_at': string | null;
8386
8563
  /**
8387
8564
  *
8388
8565
  * @type {string}
8389
- * @memberof ReachV1ContactsProfileContactResource
8566
+ * @memberof ReachV1ContactsContactDetailsResource
8567
+ */
8568
+ 'domain': string | null;
8569
+ /**
8570
+ *
8571
+ * @type {string}
8572
+ * @memberof ReachV1ContactsContactDetailsResource
8573
+ */
8574
+ 'source': ReachV1ContactsContactDetailsResourceSourceEnum | null;
8575
+ /**
8576
+ *
8577
+ * @type {string}
8578
+ * @memberof ReachV1ContactsContactDetailsResource
8390
8579
  */
8391
8580
  'note': string | null;
8581
+ /**
8582
+ *
8583
+ * @type {Array<ReachV1ContactsTagsTagResource>}
8584
+ * @memberof ReachV1ContactsContactDetailsResource
8585
+ */
8586
+ 'tags': Array<ReachV1ContactsTagsTagResource>;
8587
+ /**
8588
+ * Custom field values held by this contact
8589
+ * @type {Array<ReachV1ContactsFieldsContactFieldValueResource>}
8590
+ * @memberof ReachV1ContactsContactDetailsResource
8591
+ */
8592
+ 'fields': Array<ReachV1ContactsFieldsContactFieldValueResource>;
8392
8593
  }
8393
8594
 
8394
- export const ReachV1ContactsProfileContactResourceSubscriptionStatusEnum = {
8595
+ export const ReachV1ContactsContactDetailsResourceSubscriptionStatusEnum = {
8395
8596
  Subscribed: 'subscribed',
8396
8597
  Unsubscribed: 'unsubscribed',
8397
8598
  Confirmed: 'confirmed',
8398
8599
  Pending: 'pending'
8399
8600
  } as const;
8400
8601
 
8401
- export type ReachV1ContactsProfileContactResourceSubscriptionStatusEnum = typeof ReachV1ContactsProfileContactResourceSubscriptionStatusEnum[keyof typeof ReachV1ContactsProfileContactResourceSubscriptionStatusEnum];
8402
- export const ReachV1ContactsProfileContactResourceSourceEnum = {
8602
+ export type ReachV1ContactsContactDetailsResourceSubscriptionStatusEnum = typeof ReachV1ContactsContactDetailsResourceSubscriptionStatusEnum[keyof typeof ReachV1ContactsContactDetailsResourceSubscriptionStatusEnum];
8603
+ export const ReachV1ContactsContactDetailsResourceSourceEnum = {
8403
8604
  Sync: 'sync',
8404
8605
  Import: 'import',
8405
8606
  Manual: 'manual',
@@ -8409,450 +8610,560 @@ export const ReachV1ContactsProfileContactResourceSourceEnum = {
8409
8610
  Horizons: 'horizons'
8410
8611
  } as const;
8411
8612
 
8412
- export type ReachV1ContactsProfileContactResourceSourceEnum = typeof ReachV1ContactsProfileContactResourceSourceEnum[keyof typeof ReachV1ContactsProfileContactResourceSourceEnum];
8613
+ export type ReachV1ContactsContactDetailsResourceSourceEnum = typeof ReachV1ContactsContactDetailsResourceSourceEnum[keyof typeof ReachV1ContactsContactDetailsResourceSourceEnum];
8413
8614
 
8414
8615
  /**
8415
8616
  *
8416
8617
  * @export
8417
- * @interface ReachV1ContactsProfileContactUpdateResource
8618
+ * @interface ReachV1ContactsContactResource
8418
8619
  */
8419
- export interface ReachV1ContactsProfileContactUpdateResource {
8620
+ export interface ReachV1ContactsContactResource {
8420
8621
  /**
8421
8622
  *
8422
8623
  * @type {string}
8423
- * @memberof ReachV1ContactsProfileContactUpdateResource
8624
+ * @memberof ReachV1ContactsContactResource
8424
8625
  */
8425
8626
  'uuid': string;
8426
8627
  /**
8427
8628
  *
8428
8629
  * @type {string}
8429
- * @memberof ReachV1ContactsProfileContactUpdateResource
8630
+ * @memberof ReachV1ContactsContactResource
8430
8631
  */
8431
8632
  'name': string | null;
8432
8633
  /**
8433
8634
  *
8434
8635
  * @type {string}
8435
- * @memberof ReachV1ContactsProfileContactUpdateResource
8636
+ * @memberof ReachV1ContactsContactResource
8436
8637
  */
8437
8638
  'surname': string | null;
8438
8639
  /**
8439
8640
  *
8440
8641
  * @type {string}
8441
- * @memberof ReachV1ContactsProfileContactUpdateResource
8642
+ * @memberof ReachV1ContactsContactResource
8442
8643
  */
8443
8644
  'email': string;
8444
8645
  /**
8445
8646
  *
8446
8647
  * @type {string}
8447
- * @memberof ReachV1ContactsProfileContactUpdateResource
8648
+ * @memberof ReachV1ContactsContactResource
8448
8649
  */
8449
- 'phone': string | null;
8650
+ 'subscription_status': ReachV1ContactsContactResourceSubscriptionStatusEnum;
8450
8651
  /**
8451
8652
  *
8452
8653
  * @type {string}
8453
- * @memberof ReachV1ContactsProfileContactUpdateResource
8654
+ * @memberof ReachV1ContactsContactResource
8454
8655
  */
8455
- 'subscription_status': ReachV1ContactsProfileContactUpdateResourceSubscriptionStatusEnum;
8656
+ 'subscribed_at': string;
8456
8657
  /**
8457
8658
  *
8458
8659
  * @type {string}
8459
- * @memberof ReachV1ContactsProfileContactUpdateResource
8660
+ * @memberof ReachV1ContactsContactResource
8460
8661
  */
8461
- 'subscribed_at': string | null;
8662
+ 'source': ReachV1ContactsContactResourceSourceEnum | null;
8462
8663
  /**
8463
8664
  *
8464
8665
  * @type {string}
8465
- * @memberof ReachV1ContactsProfileContactUpdateResource
8666
+ * @memberof ReachV1ContactsContactResource
8466
8667
  */
8467
- 'unsubscribed_at': string | null;
8668
+ 'note': string | null;
8468
8669
  }
8469
8670
 
8470
- export const ReachV1ContactsProfileContactUpdateResourceSubscriptionStatusEnum = {
8671
+ export const ReachV1ContactsContactResourceSubscriptionStatusEnum = {
8471
8672
  Subscribed: 'subscribed',
8472
8673
  Unsubscribed: 'unsubscribed',
8473
8674
  Confirmed: 'confirmed',
8474
8675
  Pending: 'pending'
8475
8676
  } as const;
8476
8677
 
8477
- export type ReachV1ContactsProfileContactUpdateResourceSubscriptionStatusEnum = typeof ReachV1ContactsProfileContactUpdateResourceSubscriptionStatusEnum[keyof typeof ReachV1ContactsProfileContactUpdateResourceSubscriptionStatusEnum];
8678
+ export type ReachV1ContactsContactResourceSubscriptionStatusEnum = typeof ReachV1ContactsContactResourceSubscriptionStatusEnum[keyof typeof ReachV1ContactsContactResourceSubscriptionStatusEnum];
8679
+ export const ReachV1ContactsContactResourceSourceEnum = {
8680
+ Sync: 'sync',
8681
+ Import: 'import',
8682
+ Manual: 'manual',
8683
+ Api: 'api',
8684
+ Form: 'form',
8685
+ Checkout: 'checkout',
8686
+ Horizons: 'horizons'
8687
+ } as const;
8688
+
8689
+ export type ReachV1ContactsContactResourceSourceEnum = typeof ReachV1ContactsContactResourceSourceEnum[keyof typeof ReachV1ContactsContactResourceSourceEnum];
8478
8690
 
8479
8691
  /**
8480
8692
  *
8481
8693
  * @export
8482
- * @interface ReachV1ContactsSegmentsContactSegmentResource
8694
+ * @interface ReachV1ContactsFieldsContactFieldOptionResource
8483
8695
  */
8484
- export interface ReachV1ContactsSegmentsContactSegmentResource {
8696
+ export interface ReachV1ContactsFieldsContactFieldOptionResource {
8485
8697
  /**
8486
8698
  *
8487
8699
  * @type {string}
8488
- * @memberof ReachV1ContactsSegmentsContactSegmentResource
8700
+ * @memberof ReachV1ContactsFieldsContactFieldOptionResource
8489
8701
  */
8490
8702
  'uuid': string;
8491
8703
  /**
8492
8704
  *
8493
8705
  * @type {string}
8494
- * @memberof ReachV1ContactsSegmentsContactSegmentResource
8706
+ * @memberof ReachV1ContactsFieldsContactFieldOptionResource
8495
8707
  */
8496
- 'name': string;
8708
+ 'label': string;
8709
+ /**
8710
+ *
8711
+ * @type {number}
8712
+ * @memberof ReachV1ContactsFieldsContactFieldOptionResource
8713
+ */
8714
+ 'sort_order': number;
8715
+ }
8716
+ /**
8717
+ *
8718
+ * @export
8719
+ * @interface ReachV1ContactsFieldsContactFieldResource
8720
+ */
8721
+ export interface ReachV1ContactsFieldsContactFieldResource {
8497
8722
  /**
8498
8723
  *
8499
8724
  * @type {string}
8500
- * @memberof ReachV1ContactsSegmentsContactSegmentResource
8725
+ * @memberof ReachV1ContactsFieldsContactFieldResource
8501
8726
  */
8502
- 'created_at': string;
8727
+ 'uuid': string;
8503
8728
  /**
8504
8729
  *
8505
8730
  * @type {string}
8506
- * @memberof ReachV1ContactsSegmentsContactSegmentResource
8731
+ * @memberof ReachV1ContactsFieldsContactFieldResource
8507
8732
  */
8508
- 'updated_at': string;
8509
- }
8510
- /**
8511
- * Create a segment from a set of conditions
8512
- * @export
8513
- * @interface ReachV1ContactsSegmentsProfileStoreRequest
8514
- */
8515
- export interface ReachV1ContactsSegmentsProfileStoreRequest {
8733
+ 'type': ReachV1ContactsFieldsContactFieldResourceTypeEnum;
8516
8734
  /**
8517
8735
  *
8518
8736
  * @type {string}
8519
- * @memberof ReachV1ContactsSegmentsProfileStoreRequest
8737
+ * @memberof ReachV1ContactsFieldsContactFieldResource
8520
8738
  */
8521
- 'name': string;
8739
+ 'label': string;
8522
8740
  /**
8523
- * Conditions a contact must satisfy to fall into the segment
8524
- * @type {Array<ReachV1ContactsSegmentsProfileStoreRequestConditionsInner>}
8525
- * @memberof ReachV1ContactsSegmentsProfileStoreRequest
8741
+ * Derived from the label on creation and immutable afterwards
8742
+ * @type {string}
8743
+ * @memberof ReachV1ContactsFieldsContactFieldResource
8526
8744
  */
8527
- 'conditions': Array<ReachV1ContactsSegmentsProfileStoreRequestConditionsInner>;
8745
+ 'slug': string;
8528
8746
  /**
8529
- * How to combine multiple conditions
8747
+ * Available choices. Always empty for the scalar field types.
8748
+ * @type {Array<ReachV1ContactsFieldsContactFieldOptionResource>}
8749
+ * @memberof ReachV1ContactsFieldsContactFieldResource
8750
+ */
8751
+ 'options': Array<ReachV1ContactsFieldsContactFieldOptionResource>;
8752
+ /**
8753
+ *
8530
8754
  * @type {string}
8531
- * @memberof ReachV1ContactsSegmentsProfileStoreRequest
8755
+ * @memberof ReachV1ContactsFieldsContactFieldResource
8532
8756
  */
8533
- 'logic': ReachV1ContactsSegmentsProfileStoreRequestLogicEnum;
8757
+ 'created_at': string;
8534
8758
  }
8535
8759
 
8536
- export const ReachV1ContactsSegmentsProfileStoreRequestLogicEnum = {
8537
- And: 'AND',
8538
- Or: 'OR'
8760
+ export const ReachV1ContactsFieldsContactFieldResourceTypeEnum = {
8761
+ Text: 'text',
8762
+ Number: 'number',
8763
+ Date: 'date',
8764
+ SingleChoice: 'single_choice',
8765
+ MultiChoice: 'multi_choice'
8539
8766
  } as const;
8540
8767
 
8541
- export type ReachV1ContactsSegmentsProfileStoreRequestLogicEnum = typeof ReachV1ContactsSegmentsProfileStoreRequestLogicEnum[keyof typeof ReachV1ContactsSegmentsProfileStoreRequestLogicEnum];
8768
+ export type ReachV1ContactsFieldsContactFieldResourceTypeEnum = typeof ReachV1ContactsFieldsContactFieldResourceTypeEnum[keyof typeof ReachV1ContactsFieldsContactFieldResourceTypeEnum];
8542
8769
 
8543
8770
  /**
8544
- *
8771
+ * A custom contact field together with the value held by one contact
8545
8772
  * @export
8546
- * @interface ReachV1ContactsSegmentsProfileStoreRequestConditionsInner
8773
+ * @interface ReachV1ContactsFieldsContactFieldValueResource
8547
8774
  */
8548
- export interface ReachV1ContactsSegmentsProfileStoreRequestConditionsInner {
8775
+ export interface ReachV1ContactsFieldsContactFieldValueResource {
8549
8776
  /**
8550
- * A built-in contact attribute, or `cf:{fieldUuid}` to target a custom contact field. Custom fields are addressed by field UUID; their slug is not accepted. Built-in attributes: `email`, `note`, `domain`, `source`, `opt_in_method`, `subscription_status`, `subscribed_at`, `unsubscribed_at`, `created_at`, `tag`, `campaigns`, `processed`, `opened`, `clicked`, `delivered`, `bounced`, `soft_bounced`, `dropped`. Which operators are accepted depends on the attribute.
8777
+ *
8551
8778
  * @type {string}
8552
- * @memberof ReachV1ContactsSegmentsProfileStoreRequestConditionsInner
8779
+ * @memberof ReachV1ContactsFieldsContactFieldValueResource
8553
8780
  */
8554
- 'attribute': string;
8781
+ 'uuid': string;
8555
8782
  /**
8556
8783
  *
8557
8784
  * @type {string}
8558
- * @memberof ReachV1ContactsSegmentsProfileStoreRequestConditionsInner
8785
+ * @memberof ReachV1ContactsFieldsContactFieldValueResource
8559
8786
  */
8560
- 'operator': ReachV1ContactsSegmentsProfileStoreRequestConditionsInnerOperatorEnum;
8787
+ 'type': ReachV1ContactsFieldsContactFieldValueResourceTypeEnum;
8561
8788
  /**
8562
- * Always a string, including for numeric and date comparisons
8789
+ *
8563
8790
  * @type {string}
8564
- * @memberof ReachV1ContactsSegmentsProfileStoreRequestConditionsInner
8791
+ * @memberof ReachV1ContactsFieldsContactFieldValueResource
8565
8792
  */
8566
- 'value': string;
8793
+ 'label': string;
8794
+ /**
8795
+ *
8796
+ * @type {string}
8797
+ * @memberof ReachV1ContactsFieldsContactFieldValueResource
8798
+ */
8799
+ 'slug': string;
8800
+ /**
8801
+ * Set for the scalar field types, null for the choice types
8802
+ * @type {string}
8803
+ * @memberof ReachV1ContactsFieldsContactFieldValueResource
8804
+ */
8805
+ 'value': string | null;
8806
+ /**
8807
+ * Chosen options for the choice field types, empty for the scalar types
8808
+ * @type {Array<string>}
8809
+ * @memberof ReachV1ContactsFieldsContactFieldValueResource
8810
+ */
8811
+ 'selected_option_uuids': Array<string>;
8812
+ /**
8813
+ * Every option the field offers, not only the selected ones
8814
+ * @type {Array<ReachV1ContactsFieldsContactFieldOptionResource>}
8815
+ * @memberof ReachV1ContactsFieldsContactFieldValueResource
8816
+ */
8817
+ 'options': Array<ReachV1ContactsFieldsContactFieldOptionResource>;
8567
8818
  }
8568
8819
 
8569
- export const ReachV1ContactsSegmentsProfileStoreRequestConditionsInnerOperatorEnum = {
8570
- Equals: 'equals',
8571
- NotEquals: 'not_equals',
8572
- Contains: 'contains',
8573
- NotContains: 'not_contains',
8574
- Gte: 'gte',
8575
- Lte: 'lte',
8576
- Exists: 'exists',
8577
- WithinLastDays: 'within_last_days',
8578
- NotWithinLastDays: 'not_within_last_days',
8579
- OlderThanDays: 'older_than_days',
8580
- Processed: 'processed',
8581
- NotProcessed: 'not_processed',
8582
- Delivered: 'delivered',
8583
- NotDelivered: 'not_delivered',
8584
- Dropped: 'dropped',
8585
- NotDropped: 'not_dropped',
8586
- Bounced: 'bounced',
8587
- NotBounced: 'not_bounced',
8588
- SoftBounced: 'soft_bounced',
8589
- NotSoftBounced: 'not_soft_bounced',
8590
- Opened: 'opened',
8591
- NotOpened: 'not_opened',
8592
- Clicked: 'clicked',
8593
- NotClicked: 'not_clicked',
8594
- Unsubscribed: 'unsubscribed',
8595
- NotUnsubscribed: 'not_unsubscribed'
8820
+ export const ReachV1ContactsFieldsContactFieldValueResourceTypeEnum = {
8821
+ Text: 'text',
8822
+ Number: 'number',
8823
+ Date: 'date',
8824
+ SingleChoice: 'single_choice',
8825
+ MultiChoice: 'multi_choice'
8596
8826
  } as const;
8597
8827
 
8598
- export type ReachV1ContactsSegmentsProfileStoreRequestConditionsInnerOperatorEnum = typeof ReachV1ContactsSegmentsProfileStoreRequestConditionsInnerOperatorEnum[keyof typeof ReachV1ContactsSegmentsProfileStoreRequestConditionsInnerOperatorEnum];
8828
+ export type ReachV1ContactsFieldsContactFieldValueResourceTypeEnum = typeof ReachV1ContactsFieldsContactFieldValueResourceTypeEnum[keyof typeof ReachV1ContactsFieldsContactFieldValueResourceTypeEnum];
8599
8829
 
8600
8830
  /**
8601
- * Rename a segment and/or replace the conditions that define it
8831
+ * Define a custom contact field for the profile
8602
8832
  * @export
8603
- * @interface ReachV1ContactsSegmentsProfileUpdateRequest
8833
+ * @interface ReachV1ContactsFieldsStoreRequest
8604
8834
  */
8605
- export interface ReachV1ContactsSegmentsProfileUpdateRequest {
8835
+ export interface ReachV1ContactsFieldsStoreRequest {
8606
8836
  /**
8607
- *
8837
+ * Immutable once the field exists
8608
8838
  * @type {string}
8609
- * @memberof ReachV1ContactsSegmentsProfileUpdateRequest
8839
+ * @memberof ReachV1ContactsFieldsStoreRequest
8610
8840
  */
8611
- 'name': string;
8841
+ 'type': ReachV1ContactsFieldsStoreRequestTypeEnum;
8612
8842
  /**
8613
- * Replaces the existing conditions entirely. Omit to keep the current ones.
8614
- * @type {Array<ReachV1ContactsSegmentsProfileStoreRequestConditionsInner>}
8615
- * @memberof ReachV1ContactsSegmentsProfileUpdateRequest
8843
+ *
8844
+ * @type {string}
8845
+ * @memberof ReachV1ContactsFieldsStoreRequest
8616
8846
  */
8617
- 'conditions': Array<ReachV1ContactsSegmentsProfileStoreRequestConditionsInner>;
8847
+ 'label': string;
8618
8848
  /**
8619
- * How to combine multiple conditions. Required when conditions are given.
8620
- * @type {string}
8621
- * @memberof ReachV1ContactsSegmentsProfileUpdateRequest
8849
+ * Required for single_choice and multi_choice, ignored for the scalar types. Labels must be unique regardless of casing.
8850
+ * @type {Array<string>}
8851
+ * @memberof ReachV1ContactsFieldsStoreRequest
8622
8852
  */
8623
- 'logic': ReachV1ContactsSegmentsProfileUpdateRequestLogicEnum;
8853
+ 'options': Array<string>;
8624
8854
  }
8625
8855
 
8626
- export const ReachV1ContactsSegmentsProfileUpdateRequestLogicEnum = {
8627
- And: 'AND',
8628
- Or: 'OR'
8856
+ export const ReachV1ContactsFieldsStoreRequestTypeEnum = {
8857
+ Text: 'text',
8858
+ Number: 'number',
8859
+ Date: 'date',
8860
+ SingleChoice: 'single_choice',
8861
+ MultiChoice: 'multi_choice'
8629
8862
  } as const;
8630
8863
 
8631
- export type ReachV1ContactsSegmentsProfileUpdateRequestLogicEnum = typeof ReachV1ContactsSegmentsProfileUpdateRequestLogicEnum[keyof typeof ReachV1ContactsSegmentsProfileUpdateRequestLogicEnum];
8864
+ export type ReachV1ContactsFieldsStoreRequestTypeEnum = typeof ReachV1ContactsFieldsStoreRequestTypeEnum[keyof typeof ReachV1ContactsFieldsStoreRequestTypeEnum];
8632
8865
 
8633
8866
  /**
8634
- *
8867
+ * Rename a custom contact field and, for the choice types, replace its option set. The field type and slug are immutable.
8635
8868
  * @export
8636
- * @interface ReachV1ContactsSegmentsSegmentContactsCountResource
8869
+ * @interface ReachV1ContactsFieldsUpdateRequest
8637
8870
  */
8638
- export interface ReachV1ContactsSegmentsSegmentContactsCountResource {
8871
+ export interface ReachV1ContactsFieldsUpdateRequest {
8639
8872
  /**
8640
- * Contacts currently matching the segment conditions
8641
- * @type {number}
8642
- * @memberof ReachV1ContactsSegmentsSegmentContactsCountResource
8873
+ *
8874
+ * @type {string}
8875
+ * @memberof ReachV1ContactsFieldsUpdateRequest
8643
8876
  */
8644
- 'count': number;
8877
+ 'label': string;
8878
+ /**
8879
+ * Replaces the option set when provided. Entries carrying a uuid are kept and relabelled, entries without one are created, and any existing option missing from the list is deleted along with the values contacts hold for it.
8880
+ * @type {Array<ReachV1ContactsFieldsUpdateRequestOptionsInner>}
8881
+ * @memberof ReachV1ContactsFieldsUpdateRequest
8882
+ */
8883
+ 'options': Array<ReachV1ContactsFieldsUpdateRequestOptionsInner> | null;
8645
8884
  }
8646
8885
  /**
8647
8886
  *
8648
8887
  * @export
8649
- * @interface ReachV1ContactsSegmentsSegmentListItemResource
8888
+ * @interface ReachV1ContactsFieldsUpdateRequestOptionsInner
8650
8889
  */
8651
- export interface ReachV1ContactsSegmentsSegmentListItemResource {
8890
+ export interface ReachV1ContactsFieldsUpdateRequestOptionsInner {
8652
8891
  /**
8653
8892
  *
8654
8893
  * @type {string}
8655
- * @memberof ReachV1ContactsSegmentsSegmentListItemResource
8894
+ * @memberof ReachV1ContactsFieldsUpdateRequestOptionsInner
8656
8895
  */
8657
- 'uuid': string;
8896
+ 'uuid': string | null;
8658
8897
  /**
8659
8898
  *
8660
8899
  * @type {string}
8661
- * @memberof ReachV1ContactsSegmentsSegmentListItemResource
8662
- */
8663
- 'name': string;
8664
- /**
8665
- * Contacts currently matching the segment conditions
8666
- * @type {number}
8667
- * @memberof ReachV1ContactsSegmentsSegmentListItemResource
8900
+ * @memberof ReachV1ContactsFieldsUpdateRequestOptionsInner
8668
8901
  */
8669
- 'contacts_count': number;
8902
+ 'label': string;
8903
+ }
8904
+ /**
8905
+ *
8906
+ * @export
8907
+ * @interface ReachV1ContactsGroupsContactGroupResource
8908
+ */
8909
+ export interface ReachV1ContactsGroupsContactGroupResource {
8670
8910
  /**
8671
8911
  *
8672
8912
  * @type {string}
8673
- * @memberof ReachV1ContactsSegmentsSegmentListItemResource
8913
+ * @memberof ReachV1ContactsGroupsContactGroupResource
8674
8914
  */
8675
- 'created_at': string;
8915
+ 'uuid': string;
8676
8916
  /**
8677
8917
  *
8678
8918
  * @type {string}
8679
- * @memberof ReachV1ContactsSegmentsSegmentListItemResource
8919
+ * @memberof ReachV1ContactsGroupsContactGroupResource
8680
8920
  */
8681
- 'updated_at': string;
8921
+ 'title': string;
8682
8922
  }
8683
8923
  /**
8684
8924
  *
8685
8925
  * @export
8686
- * @interface ReachV1ContactsSegmentsSegmentResource
8926
+ * @interface ReachV1ContactsProfileContactResource
8687
8927
  */
8688
- export interface ReachV1ContactsSegmentsSegmentResource {
8928
+ export interface ReachV1ContactsProfileContactResource {
8689
8929
  /**
8690
8930
  *
8691
8931
  * @type {string}
8692
- * @memberof ReachV1ContactsSegmentsSegmentResource
8932
+ * @memberof ReachV1ContactsProfileContactResource
8693
8933
  */
8694
8934
  'uuid': string;
8695
8935
  /**
8696
8936
  *
8697
8937
  * @type {string}
8698
- * @memberof ReachV1ContactsSegmentsSegmentResource
8938
+ * @memberof ReachV1ContactsProfileContactResource
8699
8939
  */
8700
- 'name': string;
8940
+ 'name': string | null;
8701
8941
  /**
8702
8942
  *
8703
- * @type {Array<any>}
8704
- * @memberof ReachV1ContactsSegmentsSegmentResource
8943
+ * @type {string}
8944
+ * @memberof ReachV1ContactsProfileContactResource
8705
8945
  */
8706
- 'query': Array<any>;
8946
+ 'surname': string | null;
8707
8947
  /**
8708
8948
  *
8709
8949
  * @type {string}
8710
- * @memberof ReachV1ContactsSegmentsSegmentResource
8950
+ * @memberof ReachV1ContactsProfileContactResource
8711
8951
  */
8712
- 'created_at': string;
8952
+ 'email': string;
8713
8953
  /**
8714
8954
  *
8715
8955
  * @type {string}
8716
- * @memberof ReachV1ContactsSegmentsSegmentResource
8956
+ * @memberof ReachV1ContactsProfileContactResource
8717
8957
  */
8718
- 'updated_at': string;
8958
+ 'phone': string | null;
8959
+ /**
8960
+ *
8961
+ * @type {string}
8962
+ * @memberof ReachV1ContactsProfileContactResource
8963
+ */
8964
+ 'subscription_status': ReachV1ContactsProfileContactResourceSubscriptionStatusEnum;
8965
+ /**
8966
+ *
8967
+ * @type {string}
8968
+ * @memberof ReachV1ContactsProfileContactResource
8969
+ */
8970
+ 'subscribed_at': string | null;
8971
+ /**
8972
+ *
8973
+ * @type {string}
8974
+ * @memberof ReachV1ContactsProfileContactResource
8975
+ */
8976
+ 'unsubscribed_at': string | null;
8977
+ /**
8978
+ *
8979
+ * @type {string}
8980
+ * @memberof ReachV1ContactsProfileContactResource
8981
+ */
8982
+ 'source': ReachV1ContactsProfileContactResourceSourceEnum | null;
8983
+ /**
8984
+ *
8985
+ * @type {string}
8986
+ * @memberof ReachV1ContactsProfileContactResource
8987
+ */
8988
+ 'note': string | null;
8719
8989
  }
8990
+
8991
+ export const ReachV1ContactsProfileContactResourceSubscriptionStatusEnum = {
8992
+ Subscribed: 'subscribed',
8993
+ Unsubscribed: 'unsubscribed',
8994
+ Confirmed: 'confirmed',
8995
+ Pending: 'pending'
8996
+ } as const;
8997
+
8998
+ export type ReachV1ContactsProfileContactResourceSubscriptionStatusEnum = typeof ReachV1ContactsProfileContactResourceSubscriptionStatusEnum[keyof typeof ReachV1ContactsProfileContactResourceSubscriptionStatusEnum];
8999
+ export const ReachV1ContactsProfileContactResourceSourceEnum = {
9000
+ Sync: 'sync',
9001
+ Import: 'import',
9002
+ Manual: 'manual',
9003
+ Api: 'api',
9004
+ Form: 'form',
9005
+ Checkout: 'checkout',
9006
+ Horizons: 'horizons'
9007
+ } as const;
9008
+
9009
+ export type ReachV1ContactsProfileContactResourceSourceEnum = typeof ReachV1ContactsProfileContactResourceSourceEnum[keyof typeof ReachV1ContactsProfileContactResourceSourceEnum];
9010
+
8720
9011
  /**
8721
9012
  *
8722
9013
  * @export
8723
- * @interface ReachV1ContactsSegmentsSegmentationContactResource
9014
+ * @interface ReachV1ContactsProfileContactUpdateResource
8724
9015
  */
8725
- export interface ReachV1ContactsSegmentsSegmentationContactResource {
9016
+ export interface ReachV1ContactsProfileContactUpdateResource {
8726
9017
  /**
8727
9018
  *
8728
9019
  * @type {string}
8729
- * @memberof ReachV1ContactsSegmentsSegmentationContactResource
9020
+ * @memberof ReachV1ContactsProfileContactUpdateResource
8730
9021
  */
8731
9022
  'uuid': string;
8732
9023
  /**
8733
9024
  *
8734
9025
  * @type {string}
8735
- * @memberof ReachV1ContactsSegmentsSegmentationContactResource
9026
+ * @memberof ReachV1ContactsProfileContactUpdateResource
8736
9027
  */
8737
9028
  'name': string | null;
8738
9029
  /**
8739
9030
  *
8740
9031
  * @type {string}
8741
- * @memberof ReachV1ContactsSegmentsSegmentationContactResource
9032
+ * @memberof ReachV1ContactsProfileContactUpdateResource
8742
9033
  */
8743
9034
  'surname': string | null;
8744
9035
  /**
8745
9036
  *
8746
9037
  * @type {string}
8747
- * @memberof ReachV1ContactsSegmentsSegmentationContactResource
9038
+ * @memberof ReachV1ContactsProfileContactUpdateResource
8748
9039
  */
8749
9040
  'email': string;
8750
9041
  /**
8751
9042
  *
8752
9043
  * @type {string}
8753
- * @memberof ReachV1ContactsSegmentsSegmentationContactResource
9044
+ * @memberof ReachV1ContactsProfileContactUpdateResource
8754
9045
  */
8755
- 'subscription_status': ReachV1ContactsSegmentsSegmentationContactResourceSubscriptionStatusEnum;
9046
+ 'phone': string | null;
8756
9047
  /**
8757
9048
  *
8758
9049
  * @type {string}
8759
- * @memberof ReachV1ContactsSegmentsSegmentationContactResource
9050
+ * @memberof ReachV1ContactsProfileContactUpdateResource
8760
9051
  */
8761
- 'subscribed_at': string;
9052
+ 'subscription_status': ReachV1ContactsProfileContactUpdateResourceSubscriptionStatusEnum;
8762
9053
  /**
8763
9054
  *
8764
9055
  * @type {string}
8765
- * @memberof ReachV1ContactsSegmentsSegmentationContactResource
9056
+ * @memberof ReachV1ContactsProfileContactUpdateResource
8766
9057
  */
8767
- 'source': ReachV1ContactsSegmentsSegmentationContactResourceSourceEnum | null;
9058
+ 'subscribed_at': string | null;
8768
9059
  /**
8769
9060
  *
8770
9061
  * @type {string}
8771
- * @memberof ReachV1ContactsSegmentsSegmentationContactResource
9062
+ * @memberof ReachV1ContactsProfileContactUpdateResource
8772
9063
  */
8773
- 'note': string | null;
9064
+ 'unsubscribed_at': string | null;
8774
9065
  }
8775
9066
 
8776
- export const ReachV1ContactsSegmentsSegmentationContactResourceSubscriptionStatusEnum = {
9067
+ export const ReachV1ContactsProfileContactUpdateResourceSubscriptionStatusEnum = {
8777
9068
  Subscribed: 'subscribed',
8778
9069
  Unsubscribed: 'unsubscribed',
8779
9070
  Confirmed: 'confirmed',
8780
9071
  Pending: 'pending'
8781
9072
  } as const;
8782
9073
 
8783
- export type ReachV1ContactsSegmentsSegmentationContactResourceSubscriptionStatusEnum = typeof ReachV1ContactsSegmentsSegmentationContactResourceSubscriptionStatusEnum[keyof typeof ReachV1ContactsSegmentsSegmentationContactResourceSubscriptionStatusEnum];
8784
- export const ReachV1ContactsSegmentsSegmentationContactResourceSourceEnum = {
8785
- Sync: 'sync',
8786
- Import: 'import',
8787
- Manual: 'manual',
8788
- Api: 'api',
8789
- Form: 'form',
8790
- Checkout: 'checkout',
8791
- Horizons: 'horizons'
8792
- } as const;
8793
-
8794
- export type ReachV1ContactsSegmentsSegmentationContactResourceSourceEnum = typeof ReachV1ContactsSegmentsSegmentationContactResourceSourceEnum[keyof typeof ReachV1ContactsSegmentsSegmentationContactResourceSourceEnum];
9074
+ export type ReachV1ContactsProfileContactUpdateResourceSubscriptionStatusEnum = typeof ReachV1ContactsProfileContactUpdateResourceSubscriptionStatusEnum[keyof typeof ReachV1ContactsProfileContactUpdateResourceSubscriptionStatusEnum];
8795
9075
 
8796
9076
  /**
8797
9077
  *
8798
9078
  * @export
8799
- * @interface ReachV1ContactsSegmentsStoreRequest
9079
+ * @interface ReachV1ContactsSegmentsContactSegmentResource
8800
9080
  */
8801
- export interface ReachV1ContactsSegmentsStoreRequest {
9081
+ export interface ReachV1ContactsSegmentsContactSegmentResource {
8802
9082
  /**
8803
9083
  *
8804
9084
  * @type {string}
8805
- * @memberof ReachV1ContactsSegmentsStoreRequest
9085
+ * @memberof ReachV1ContactsSegmentsContactSegmentResource
9086
+ */
9087
+ 'uuid': string;
9088
+ /**
9089
+ *
9090
+ * @type {string}
9091
+ * @memberof ReachV1ContactsSegmentsContactSegmentResource
8806
9092
  */
8807
9093
  'name': string;
8808
9094
  /**
8809
9095
  *
8810
- * @type {Array<ReachV1ContactsSegmentsStoreRequestConditionsInner>}
8811
- * @memberof ReachV1ContactsSegmentsStoreRequest
9096
+ * @type {string}
9097
+ * @memberof ReachV1ContactsSegmentsContactSegmentResource
8812
9098
  */
8813
- 'conditions': Array<ReachV1ContactsSegmentsStoreRequestConditionsInner>;
9099
+ 'created_at': string;
8814
9100
  /**
8815
9101
  *
8816
9102
  * @type {string}
8817
- * @memberof ReachV1ContactsSegmentsStoreRequest
9103
+ * @memberof ReachV1ContactsSegmentsContactSegmentResource
8818
9104
  */
8819
- 'logic': ReachV1ContactsSegmentsStoreRequestLogicEnum;
9105
+ 'updated_at': string;
9106
+ }
9107
+ /**
9108
+ * Create a segment from a set of conditions
9109
+ * @export
9110
+ * @interface ReachV1ContactsSegmentsProfileStoreRequest
9111
+ */
9112
+ export interface ReachV1ContactsSegmentsProfileStoreRequest {
9113
+ /**
9114
+ *
9115
+ * @type {string}
9116
+ * @memberof ReachV1ContactsSegmentsProfileStoreRequest
9117
+ */
9118
+ 'name': string;
9119
+ /**
9120
+ * Conditions a contact must satisfy to fall into the segment
9121
+ * @type {Array<ReachV1ContactsSegmentsProfileStoreRequestConditionsInner>}
9122
+ * @memberof ReachV1ContactsSegmentsProfileStoreRequest
9123
+ */
9124
+ 'conditions': Array<ReachV1ContactsSegmentsProfileStoreRequestConditionsInner>;
9125
+ /**
9126
+ * How to combine multiple conditions
9127
+ * @type {string}
9128
+ * @memberof ReachV1ContactsSegmentsProfileStoreRequest
9129
+ */
9130
+ 'logic': ReachV1ContactsSegmentsProfileStoreRequestLogicEnum;
8820
9131
  }
8821
9132
 
8822
- export const ReachV1ContactsSegmentsStoreRequestLogicEnum = {
9133
+ export const ReachV1ContactsSegmentsProfileStoreRequestLogicEnum = {
8823
9134
  And: 'AND',
8824
9135
  Or: 'OR'
8825
9136
  } as const;
8826
9137
 
8827
- export type ReachV1ContactsSegmentsStoreRequestLogicEnum = typeof ReachV1ContactsSegmentsStoreRequestLogicEnum[keyof typeof ReachV1ContactsSegmentsStoreRequestLogicEnum];
9138
+ export type ReachV1ContactsSegmentsProfileStoreRequestLogicEnum = typeof ReachV1ContactsSegmentsProfileStoreRequestLogicEnum[keyof typeof ReachV1ContactsSegmentsProfileStoreRequestLogicEnum];
8828
9139
 
8829
9140
  /**
8830
9141
  *
8831
9142
  * @export
8832
- * @interface ReachV1ContactsSegmentsStoreRequestConditionsInner
9143
+ * @interface ReachV1ContactsSegmentsProfileStoreRequestConditionsInner
8833
9144
  */
8834
- export interface ReachV1ContactsSegmentsStoreRequestConditionsInner {
9145
+ export interface ReachV1ContactsSegmentsProfileStoreRequestConditionsInner {
8835
9146
  /**
8836
- *
9147
+ * A built-in contact attribute, or `cf:{fieldUuid}` to target a custom contact field. Custom fields are addressed by field UUID; their slug is not accepted. Built-in attributes: `email`, `note`, `domain`, `source`, `opt_in_method`, `subscription_status`, `subscribed_at`, `unsubscribed_at`, `created_at`, `tag`, `campaigns`, `processed`, `opened`, `clicked`, `delivered`, `bounced`, `soft_bounced`, `dropped`. Which operators are accepted depends on the attribute.
8837
9148
  * @type {string}
8838
- * @memberof ReachV1ContactsSegmentsStoreRequestConditionsInner
9149
+ * @memberof ReachV1ContactsSegmentsProfileStoreRequestConditionsInner
8839
9150
  */
8840
- 'operator': ReachV1ContactsSegmentsStoreRequestConditionsInnerOperatorEnum;
9151
+ 'attribute': string;
8841
9152
  /**
8842
9153
  *
8843
- * @type {ReachV1ContactsSegmentsStoreRequestConditionsInnerValue}
8844
- * @memberof ReachV1ContactsSegmentsStoreRequestConditionsInner
9154
+ * @type {string}
9155
+ * @memberof ReachV1ContactsSegmentsProfileStoreRequestConditionsInner
8845
9156
  */
8846
- 'value': ReachV1ContactsSegmentsStoreRequestConditionsInnerValue;
9157
+ 'operator': ReachV1ContactsSegmentsProfileStoreRequestConditionsInnerOperatorEnum;
8847
9158
  /**
8848
- *
9159
+ * Always a string, including for numeric and date comparisons
8849
9160
  * @type {string}
8850
- * @memberof ReachV1ContactsSegmentsStoreRequestConditionsInner
9161
+ * @memberof ReachV1ContactsSegmentsProfileStoreRequestConditionsInner
8851
9162
  */
8852
- 'attribute': ReachV1ContactsSegmentsStoreRequestConditionsInnerAttributeEnum;
9163
+ 'value': string;
8853
9164
  }
8854
9165
 
8855
- export const ReachV1ContactsSegmentsStoreRequestConditionsInnerOperatorEnum = {
9166
+ export const ReachV1ContactsSegmentsProfileStoreRequestConditionsInnerOperatorEnum = {
8856
9167
  Equals: 'equals',
8857
9168
  NotEquals: 'not_equals',
8858
9169
  Contains: 'contains',
@@ -8881,455 +9192,741 @@ export const ReachV1ContactsSegmentsStoreRequestConditionsInnerOperatorEnum = {
8881
9192
  NotUnsubscribed: 'not_unsubscribed'
8882
9193
  } as const;
8883
9194
 
8884
- export type ReachV1ContactsSegmentsStoreRequestConditionsInnerOperatorEnum = typeof ReachV1ContactsSegmentsStoreRequestConditionsInnerOperatorEnum[keyof typeof ReachV1ContactsSegmentsStoreRequestConditionsInnerOperatorEnum];
8885
- export const ReachV1ContactsSegmentsStoreRequestConditionsInnerAttributeEnum = {
8886
- Note: 'note',
8887
- Comment: 'comment',
8888
- Domain: 'domain',
8889
- Integration: 'integration',
8890
- Source: 'source',
8891
- Name: 'name',
8892
- Surname: 'surname',
8893
- Email: 'email',
8894
- SubscribedAt: 'subscribed_at',
8895
- UnsubscribedAt: 'unsubscribed_at',
8896
- SubscriptionStatus: 'subscription_status',
8897
- Processed: 'processed',
8898
- Opened: 'opened',
8899
- Clicked: 'clicked',
8900
- Delivered: 'delivered',
8901
- Bounced: 'bounced',
8902
- Unsubscribed: 'unsubscribed',
8903
- Dropped: 'dropped',
8904
- Tag: 'tag',
8905
- Campaigns: 'campaigns'
8906
- } as const;
8907
-
8908
- export type ReachV1ContactsSegmentsStoreRequestConditionsInnerAttributeEnum = typeof ReachV1ContactsSegmentsStoreRequestConditionsInnerAttributeEnum[keyof typeof ReachV1ContactsSegmentsStoreRequestConditionsInnerAttributeEnum];
9195
+ export type ReachV1ContactsSegmentsProfileStoreRequestConditionsInnerOperatorEnum = typeof ReachV1ContactsSegmentsProfileStoreRequestConditionsInnerOperatorEnum[keyof typeof ReachV1ContactsSegmentsProfileStoreRequestConditionsInnerOperatorEnum];
8909
9196
 
8910
9197
  /**
8911
- * @type ReachV1ContactsSegmentsStoreRequestConditionsInnerValue
9198
+ * Rename a segment and/or replace the conditions that define it
8912
9199
  * @export
9200
+ * @interface ReachV1ContactsSegmentsProfileUpdateRequest
8913
9201
  */
8914
- export type ReachV1ContactsSegmentsStoreRequestConditionsInnerValue = number | string;
8915
-
8916
- /**
8917
- *
8918
- * @export
8919
- * @interface ReachV1ContactsStoreRequest
8920
- */
8921
- export interface ReachV1ContactsStoreRequest {
9202
+ export interface ReachV1ContactsSegmentsProfileUpdateRequest {
8922
9203
  /**
8923
9204
  *
8924
9205
  * @type {string}
8925
- * @memberof ReachV1ContactsStoreRequest
9206
+ * @memberof ReachV1ContactsSegmentsProfileUpdateRequest
8926
9207
  */
8927
- 'email': string;
9208
+ 'name': string;
8928
9209
  /**
8929
- *
8930
- * @type {string}
8931
- * @memberof ReachV1ContactsStoreRequest
9210
+ * Replaces the existing conditions entirely. Omit to keep the current ones.
9211
+ * @type {Array<ReachV1ContactsSegmentsProfileStoreRequestConditionsInner>}
9212
+ * @memberof ReachV1ContactsSegmentsProfileUpdateRequest
8932
9213
  */
8933
- 'name': string | null;
9214
+ 'conditions': Array<ReachV1ContactsSegmentsProfileStoreRequestConditionsInner>;
8934
9215
  /**
8935
- *
9216
+ * How to combine multiple conditions. Required when conditions are given.
8936
9217
  * @type {string}
8937
- * @memberof ReachV1ContactsStoreRequest
9218
+ * @memberof ReachV1ContactsSegmentsProfileUpdateRequest
8938
9219
  */
8939
- 'surname': string | null;
9220
+ 'logic': ReachV1ContactsSegmentsProfileUpdateRequestLogicEnum;
9221
+ }
9222
+
9223
+ export const ReachV1ContactsSegmentsProfileUpdateRequestLogicEnum = {
9224
+ And: 'AND',
9225
+ Or: 'OR'
9226
+ } as const;
9227
+
9228
+ export type ReachV1ContactsSegmentsProfileUpdateRequestLogicEnum = typeof ReachV1ContactsSegmentsProfileUpdateRequestLogicEnum[keyof typeof ReachV1ContactsSegmentsProfileUpdateRequestLogicEnum];
9229
+
9230
+ /**
9231
+ *
9232
+ * @export
9233
+ * @interface ReachV1ContactsSegmentsSegmentContactsCountResource
9234
+ */
9235
+ export interface ReachV1ContactsSegmentsSegmentContactsCountResource {
8940
9236
  /**
8941
- * Phone number in E.164 format (leading \"+\" then 7-15 digits)
9237
+ * Contacts currently matching the segment conditions
9238
+ * @type {number}
9239
+ * @memberof ReachV1ContactsSegmentsSegmentContactsCountResource
9240
+ */
9241
+ 'count': number;
9242
+ }
9243
+ /**
9244
+ *
9245
+ * @export
9246
+ * @interface ReachV1ContactsSegmentsSegmentListItemResource
9247
+ */
9248
+ export interface ReachV1ContactsSegmentsSegmentListItemResource {
9249
+ /**
9250
+ *
8942
9251
  * @type {string}
8943
- * @memberof ReachV1ContactsStoreRequest
9252
+ * @memberof ReachV1ContactsSegmentsSegmentListItemResource
8944
9253
  */
8945
- 'phone': string | null;
9254
+ 'uuid': string;
8946
9255
  /**
8947
9256
  *
8948
9257
  * @type {string}
8949
- * @memberof ReachV1ContactsStoreRequest
9258
+ * @memberof ReachV1ContactsSegmentsSegmentListItemResource
8950
9259
  */
8951
- 'note': string | null;
8952
- }
8953
- /**
8954
- * Contacts to assign to, or remove from, a tag
8955
- * @export
8956
- * @interface ReachV1ContactsTagsManageContactsRequest
8957
- */
8958
- export interface ReachV1ContactsTagsManageContactsRequest {
9260
+ 'name': string;
8959
9261
  /**
8960
- * Contacts to apply the change to. Required unless all_contacts is true.
8961
- * @type {Array<string>}
8962
- * @memberof ReachV1ContactsTagsManageContactsRequest
9262
+ * Contacts currently matching the segment conditions
9263
+ * @type {number}
9264
+ * @memberof ReachV1ContactsSegmentsSegmentListItemResource
8963
9265
  */
8964
- 'contact_uuids': Array<string>;
9266
+ 'contacts_count': number;
8965
9267
  /**
8966
- * Apply to every contact in the profile
8967
- * @type {boolean}
8968
- * @memberof ReachV1ContactsTagsManageContactsRequest
9268
+ *
9269
+ * @type {string}
9270
+ * @memberof ReachV1ContactsSegmentsSegmentListItemResource
8969
9271
  */
8970
- 'all_contacts': boolean;
8971
- }
8972
- /**
8973
- * Names to create. Names that already exist in the profile are returned as they are.
8974
- * @export
8975
- * @interface ReachV1ContactsTagsStoreRequest
8976
- */
8977
- export interface ReachV1ContactsTagsStoreRequest {
9272
+ 'created_at': string;
8978
9273
  /**
8979
9274
  *
8980
- * @type {Array<string>}
8981
- * @memberof ReachV1ContactsTagsStoreRequest
9275
+ * @type {string}
9276
+ * @memberof ReachV1ContactsSegmentsSegmentListItemResource
8982
9277
  */
8983
- 'names': Array<string>;
9278
+ 'updated_at': string;
8984
9279
  }
8985
9280
  /**
8986
9281
  *
8987
9282
  * @export
8988
- * @interface ReachV1ContactsTagsTagResource
9283
+ * @interface ReachV1ContactsSegmentsSegmentResource
8989
9284
  */
8990
- export interface ReachV1ContactsTagsTagResource {
9285
+ export interface ReachV1ContactsSegmentsSegmentResource {
8991
9286
  /**
8992
9287
  *
8993
9288
  * @type {string}
8994
- * @memberof ReachV1ContactsTagsTagResource
9289
+ * @memberof ReachV1ContactsSegmentsSegmentResource
8995
9290
  */
8996
9291
  'uuid': string;
8997
9292
  /**
8998
- * How the tag came about. `custom` covers the tags you create yourself, `form` covers the ones Reach creates for its forms.
9293
+ *
8999
9294
  * @type {string}
9000
- * @memberof ReachV1ContactsTagsTagResource
9295
+ * @memberof ReachV1ContactsSegmentsSegmentResource
9001
9296
  */
9002
- 'type': ReachV1ContactsTagsTagResourceTypeEnum;
9297
+ 'name': string;
9003
9298
  /**
9004
9299
  *
9005
- * @type {string}
9006
- * @memberof ReachV1ContactsTagsTagResource
9300
+ * @type {Array<any>}
9301
+ * @memberof ReachV1ContactsSegmentsSegmentResource
9007
9302
  */
9008
- 'value': string;
9303
+ 'query': Array<any>;
9009
9304
  /**
9010
9305
  *
9011
9306
  * @type {string}
9012
- * @memberof ReachV1ContactsTagsTagResource
9307
+ * @memberof ReachV1ContactsSegmentsSegmentResource
9013
9308
  */
9014
9309
  'created_at': string;
9015
- }
9016
-
9017
- export const ReachV1ContactsTagsTagResourceTypeEnum = {
9018
- Form: 'form',
9019
- Custom: 'custom'
9020
- } as const;
9021
-
9022
- export type ReachV1ContactsTagsTagResourceTypeEnum = typeof ReachV1ContactsTagsTagResourceTypeEnum[keyof typeof ReachV1ContactsTagsTagResourceTypeEnum];
9023
-
9024
- /**
9025
- * Rename a tag
9026
- * @export
9027
- * @interface ReachV1ContactsTagsUpdateRequest
9028
- */
9029
- export interface ReachV1ContactsTagsUpdateRequest {
9030
9310
  /**
9031
- * New tag name
9311
+ *
9032
9312
  * @type {string}
9033
- * @memberof ReachV1ContactsTagsUpdateRequest
9313
+ * @memberof ReachV1ContactsSegmentsSegmentResource
9034
9314
  */
9035
- 'value': string;
9315
+ 'updated_at': string;
9036
9316
  }
9037
9317
  /**
9038
- * Fields to change on a contact. Omitted properties are left untouched.
9318
+ *
9039
9319
  * @export
9040
- * @interface ReachV1ContactsUpdateRequest
9320
+ * @interface ReachV1ContactsSegmentsSegmentationContactResource
9041
9321
  */
9042
- export interface ReachV1ContactsUpdateRequest {
9322
+ export interface ReachV1ContactsSegmentsSegmentationContactResource {
9043
9323
  /**
9044
9324
  *
9045
9325
  * @type {string}
9046
- * @memberof ReachV1ContactsUpdateRequest
9326
+ * @memberof ReachV1ContactsSegmentsSegmentationContactResource
9047
9327
  */
9048
- 'email': string | null;
9328
+ 'uuid': string;
9049
9329
  /**
9050
9330
  *
9051
9331
  * @type {string}
9052
- * @memberof ReachV1ContactsUpdateRequest
9332
+ * @memberof ReachV1ContactsSegmentsSegmentationContactResource
9053
9333
  */
9054
9334
  'name': string | null;
9055
9335
  /**
9056
9336
  *
9057
9337
  * @type {string}
9058
- * @memberof ReachV1ContactsUpdateRequest
9338
+ * @memberof ReachV1ContactsSegmentsSegmentationContactResource
9059
9339
  */
9060
9340
  'surname': string | null;
9061
9341
  /**
9062
- * Phone number in E.164 format (leading \"+\" then 7-15 digits)
9342
+ *
9063
9343
  * @type {string}
9064
- * @memberof ReachV1ContactsUpdateRequest
9344
+ * @memberof ReachV1ContactsSegmentsSegmentationContactResource
9065
9345
  */
9066
- 'phone': string | null;
9346
+ 'email': string;
9067
9347
  /**
9068
9348
  *
9069
9349
  * @type {string}
9070
- * @memberof ReachV1ContactsUpdateRequest
9350
+ * @memberof ReachV1ContactsSegmentsSegmentationContactResource
9071
9351
  */
9072
- 'subscription_status': ReachV1ContactsUpdateRequestSubscriptionStatusEnum | null;
9352
+ 'subscription_status': ReachV1ContactsSegmentsSegmentationContactResourceSubscriptionStatusEnum;
9073
9353
  /**
9074
9354
  *
9075
9355
  * @type {string}
9076
- * @memberof ReachV1ContactsUpdateRequest
9356
+ * @memberof ReachV1ContactsSegmentsSegmentationContactResource
9077
9357
  */
9078
- 'note': string | null;
9358
+ 'subscribed_at': string;
9079
9359
  /**
9080
- * Set custom field values. Omit to leave untouched, send an empty array to clear them all.
9081
- * @type {Array<ReachV1ContactsUpdateRequestFieldsInner>}
9082
- * @memberof ReachV1ContactsUpdateRequest
9360
+ *
9361
+ * @type {string}
9362
+ * @memberof ReachV1ContactsSegmentsSegmentationContactResource
9083
9363
  */
9084
- 'fields': Array<ReachV1ContactsUpdateRequestFieldsInner>;
9364
+ 'source': ReachV1ContactsSegmentsSegmentationContactResourceSourceEnum | null;
9365
+ /**
9366
+ *
9367
+ * @type {string}
9368
+ * @memberof ReachV1ContactsSegmentsSegmentationContactResource
9369
+ */
9370
+ 'note': string | null;
9085
9371
  }
9086
9372
 
9087
- export const ReachV1ContactsUpdateRequestSubscriptionStatusEnum = {
9373
+ export const ReachV1ContactsSegmentsSegmentationContactResourceSubscriptionStatusEnum = {
9088
9374
  Subscribed: 'subscribed',
9089
9375
  Unsubscribed: 'unsubscribed',
9090
9376
  Confirmed: 'confirmed',
9091
9377
  Pending: 'pending'
9092
9378
  } as const;
9093
9379
 
9094
- export type ReachV1ContactsUpdateRequestSubscriptionStatusEnum = typeof ReachV1ContactsUpdateRequestSubscriptionStatusEnum[keyof typeof ReachV1ContactsUpdateRequestSubscriptionStatusEnum];
9380
+ export type ReachV1ContactsSegmentsSegmentationContactResourceSubscriptionStatusEnum = typeof ReachV1ContactsSegmentsSegmentationContactResourceSubscriptionStatusEnum[keyof typeof ReachV1ContactsSegmentsSegmentationContactResourceSubscriptionStatusEnum];
9381
+ export const ReachV1ContactsSegmentsSegmentationContactResourceSourceEnum = {
9382
+ Sync: 'sync',
9383
+ Import: 'import',
9384
+ Manual: 'manual',
9385
+ Api: 'api',
9386
+ Form: 'form',
9387
+ Checkout: 'checkout',
9388
+ Horizons: 'horizons'
9389
+ } as const;
9390
+
9391
+ export type ReachV1ContactsSegmentsSegmentationContactResourceSourceEnum = typeof ReachV1ContactsSegmentsSegmentationContactResourceSourceEnum[keyof typeof ReachV1ContactsSegmentsSegmentationContactResourceSourceEnum];
9095
9392
 
9096
9393
  /**
9097
9394
  *
9098
9395
  * @export
9099
- * @interface ReachV1ContactsUpdateRequestFieldsInner
9396
+ * @interface ReachV1ContactsSegmentsStoreRequest
9100
9397
  */
9101
- export interface ReachV1ContactsUpdateRequestFieldsInner {
9398
+ export interface ReachV1ContactsSegmentsStoreRequest {
9102
9399
  /**
9103
9400
  *
9104
9401
  * @type {string}
9105
- * @memberof ReachV1ContactsUpdateRequestFieldsInner
9402
+ * @memberof ReachV1ContactsSegmentsStoreRequest
9106
9403
  */
9107
- 'uuid': string;
9404
+ 'name': string;
9108
9405
  /**
9109
- * For the scalar field types
9110
- * @type {string}
9111
- * @memberof ReachV1ContactsUpdateRequestFieldsInner
9406
+ *
9407
+ * @type {Array<ReachV1ContactsSegmentsStoreRequestConditionsInner>}
9408
+ * @memberof ReachV1ContactsSegmentsStoreRequest
9112
9409
  */
9113
- 'value': string | null;
9410
+ 'conditions': Array<ReachV1ContactsSegmentsStoreRequestConditionsInner>;
9114
9411
  /**
9115
- * For the choice field types
9116
- * @type {Array<string>}
9117
- * @memberof ReachV1ContactsUpdateRequestFieldsInner
9412
+ *
9413
+ * @type {string}
9414
+ * @memberof ReachV1ContactsSegmentsStoreRequest
9118
9415
  */
9119
- 'selected_option_uuids': Array<string>;
9416
+ 'logic': ReachV1ContactsSegmentsStoreRequestLogicEnum;
9120
9417
  }
9418
+
9419
+ export const ReachV1ContactsSegmentsStoreRequestLogicEnum = {
9420
+ And: 'AND',
9421
+ Or: 'OR'
9422
+ } as const;
9423
+
9424
+ export type ReachV1ContactsSegmentsStoreRequestLogicEnum = typeof ReachV1ContactsSegmentsStoreRequestLogicEnum[keyof typeof ReachV1ContactsSegmentsStoreRequestLogicEnum];
9425
+
9121
9426
  /**
9122
9427
  *
9123
9428
  * @export
9124
- * @interface ReachV1ProfilesDomainsDnsRecordStatus
9429
+ * @interface ReachV1ContactsSegmentsStoreRequestConditionsInner
9125
9430
  */
9126
- export interface ReachV1ProfilesDomainsDnsRecordStatus {
9431
+ export interface ReachV1ContactsSegmentsStoreRequestConditionsInner {
9127
9432
  /**
9128
9433
  *
9129
- * @type {Array<ReachV1ProfilesDomainsDnsRecordStatusActualInner>}
9130
- * @memberof ReachV1ProfilesDomainsDnsRecordStatus
9434
+ * @type {string}
9435
+ * @memberof ReachV1ContactsSegmentsStoreRequestConditionsInner
9131
9436
  */
9132
- 'actual': Array<ReachV1ProfilesDomainsDnsRecordStatusActualInner>;
9437
+ 'operator': ReachV1ContactsSegmentsStoreRequestConditionsInnerOperatorEnum;
9133
9438
  /**
9134
9439
  *
9135
- * @type {Array<ReachV1ProfilesDomainsDnsRecordStatusSuggestedInner>}
9136
- * @memberof ReachV1ProfilesDomainsDnsRecordStatus
9440
+ * @type {ReachV1ContactsSegmentsStoreRequestConditionsInnerValue}
9441
+ * @memberof ReachV1ContactsSegmentsStoreRequestConditionsInner
9137
9442
  */
9138
- 'suggested': Array<ReachV1ProfilesDomainsDnsRecordStatusSuggestedInner>;
9443
+ 'value': ReachV1ContactsSegmentsStoreRequestConditionsInnerValue;
9139
9444
  /**
9140
9445
  *
9141
- * @type {boolean}
9142
- * @memberof ReachV1ProfilesDomainsDnsRecordStatus
9446
+ * @type {string}
9447
+ * @memberof ReachV1ContactsSegmentsStoreRequestConditionsInner
9143
9448
  */
9144
- 'is_valid': boolean;
9449
+ 'attribute': ReachV1ContactsSegmentsStoreRequestConditionsInnerAttributeEnum;
9145
9450
  }
9146
- /**
9147
- *
9148
- * @export
9149
- * @interface ReachV1ProfilesDomainsDnsRecordStatusActualInner
9150
- */
9151
- export interface ReachV1ProfilesDomainsDnsRecordStatusActualInner {
9451
+
9452
+ export const ReachV1ContactsSegmentsStoreRequestConditionsInnerOperatorEnum = {
9453
+ Equals: 'equals',
9454
+ NotEquals: 'not_equals',
9455
+ Contains: 'contains',
9456
+ NotContains: 'not_contains',
9457
+ Gte: 'gte',
9458
+ Lte: 'lte',
9459
+ Exists: 'exists',
9460
+ WithinLastDays: 'within_last_days',
9461
+ NotWithinLastDays: 'not_within_last_days',
9462
+ OlderThanDays: 'older_than_days',
9463
+ Processed: 'processed',
9464
+ NotProcessed: 'not_processed',
9465
+ Delivered: 'delivered',
9466
+ NotDelivered: 'not_delivered',
9467
+ Dropped: 'dropped',
9468
+ NotDropped: 'not_dropped',
9469
+ Bounced: 'bounced',
9470
+ NotBounced: 'not_bounced',
9471
+ SoftBounced: 'soft_bounced',
9472
+ NotSoftBounced: 'not_soft_bounced',
9473
+ Opened: 'opened',
9474
+ NotOpened: 'not_opened',
9475
+ Clicked: 'clicked',
9476
+ NotClicked: 'not_clicked',
9477
+ Unsubscribed: 'unsubscribed',
9478
+ NotUnsubscribed: 'not_unsubscribed'
9479
+ } as const;
9480
+
9481
+ export type ReachV1ContactsSegmentsStoreRequestConditionsInnerOperatorEnum = typeof ReachV1ContactsSegmentsStoreRequestConditionsInnerOperatorEnum[keyof typeof ReachV1ContactsSegmentsStoreRequestConditionsInnerOperatorEnum];
9482
+ export const ReachV1ContactsSegmentsStoreRequestConditionsInnerAttributeEnum = {
9483
+ Note: 'note',
9484
+ Comment: 'comment',
9485
+ Domain: 'domain',
9486
+ Integration: 'integration',
9487
+ Source: 'source',
9488
+ Name: 'name',
9489
+ Surname: 'surname',
9490
+ Email: 'email',
9491
+ SubscribedAt: 'subscribed_at',
9492
+ UnsubscribedAt: 'unsubscribed_at',
9493
+ SubscriptionStatus: 'subscription_status',
9494
+ Processed: 'processed',
9495
+ Opened: 'opened',
9496
+ Clicked: 'clicked',
9497
+ Delivered: 'delivered',
9498
+ Bounced: 'bounced',
9499
+ Unsubscribed: 'unsubscribed',
9500
+ Dropped: 'dropped',
9501
+ Tag: 'tag',
9502
+ Campaigns: 'campaigns'
9503
+ } as const;
9504
+
9505
+ export type ReachV1ContactsSegmentsStoreRequestConditionsInnerAttributeEnum = typeof ReachV1ContactsSegmentsStoreRequestConditionsInnerAttributeEnum[keyof typeof ReachV1ContactsSegmentsStoreRequestConditionsInnerAttributeEnum];
9506
+
9507
+ /**
9508
+ * @type ReachV1ContactsSegmentsStoreRequestConditionsInnerValue
9509
+ * @export
9510
+ */
9511
+ export type ReachV1ContactsSegmentsStoreRequestConditionsInnerValue = number | string;
9512
+
9513
+ /**
9514
+ *
9515
+ * @export
9516
+ * @interface ReachV1ContactsStoreRequest
9517
+ */
9518
+ export interface ReachV1ContactsStoreRequest {
9152
9519
  /**
9153
9520
  *
9154
9521
  * @type {string}
9155
- * @memberof ReachV1ProfilesDomainsDnsRecordStatusActualInner
9522
+ * @memberof ReachV1ContactsStoreRequest
9156
9523
  */
9157
- 'type': string;
9524
+ 'email': string;
9158
9525
  /**
9159
9526
  *
9160
9527
  * @type {string}
9161
- * @memberof ReachV1ProfilesDomainsDnsRecordStatusActualInner
9528
+ * @memberof ReachV1ContactsStoreRequest
9162
9529
  */
9163
- 'value': string;
9164
- }
9165
- /**
9166
- *
9167
- * @export
9168
- * @interface ReachV1ProfilesDomainsDnsRecordStatusSuggestedInner
9169
- */
9170
- export interface ReachV1ProfilesDomainsDnsRecordStatusSuggestedInner {
9530
+ 'name': string | null;
9171
9531
  /**
9172
9532
  *
9173
9533
  * @type {string}
9174
- * @memberof ReachV1ProfilesDomainsDnsRecordStatusSuggestedInner
9534
+ * @memberof ReachV1ContactsStoreRequest
9175
9535
  */
9176
- 'name': string;
9536
+ 'surname': string | null;
9177
9537
  /**
9178
- *
9538
+ * Phone number in E.164 format (leading \"+\" then 7-15 digits)
9179
9539
  * @type {string}
9180
- * @memberof ReachV1ProfilesDomainsDnsRecordStatusSuggestedInner
9540
+ * @memberof ReachV1ContactsStoreRequest
9181
9541
  */
9182
- 'type': string;
9542
+ 'phone': string | null;
9183
9543
  /**
9184
9544
  *
9185
9545
  * @type {string}
9186
- * @memberof ReachV1ProfilesDomainsDnsRecordStatusSuggestedInner
9546
+ * @memberof ReachV1ContactsStoreRequest
9187
9547
  */
9188
- 'value': string;
9548
+ 'note': string | null;
9189
9549
  }
9190
9550
  /**
9191
- *
9551
+ * Contacts to assign to, or remove from, a tag
9192
9552
  * @export
9193
- * @interface ReachV1ProfilesDomainsDnsStatusResource
9553
+ * @interface ReachV1ContactsTagsManageContactsRequest
9194
9554
  */
9195
- export interface ReachV1ProfilesDomainsDnsStatusResource {
9196
- /**
9197
- *
9198
- * @type {string}
9199
- * @memberof ReachV1ProfilesDomainsDnsStatusResource
9200
- */
9201
- 'domain': string;
9202
- /**
9203
- *
9204
- * @type {ReachV1ProfilesDomainsDnsRecordStatus}
9205
- * @memberof ReachV1ProfilesDomainsDnsStatusResource
9206
- */
9207
- 'mx': ReachV1ProfilesDomainsDnsRecordStatus;
9555
+ export interface ReachV1ContactsTagsManageContactsRequest {
9208
9556
  /**
9209
- *
9210
- * @type {ReachV1ProfilesDomainsDnsRecordStatus}
9211
- * @memberof ReachV1ProfilesDomainsDnsStatusResource
9557
+ * Contacts to apply the change to. Required unless all_contacts is true.
9558
+ * @type {Array<string>}
9559
+ * @memberof ReachV1ContactsTagsManageContactsRequest
9212
9560
  */
9213
- 'spf': ReachV1ProfilesDomainsDnsRecordStatus;
9561
+ 'contact_uuids': Array<string>;
9214
9562
  /**
9215
- *
9216
- * @type {ReachV1ProfilesDomainsDnsRecordStatus}
9217
- * @memberof ReachV1ProfilesDomainsDnsStatusResource
9563
+ * Apply to every contact in the profile
9564
+ * @type {boolean}
9565
+ * @memberof ReachV1ContactsTagsManageContactsRequest
9218
9566
  */
9219
- 'dkim': ReachV1ProfilesDomainsDnsRecordStatus;
9567
+ 'all_contacts': boolean;
9568
+ }
9569
+ /**
9570
+ * Names to create. Names that already exist in the profile are returned as they are.
9571
+ * @export
9572
+ * @interface ReachV1ContactsTagsStoreRequest
9573
+ */
9574
+ export interface ReachV1ContactsTagsStoreRequest {
9220
9575
  /**
9221
9576
  *
9222
- * @type {ReachV1ProfilesDomainsDnsRecordStatus}
9223
- * @memberof ReachV1ProfilesDomainsDnsStatusResource
9577
+ * @type {Array<string>}
9578
+ * @memberof ReachV1ContactsTagsStoreRequest
9224
9579
  */
9225
- 'dmarc': ReachV1ProfilesDomainsDnsRecordStatus;
9580
+ 'names': Array<string>;
9226
9581
  }
9227
9582
  /**
9228
9583
  *
9229
9584
  * @export
9230
- * @interface ReachV1ProfilesProfileResource
9585
+ * @interface ReachV1ContactsTagsTagResource
9231
9586
  */
9232
- export interface ReachV1ProfilesProfileResource {
9233
- /**
9234
- *
9235
- * @type {ReachV1ProfilesProfileResourceLimits}
9236
- * @memberof ReachV1ProfilesProfileResource
9237
- */
9238
- 'limits': ReachV1ProfilesProfileResourceLimits;
9239
- /**
9240
- *
9241
- * @type {boolean}
9242
- * @memberof ReachV1ProfilesProfileResource
9243
- */
9244
- 'is_trial': boolean;
9587
+ export interface ReachV1ContactsTagsTagResource {
9245
9588
  /**
9246
9589
  *
9247
9590
  * @type {string}
9248
- * @memberof ReachV1ProfilesProfileResource
9591
+ * @memberof ReachV1ContactsTagsTagResource
9249
9592
  */
9250
- 'expires_at': string;
9593
+ 'uuid': string;
9251
9594
  /**
9252
- *
9253
- * @type {number}
9254
- * @memberof ReachV1ProfilesProfileResource
9595
+ * How the tag came about. `custom` covers the tags you create yourself, `form` covers the ones Reach creates for its forms.
9596
+ * @type {string}
9597
+ * @memberof ReachV1ContactsTagsTagResource
9255
9598
  */
9256
- 'resource_id': number;
9599
+ 'type': ReachV1ContactsTagsTagResourceTypeEnum;
9257
9600
  /**
9258
9601
  *
9259
9602
  * @type {string}
9260
- * @memberof ReachV1ProfilesProfileResource
9603
+ * @memberof ReachV1ContactsTagsTagResource
9261
9604
  */
9262
- 'status': string;
9605
+ 'value': string;
9263
9606
  /**
9264
9607
  *
9265
- * @type {Array<ReachV1ProfilesProfileResourceProfilesInner>}
9266
- * @memberof ReachV1ProfilesProfileResource
9608
+ * @type {string}
9609
+ * @memberof ReachV1ContactsTagsTagResource
9267
9610
  */
9268
- 'profiles': Array<ReachV1ProfilesProfileResourceProfilesInner>;
9611
+ 'created_at': string;
9269
9612
  }
9613
+
9614
+ export const ReachV1ContactsTagsTagResourceTypeEnum = {
9615
+ Form: 'form',
9616
+ Custom: 'custom'
9617
+ } as const;
9618
+
9619
+ export type ReachV1ContactsTagsTagResourceTypeEnum = typeof ReachV1ContactsTagsTagResourceTypeEnum[keyof typeof ReachV1ContactsTagsTagResourceTypeEnum];
9620
+
9270
9621
  /**
9271
- *
9622
+ * Rename a tag
9272
9623
  * @export
9273
- * @interface ReachV1ProfilesProfileResourceLimits
9624
+ * @interface ReachV1ContactsTagsUpdateRequest
9274
9625
  */
9275
- export interface ReachV1ProfilesProfileResourceLimits {
9276
- /**
9277
- *
9278
- * @type {number}
9279
- * @memberof ReachV1ProfilesProfileResourceLimits
9280
- */
9281
- 'ai_messages_limit': number;
9626
+ export interface ReachV1ContactsTagsUpdateRequest {
9282
9627
  /**
9283
- *
9284
- * @type {number}
9285
- * @memberof ReachV1ProfilesProfileResourceLimits
9628
+ * New tag name
9629
+ * @type {string}
9630
+ * @memberof ReachV1ContactsTagsUpdateRequest
9286
9631
  */
9287
- 'subscribers_limit': number;
9632
+ 'value': string;
9633
+ }
9634
+ /**
9635
+ * Fields to change on a contact. Omitted properties are left untouched.
9636
+ * @export
9637
+ * @interface ReachV1ContactsUpdateRequest
9638
+ */
9639
+ export interface ReachV1ContactsUpdateRequest {
9288
9640
  /**
9289
9641
  *
9290
- * @type {number}
9291
- * @memberof ReachV1ProfilesProfileResourceLimits
9642
+ * @type {string}
9643
+ * @memberof ReachV1ContactsUpdateRequest
9292
9644
  */
9293
- 'emails_monthly_limit': number;
9645
+ 'email': string | null;
9294
9646
  /**
9295
9647
  *
9296
- * @type {number}
9297
- * @memberof ReachV1ProfilesProfileResourceLimits
9648
+ * @type {string}
9649
+ * @memberof ReachV1ContactsUpdateRequest
9298
9650
  */
9299
- 'ai_messages_additional': number;
9300
- }
9301
- /**
9302
- *
9303
- * @export
9304
- * @interface ReachV1ProfilesProfileResourceProfilesInner
9305
- */
9306
- export interface ReachV1ProfilesProfileResourceProfilesInner {
9651
+ 'name': string | null;
9307
9652
  /**
9308
9653
  *
9309
9654
  * @type {string}
9310
- * @memberof ReachV1ProfilesProfileResourceProfilesInner
9655
+ * @memberof ReachV1ContactsUpdateRequest
9311
9656
  */
9312
- 'uuid': string;
9657
+ 'surname': string | null;
9313
9658
  /**
9314
- *
9659
+ * Phone number in E.164 format (leading \"+\" then 7-15 digits)
9315
9660
  * @type {string}
9316
- * @memberof ReachV1ProfilesProfileResourceProfilesInner
9661
+ * @memberof ReachV1ContactsUpdateRequest
9317
9662
  */
9318
- 'domain': string;
9663
+ 'phone': string | null;
9319
9664
  /**
9320
9665
  *
9321
9666
  * @type {string}
9322
- * @memberof ReachV1ProfilesProfileResourceProfilesInner
9667
+ * @memberof ReachV1ContactsUpdateRequest
9323
9668
  */
9324
- 'created_at': string;
9669
+ 'subscription_status': ReachV1ContactsUpdateRequestSubscriptionStatusEnum | null;
9325
9670
  /**
9326
9671
  *
9327
9672
  * @type {string}
9328
- * @memberof ReachV1ProfilesProfileResourceProfilesInner
9673
+ * @memberof ReachV1ContactsUpdateRequest
9329
9674
  */
9330
- 'updated_at': string;
9331
- }
9332
- /**
9675
+ 'note': string | null;
9676
+ /**
9677
+ * Set custom field values. Omit to leave untouched, send an empty array to clear them all.
9678
+ * @type {Array<ReachV1ContactsUpdateRequestFieldsInner>}
9679
+ * @memberof ReachV1ContactsUpdateRequest
9680
+ */
9681
+ 'fields': Array<ReachV1ContactsUpdateRequestFieldsInner>;
9682
+ }
9683
+
9684
+ export const ReachV1ContactsUpdateRequestSubscriptionStatusEnum = {
9685
+ Subscribed: 'subscribed',
9686
+ Unsubscribed: 'unsubscribed',
9687
+ Confirmed: 'confirmed',
9688
+ Pending: 'pending'
9689
+ } as const;
9690
+
9691
+ export type ReachV1ContactsUpdateRequestSubscriptionStatusEnum = typeof ReachV1ContactsUpdateRequestSubscriptionStatusEnum[keyof typeof ReachV1ContactsUpdateRequestSubscriptionStatusEnum];
9692
+
9693
+ /**
9694
+ *
9695
+ * @export
9696
+ * @interface ReachV1ContactsUpdateRequestFieldsInner
9697
+ */
9698
+ export interface ReachV1ContactsUpdateRequestFieldsInner {
9699
+ /**
9700
+ *
9701
+ * @type {string}
9702
+ * @memberof ReachV1ContactsUpdateRequestFieldsInner
9703
+ */
9704
+ 'uuid': string;
9705
+ /**
9706
+ * For the scalar field types
9707
+ * @type {string}
9708
+ * @memberof ReachV1ContactsUpdateRequestFieldsInner
9709
+ */
9710
+ 'value': string | null;
9711
+ /**
9712
+ * For the choice field types
9713
+ * @type {Array<string>}
9714
+ * @memberof ReachV1ContactsUpdateRequestFieldsInner
9715
+ */
9716
+ 'selected_option_uuids': Array<string>;
9717
+ }
9718
+ /**
9719
+ *
9720
+ * @export
9721
+ * @interface ReachV1ProfilesDomainsDnsRecordStatus
9722
+ */
9723
+ export interface ReachV1ProfilesDomainsDnsRecordStatus {
9724
+ /**
9725
+ *
9726
+ * @type {Array<ReachV1ProfilesDomainsDnsRecordStatusActualInner>}
9727
+ * @memberof ReachV1ProfilesDomainsDnsRecordStatus
9728
+ */
9729
+ 'actual': Array<ReachV1ProfilesDomainsDnsRecordStatusActualInner>;
9730
+ /**
9731
+ *
9732
+ * @type {Array<ReachV1ProfilesDomainsDnsRecordStatusSuggestedInner>}
9733
+ * @memberof ReachV1ProfilesDomainsDnsRecordStatus
9734
+ */
9735
+ 'suggested': Array<ReachV1ProfilesDomainsDnsRecordStatusSuggestedInner>;
9736
+ /**
9737
+ *
9738
+ * @type {boolean}
9739
+ * @memberof ReachV1ProfilesDomainsDnsRecordStatus
9740
+ */
9741
+ 'is_valid': boolean;
9742
+ }
9743
+ /**
9744
+ *
9745
+ * @export
9746
+ * @interface ReachV1ProfilesDomainsDnsRecordStatusActualInner
9747
+ */
9748
+ export interface ReachV1ProfilesDomainsDnsRecordStatusActualInner {
9749
+ /**
9750
+ *
9751
+ * @type {string}
9752
+ * @memberof ReachV1ProfilesDomainsDnsRecordStatusActualInner
9753
+ */
9754
+ 'type': string;
9755
+ /**
9756
+ *
9757
+ * @type {string}
9758
+ * @memberof ReachV1ProfilesDomainsDnsRecordStatusActualInner
9759
+ */
9760
+ 'value': string;
9761
+ }
9762
+ /**
9763
+ *
9764
+ * @export
9765
+ * @interface ReachV1ProfilesDomainsDnsRecordStatusSuggestedInner
9766
+ */
9767
+ export interface ReachV1ProfilesDomainsDnsRecordStatusSuggestedInner {
9768
+ /**
9769
+ *
9770
+ * @type {string}
9771
+ * @memberof ReachV1ProfilesDomainsDnsRecordStatusSuggestedInner
9772
+ */
9773
+ 'name': string;
9774
+ /**
9775
+ *
9776
+ * @type {string}
9777
+ * @memberof ReachV1ProfilesDomainsDnsRecordStatusSuggestedInner
9778
+ */
9779
+ 'type': string;
9780
+ /**
9781
+ *
9782
+ * @type {string}
9783
+ * @memberof ReachV1ProfilesDomainsDnsRecordStatusSuggestedInner
9784
+ */
9785
+ 'value': string;
9786
+ }
9787
+ /**
9788
+ *
9789
+ * @export
9790
+ * @interface ReachV1ProfilesDomainsDnsStatusResource
9791
+ */
9792
+ export interface ReachV1ProfilesDomainsDnsStatusResource {
9793
+ /**
9794
+ *
9795
+ * @type {string}
9796
+ * @memberof ReachV1ProfilesDomainsDnsStatusResource
9797
+ */
9798
+ 'domain': string;
9799
+ /**
9800
+ *
9801
+ * @type {ReachV1ProfilesDomainsDnsRecordStatus}
9802
+ * @memberof ReachV1ProfilesDomainsDnsStatusResource
9803
+ */
9804
+ 'mx': ReachV1ProfilesDomainsDnsRecordStatus;
9805
+ /**
9806
+ *
9807
+ * @type {ReachV1ProfilesDomainsDnsRecordStatus}
9808
+ * @memberof ReachV1ProfilesDomainsDnsStatusResource
9809
+ */
9810
+ 'spf': ReachV1ProfilesDomainsDnsRecordStatus;
9811
+ /**
9812
+ *
9813
+ * @type {ReachV1ProfilesDomainsDnsRecordStatus}
9814
+ * @memberof ReachV1ProfilesDomainsDnsStatusResource
9815
+ */
9816
+ 'dkim': ReachV1ProfilesDomainsDnsRecordStatus;
9817
+ /**
9818
+ *
9819
+ * @type {ReachV1ProfilesDomainsDnsRecordStatus}
9820
+ * @memberof ReachV1ProfilesDomainsDnsStatusResource
9821
+ */
9822
+ 'dmarc': ReachV1ProfilesDomainsDnsRecordStatus;
9823
+ }
9824
+ /**
9825
+ *
9826
+ * @export
9827
+ * @interface ReachV1ProfilesProfileResource
9828
+ */
9829
+ export interface ReachV1ProfilesProfileResource {
9830
+ /**
9831
+ *
9832
+ * @type {ReachV1ProfilesProfileResourceLimits}
9833
+ * @memberof ReachV1ProfilesProfileResource
9834
+ */
9835
+ 'limits': ReachV1ProfilesProfileResourceLimits;
9836
+ /**
9837
+ *
9838
+ * @type {boolean}
9839
+ * @memberof ReachV1ProfilesProfileResource
9840
+ */
9841
+ 'is_trial': boolean;
9842
+ /**
9843
+ *
9844
+ * @type {string}
9845
+ * @memberof ReachV1ProfilesProfileResource
9846
+ */
9847
+ 'expires_at': string;
9848
+ /**
9849
+ *
9850
+ * @type {number}
9851
+ * @memberof ReachV1ProfilesProfileResource
9852
+ */
9853
+ 'resource_id': number;
9854
+ /**
9855
+ *
9856
+ * @type {string}
9857
+ * @memberof ReachV1ProfilesProfileResource
9858
+ */
9859
+ 'status': string;
9860
+ /**
9861
+ *
9862
+ * @type {Array<ReachV1ProfilesProfileResourceProfilesInner>}
9863
+ * @memberof ReachV1ProfilesProfileResource
9864
+ */
9865
+ 'profiles': Array<ReachV1ProfilesProfileResourceProfilesInner>;
9866
+ }
9867
+ /**
9868
+ *
9869
+ * @export
9870
+ * @interface ReachV1ProfilesProfileResourceLimits
9871
+ */
9872
+ export interface ReachV1ProfilesProfileResourceLimits {
9873
+ /**
9874
+ *
9875
+ * @type {number}
9876
+ * @memberof ReachV1ProfilesProfileResourceLimits
9877
+ */
9878
+ 'ai_messages_limit': number;
9879
+ /**
9880
+ *
9881
+ * @type {number}
9882
+ * @memberof ReachV1ProfilesProfileResourceLimits
9883
+ */
9884
+ 'subscribers_limit': number;
9885
+ /**
9886
+ *
9887
+ * @type {number}
9888
+ * @memberof ReachV1ProfilesProfileResourceLimits
9889
+ */
9890
+ 'emails_monthly_limit': number;
9891
+ /**
9892
+ *
9893
+ * @type {number}
9894
+ * @memberof ReachV1ProfilesProfileResourceLimits
9895
+ */
9896
+ 'ai_messages_additional': number;
9897
+ }
9898
+ /**
9899
+ *
9900
+ * @export
9901
+ * @interface ReachV1ProfilesProfileResourceProfilesInner
9902
+ */
9903
+ export interface ReachV1ProfilesProfileResourceProfilesInner {
9904
+ /**
9905
+ *
9906
+ * @type {string}
9907
+ * @memberof ReachV1ProfilesProfileResourceProfilesInner
9908
+ */
9909
+ 'uuid': string;
9910
+ /**
9911
+ *
9912
+ * @type {string}
9913
+ * @memberof ReachV1ProfilesProfileResourceProfilesInner
9914
+ */
9915
+ 'domain': string;
9916
+ /**
9917
+ *
9918
+ * @type {string}
9919
+ * @memberof ReachV1ProfilesProfileResourceProfilesInner
9920
+ */
9921
+ 'created_at': string;
9922
+ /**
9923
+ *
9924
+ * @type {string}
9925
+ * @memberof ReachV1ProfilesProfileResourceProfilesInner
9926
+ */
9927
+ 'updated_at': string;
9928
+ }
9929
+ /**
9333
9930
  *
9334
9931
  * @export
9335
9932
  * @interface VPSV1ActionActionResource
@@ -28031,28 +28628,499 @@ export const MailWebhooksApiAxiosParamCreator = function (configuration?: Config
28031
28628
  }
28032
28629
 
28033
28630
 
28034
-
28035
- setSearchParams(localVarUrlObj, localVarQueryParameter);
28036
- let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
28037
- localVarRequestOptions.headers = {...localVarHeaderParameter, ...headersFromBaseOptions, ...options.headers};
28631
+
28632
+ setSearchParams(localVarUrlObj, localVarQueryParameter);
28633
+ let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
28634
+ localVarRequestOptions.headers = {...localVarHeaderParameter, ...headersFromBaseOptions, ...options.headers};
28635
+
28636
+ return {
28637
+ url: toPathString(localVarUrlObj),
28638
+ options: localVarRequestOptions,
28639
+ };
28640
+ },
28641
+ /**
28642
+ * Regenerate the secret of a webhook. The previous secret is immediately invalidated. The new secret is returned only in this response and is sent as a bearer token with every delivery.
28643
+ * @summary Regenerate webhook secret
28644
+ * @param {string} webhookId Webhook ID (returned when the webhook was created)
28645
+ * @param {*} [options] Override http request option.
28646
+ * @throws {RequiredError}
28647
+ */
28648
+ regenerateWebhookSecretV1: async (webhookId: string, options: RawAxiosRequestConfig = {}): Promise<RequestArgs> => {
28649
+ // verify required parameter 'webhookId' is not null or undefined
28650
+ assertParamExists('regenerateWebhookSecretV1', 'webhookId', webhookId)
28651
+ const localVarPath = `/api/mail/v1/webhooks/{webhookId}/regenerate-secret`
28652
+ .replace(`{${"webhookId"}}`, encodeURIComponent(String(webhookId)));
28653
+ // use dummy base URL string because the URL constructor only accepts absolute URLs.
28654
+ const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL);
28655
+ let baseOptions;
28656
+ if (configuration) {
28657
+ baseOptions = configuration.baseOptions;
28658
+ }
28659
+
28660
+ const localVarRequestOptions = { method: 'POST', ...baseOptions, ...options};
28661
+ const localVarHeaderParameter = {} as any;
28662
+ const localVarQueryParameter = {} as any;
28663
+
28664
+ // authentication apiToken required
28665
+ // http bearer authentication required
28666
+ await setBearerAuthToObject(localVarHeaderParameter, configuration)
28667
+
28668
+
28669
+
28670
+ setSearchParams(localVarUrlObj, localVarQueryParameter);
28671
+ let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
28672
+ localVarRequestOptions.headers = {...localVarHeaderParameter, ...headersFromBaseOptions, ...options.headers};
28673
+
28674
+ return {
28675
+ url: toPathString(localVarUrlObj),
28676
+ options: localVarRequestOptions,
28677
+ };
28678
+ },
28679
+ /**
28680
+ * Send a test delivery to the webhook URL and return the result. Test requests are rate limited upstream.
28681
+ * @summary Test webhook
28682
+ * @param {string} webhookId Webhook ID (returned when the webhook was created)
28683
+ * @param {*} [options] Override http request option.
28684
+ * @throws {RequiredError}
28685
+ */
28686
+ testWebhookV1: async (webhookId: string, options: RawAxiosRequestConfig = {}): Promise<RequestArgs> => {
28687
+ // verify required parameter 'webhookId' is not null or undefined
28688
+ assertParamExists('testWebhookV1', 'webhookId', webhookId)
28689
+ const localVarPath = `/api/mail/v1/webhooks/{webhookId}/test`
28690
+ .replace(`{${"webhookId"}}`, encodeURIComponent(String(webhookId)));
28691
+ // use dummy base URL string because the URL constructor only accepts absolute URLs.
28692
+ const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL);
28693
+ let baseOptions;
28694
+ if (configuration) {
28695
+ baseOptions = configuration.baseOptions;
28696
+ }
28697
+
28698
+ const localVarRequestOptions = { method: 'POST', ...baseOptions, ...options};
28699
+ const localVarHeaderParameter = {} as any;
28700
+ const localVarQueryParameter = {} as any;
28701
+
28702
+ // authentication apiToken required
28703
+ // http bearer authentication required
28704
+ await setBearerAuthToObject(localVarHeaderParameter, configuration)
28705
+
28706
+
28707
+
28708
+ setSearchParams(localVarUrlObj, localVarQueryParameter);
28709
+ let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
28710
+ localVarRequestOptions.headers = {...localVarHeaderParameter, ...headersFromBaseOptions, ...options.headers};
28711
+
28712
+ return {
28713
+ url: toPathString(localVarUrlObj),
28714
+ options: localVarRequestOptions,
28715
+ };
28716
+ },
28717
+ /**
28718
+ * Partially update a webhook. Only the fields included in the request body are changed; omitted fields retain their current values. Pass `\"description\": null` to clear the description.
28719
+ * @summary Update webhook
28720
+ * @param {string} webhookId Webhook ID (returned when the webhook was created)
28721
+ * @param {MailV1SchemaUpdateWebhookRequestSchema} mailV1SchemaUpdateWebhookRequestSchema
28722
+ * @param {*} [options] Override http request option.
28723
+ * @throws {RequiredError}
28724
+ */
28725
+ updateWebhookV1: async (webhookId: string, mailV1SchemaUpdateWebhookRequestSchema: MailV1SchemaUpdateWebhookRequestSchema, options: RawAxiosRequestConfig = {}): Promise<RequestArgs> => {
28726
+ // verify required parameter 'webhookId' is not null or undefined
28727
+ assertParamExists('updateWebhookV1', 'webhookId', webhookId)
28728
+ // verify required parameter 'mailV1SchemaUpdateWebhookRequestSchema' is not null or undefined
28729
+ assertParamExists('updateWebhookV1', 'mailV1SchemaUpdateWebhookRequestSchema', mailV1SchemaUpdateWebhookRequestSchema)
28730
+ const localVarPath = `/api/mail/v1/webhooks/{webhookId}`
28731
+ .replace(`{${"webhookId"}}`, encodeURIComponent(String(webhookId)));
28732
+ // use dummy base URL string because the URL constructor only accepts absolute URLs.
28733
+ const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL);
28734
+ let baseOptions;
28735
+ if (configuration) {
28736
+ baseOptions = configuration.baseOptions;
28737
+ }
28738
+
28739
+ const localVarRequestOptions = { method: 'PATCH', ...baseOptions, ...options};
28740
+ const localVarHeaderParameter = {} as any;
28741
+ const localVarQueryParameter = {} as any;
28742
+
28743
+ // authentication apiToken required
28744
+ // http bearer authentication required
28745
+ await setBearerAuthToObject(localVarHeaderParameter, configuration)
28746
+
28747
+
28748
+
28749
+ localVarHeaderParameter['Content-Type'] = 'application/json';
28750
+
28751
+ setSearchParams(localVarUrlObj, localVarQueryParameter);
28752
+ let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
28753
+ localVarRequestOptions.headers = {...localVarHeaderParameter, ...headersFromBaseOptions, ...options.headers};
28754
+ localVarRequestOptions.data = serializeDataIfNeeded(mailV1SchemaUpdateWebhookRequestSchema, localVarRequestOptions, configuration)
28755
+
28756
+ return {
28757
+ url: toPathString(localVarUrlObj),
28758
+ options: localVarRequestOptions,
28759
+ };
28760
+ },
28761
+ }
28762
+ };
28763
+
28764
+ /**
28765
+ * MailWebhooksApi - functional programming interface
28766
+ * @export
28767
+ */
28768
+ export const MailWebhooksApiFp = function(configuration?: Configuration) {
28769
+ const localVarAxiosParamCreator = MailWebhooksApiAxiosParamCreator(configuration)
28770
+ return {
28771
+ /**
28772
+ * Create a webhook for the given mailbox. The generated secret is returned only in this response and is sent as a bearer token with every delivery.
28773
+ * @summary Create webhook
28774
+ * @param {string} mailboxId Mailbox resource ID
28775
+ * @param {MailV1SchemaCreateWebhookRequestSchema} mailV1SchemaCreateWebhookRequestSchema
28776
+ * @param {*} [options] Override http request option.
28777
+ * @throws {RequiredError}
28778
+ */
28779
+ async createWebhookV1(mailboxId: string, mailV1SchemaCreateWebhookRequestSchema: MailV1SchemaCreateWebhookRequestSchema, options?: RawAxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<MailV1WebhooksWebhookCreatedResource>> {
28780
+ const localVarAxiosArgs = await localVarAxiosParamCreator.createWebhookV1(mailboxId, mailV1SchemaCreateWebhookRequestSchema, options);
28781
+ const localVarOperationServerBasePath = operationServerMap['MailWebhooksApi.createWebhookV1']?.[0]?.url;
28782
+ return (axios, basePath) => createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration)(axios, localVarOperationServerBasePath || basePath);
28783
+ },
28784
+ /**
28785
+ * Permanently delete a webhook. This action cannot be undone. After deletion the URL no longer receives event notifications.
28786
+ * @summary Delete webhook
28787
+ * @param {string} webhookId Webhook ID (returned when the webhook was created)
28788
+ * @param {*} [options] Override http request option.
28789
+ * @throws {RequiredError}
28790
+ */
28791
+ async deleteWebhookV1(webhookId: string, options?: RawAxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<CommonSuccessEmptyResource>> {
28792
+ const localVarAxiosArgs = await localVarAxiosParamCreator.deleteWebhookV1(webhookId, options);
28793
+ const localVarOperationServerBasePath = operationServerMap['MailWebhooksApi.deleteWebhookV1']?.[0]?.url;
28794
+ return (axios, basePath) => createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration)(axios, localVarOperationServerBasePath || basePath);
28795
+ },
28796
+ /**
28797
+ * Retrieve the details of a single webhook. The webhook secret is never included; it is returned only when a webhook is created or its secret is regenerated.
28798
+ * @summary Get webhook
28799
+ * @param {string} webhookId Webhook ID (returned when the webhook was created)
28800
+ * @param {*} [options] Override http request option.
28801
+ * @throws {RequiredError}
28802
+ */
28803
+ async getWebhookV1(webhookId: string, options?: RawAxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<MailV1WebhooksWebhookResource>> {
28804
+ const localVarAxiosArgs = await localVarAxiosParamCreator.getWebhookV1(webhookId, options);
28805
+ const localVarOperationServerBasePath = operationServerMap['MailWebhooksApi.getWebhookV1']?.[0]?.url;
28806
+ return (axios, basePath) => createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration)(axios, localVarOperationServerBasePath || basePath);
28807
+ },
28808
+ /**
28809
+ * Retrieve a paginated list of webhook delivery logs for the given mail order, including delivery outcome, duration, and retry counts. Supports filtering by mailbox.
28810
+ * @summary List webhook delivery logs
28811
+ * @param {string} orderId Order resource ID
28812
+ * @param {string | null} [mailboxId] Filter by the mailbox resource ID the webhooks are attached to
28813
+ * @param {number} [page] Page number
28814
+ * @param {number} [perPage] Number of items per page
28815
+ * @param {*} [options] Override http request option.
28816
+ * @throws {RequiredError}
28817
+ */
28818
+ async listWebhookDeliveryLogsV1(orderId: string, mailboxId?: string | null, page?: number, perPage?: number, options?: RawAxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<MailListWebhookDeliveryLogsV1200Response>> {
28819
+ const localVarAxiosArgs = await localVarAxiosParamCreator.listWebhookDeliveryLogsV1(orderId, mailboxId, page, perPage, options);
28820
+ const localVarOperationServerBasePath = operationServerMap['MailWebhooksApi.listWebhookDeliveryLogsV1']?.[0]?.url;
28821
+ return (axios, basePath) => createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration)(axios, localVarOperationServerBasePath || basePath);
28822
+ },
28823
+ /**
28824
+ * Retrieve a paginated list of webhooks belonging to the given mail order. Supports filtering by mailbox and status. The webhook secret is never included; it is returned only when a webhook is created or its secret is regenerated.
28825
+ * @summary List webhooks
28826
+ * @param {string} orderId Order resource ID
28827
+ * @param {string | null} [mailboxId] Filter by the mailbox resource ID the webhooks are attached to
28828
+ * @param {ListWebhooksV1StatusEnum} [status] Filter webhooks by status
28829
+ * @param {number} [page] Page number
28830
+ * @param {number} [perPage] Number of items per page
28831
+ * @param {*} [options] Override http request option.
28832
+ * @throws {RequiredError}
28833
+ */
28834
+ async listWebhooksV1(orderId: string, mailboxId?: string | null, status?: ListWebhooksV1StatusEnum, page?: number, perPage?: number, options?: RawAxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<MailListWebhooksV1200Response>> {
28835
+ const localVarAxiosArgs = await localVarAxiosParamCreator.listWebhooksV1(orderId, mailboxId, status, page, perPage, options);
28836
+ const localVarOperationServerBasePath = operationServerMap['MailWebhooksApi.listWebhooksV1']?.[0]?.url;
28837
+ return (axios, basePath) => createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration)(axios, localVarOperationServerBasePath || basePath);
28838
+ },
28839
+ /**
28840
+ * Regenerate the secret of a webhook. The previous secret is immediately invalidated. The new secret is returned only in this response and is sent as a bearer token with every delivery.
28841
+ * @summary Regenerate webhook secret
28842
+ * @param {string} webhookId Webhook ID (returned when the webhook was created)
28843
+ * @param {*} [options] Override http request option.
28844
+ * @throws {RequiredError}
28845
+ */
28846
+ async regenerateWebhookSecretV1(webhookId: string, options?: RawAxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<MailV1WebhooksWebhookSecretResource>> {
28847
+ const localVarAxiosArgs = await localVarAxiosParamCreator.regenerateWebhookSecretV1(webhookId, options);
28848
+ const localVarOperationServerBasePath = operationServerMap['MailWebhooksApi.regenerateWebhookSecretV1']?.[0]?.url;
28849
+ return (axios, basePath) => createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration)(axios, localVarOperationServerBasePath || basePath);
28850
+ },
28851
+ /**
28852
+ * Send a test delivery to the webhook URL and return the result. Test requests are rate limited upstream.
28853
+ * @summary Test webhook
28854
+ * @param {string} webhookId Webhook ID (returned when the webhook was created)
28855
+ * @param {*} [options] Override http request option.
28856
+ * @throws {RequiredError}
28857
+ */
28858
+ async testWebhookV1(webhookId: string, options?: RawAxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<MailV1WebhooksWebhookTestResultResource>> {
28859
+ const localVarAxiosArgs = await localVarAxiosParamCreator.testWebhookV1(webhookId, options);
28860
+ const localVarOperationServerBasePath = operationServerMap['MailWebhooksApi.testWebhookV1']?.[0]?.url;
28861
+ return (axios, basePath) => createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration)(axios, localVarOperationServerBasePath || basePath);
28862
+ },
28863
+ /**
28864
+ * Partially update a webhook. Only the fields included in the request body are changed; omitted fields retain their current values. Pass `\"description\": null` to clear the description.
28865
+ * @summary Update webhook
28866
+ * @param {string} webhookId Webhook ID (returned when the webhook was created)
28867
+ * @param {MailV1SchemaUpdateWebhookRequestSchema} mailV1SchemaUpdateWebhookRequestSchema
28868
+ * @param {*} [options] Override http request option.
28869
+ * @throws {RequiredError}
28870
+ */
28871
+ async updateWebhookV1(webhookId: string, mailV1SchemaUpdateWebhookRequestSchema: MailV1SchemaUpdateWebhookRequestSchema, options?: RawAxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<MailV1WebhooksWebhookResource>> {
28872
+ const localVarAxiosArgs = await localVarAxiosParamCreator.updateWebhookV1(webhookId, mailV1SchemaUpdateWebhookRequestSchema, options);
28873
+ const localVarOperationServerBasePath = operationServerMap['MailWebhooksApi.updateWebhookV1']?.[0]?.url;
28874
+ return (axios, basePath) => createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration)(axios, localVarOperationServerBasePath || basePath);
28875
+ },
28876
+ }
28877
+ };
28878
+
28879
+ /**
28880
+ * MailWebhooksApi - factory interface
28881
+ * @export
28882
+ */
28883
+ export const MailWebhooksApiFactory = function (configuration?: Configuration, basePath?: string, axios?: AxiosInstance) {
28884
+ const localVarFp = MailWebhooksApiFp(configuration)
28885
+ return {
28886
+ /**
28887
+ * Create a webhook for the given mailbox. The generated secret is returned only in this response and is sent as a bearer token with every delivery.
28888
+ * @summary Create webhook
28889
+ * @param {string} mailboxId Mailbox resource ID
28890
+ * @param {MailV1SchemaCreateWebhookRequestSchema} mailV1SchemaCreateWebhookRequestSchema
28891
+ * @param {*} [options] Override http request option.
28892
+ * @throws {RequiredError}
28893
+ */
28894
+ createWebhookV1(mailboxId: string, mailV1SchemaCreateWebhookRequestSchema: MailV1SchemaCreateWebhookRequestSchema, options?: RawAxiosRequestConfig): AxiosPromise<MailV1WebhooksWebhookCreatedResource> {
28895
+ return localVarFp.createWebhookV1(mailboxId, mailV1SchemaCreateWebhookRequestSchema, options).then((request) => request(axios, basePath));
28896
+ },
28897
+ /**
28898
+ * Permanently delete a webhook. This action cannot be undone. After deletion the URL no longer receives event notifications.
28899
+ * @summary Delete webhook
28900
+ * @param {string} webhookId Webhook ID (returned when the webhook was created)
28901
+ * @param {*} [options] Override http request option.
28902
+ * @throws {RequiredError}
28903
+ */
28904
+ deleteWebhookV1(webhookId: string, options?: RawAxiosRequestConfig): AxiosPromise<CommonSuccessEmptyResource> {
28905
+ return localVarFp.deleteWebhookV1(webhookId, options).then((request) => request(axios, basePath));
28906
+ },
28907
+ /**
28908
+ * Retrieve the details of a single webhook. The webhook secret is never included; it is returned only when a webhook is created or its secret is regenerated.
28909
+ * @summary Get webhook
28910
+ * @param {string} webhookId Webhook ID (returned when the webhook was created)
28911
+ * @param {*} [options] Override http request option.
28912
+ * @throws {RequiredError}
28913
+ */
28914
+ getWebhookV1(webhookId: string, options?: RawAxiosRequestConfig): AxiosPromise<MailV1WebhooksWebhookResource> {
28915
+ return localVarFp.getWebhookV1(webhookId, options).then((request) => request(axios, basePath));
28916
+ },
28917
+ /**
28918
+ * Retrieve a paginated list of webhook delivery logs for the given mail order, including delivery outcome, duration, and retry counts. Supports filtering by mailbox.
28919
+ * @summary List webhook delivery logs
28920
+ * @param {string} orderId Order resource ID
28921
+ * @param {string | null} [mailboxId] Filter by the mailbox resource ID the webhooks are attached to
28922
+ * @param {number} [page] Page number
28923
+ * @param {number} [perPage] Number of items per page
28924
+ * @param {*} [options] Override http request option.
28925
+ * @throws {RequiredError}
28926
+ */
28927
+ listWebhookDeliveryLogsV1(orderId: string, mailboxId?: string | null, page?: number, perPage?: number, options?: RawAxiosRequestConfig): AxiosPromise<MailListWebhookDeliveryLogsV1200Response> {
28928
+ return localVarFp.listWebhookDeliveryLogsV1(orderId, mailboxId, page, perPage, options).then((request) => request(axios, basePath));
28929
+ },
28930
+ /**
28931
+ * Retrieve a paginated list of webhooks belonging to the given mail order. Supports filtering by mailbox and status. The webhook secret is never included; it is returned only when a webhook is created or its secret is regenerated.
28932
+ * @summary List webhooks
28933
+ * @param {string} orderId Order resource ID
28934
+ * @param {string | null} [mailboxId] Filter by the mailbox resource ID the webhooks are attached to
28935
+ * @param {ListWebhooksV1StatusEnum} [status] Filter webhooks by status
28936
+ * @param {number} [page] Page number
28937
+ * @param {number} [perPage] Number of items per page
28938
+ * @param {*} [options] Override http request option.
28939
+ * @throws {RequiredError}
28940
+ */
28941
+ listWebhooksV1(orderId: string, mailboxId?: string | null, status?: ListWebhooksV1StatusEnum, page?: number, perPage?: number, options?: RawAxiosRequestConfig): AxiosPromise<MailListWebhooksV1200Response> {
28942
+ return localVarFp.listWebhooksV1(orderId, mailboxId, status, page, perPage, options).then((request) => request(axios, basePath));
28943
+ },
28944
+ /**
28945
+ * Regenerate the secret of a webhook. The previous secret is immediately invalidated. The new secret is returned only in this response and is sent as a bearer token with every delivery.
28946
+ * @summary Regenerate webhook secret
28947
+ * @param {string} webhookId Webhook ID (returned when the webhook was created)
28948
+ * @param {*} [options] Override http request option.
28949
+ * @throws {RequiredError}
28950
+ */
28951
+ regenerateWebhookSecretV1(webhookId: string, options?: RawAxiosRequestConfig): AxiosPromise<MailV1WebhooksWebhookSecretResource> {
28952
+ return localVarFp.regenerateWebhookSecretV1(webhookId, options).then((request) => request(axios, basePath));
28953
+ },
28954
+ /**
28955
+ * Send a test delivery to the webhook URL and return the result. Test requests are rate limited upstream.
28956
+ * @summary Test webhook
28957
+ * @param {string} webhookId Webhook ID (returned when the webhook was created)
28958
+ * @param {*} [options] Override http request option.
28959
+ * @throws {RequiredError}
28960
+ */
28961
+ testWebhookV1(webhookId: string, options?: RawAxiosRequestConfig): AxiosPromise<MailV1WebhooksWebhookTestResultResource> {
28962
+ return localVarFp.testWebhookV1(webhookId, options).then((request) => request(axios, basePath));
28963
+ },
28964
+ /**
28965
+ * Partially update a webhook. Only the fields included in the request body are changed; omitted fields retain their current values. Pass `\"description\": null` to clear the description.
28966
+ * @summary Update webhook
28967
+ * @param {string} webhookId Webhook ID (returned when the webhook was created)
28968
+ * @param {MailV1SchemaUpdateWebhookRequestSchema} mailV1SchemaUpdateWebhookRequestSchema
28969
+ * @param {*} [options] Override http request option.
28970
+ * @throws {RequiredError}
28971
+ */
28972
+ updateWebhookV1(webhookId: string, mailV1SchemaUpdateWebhookRequestSchema: MailV1SchemaUpdateWebhookRequestSchema, options?: RawAxiosRequestConfig): AxiosPromise<MailV1WebhooksWebhookResource> {
28973
+ return localVarFp.updateWebhookV1(webhookId, mailV1SchemaUpdateWebhookRequestSchema, options).then((request) => request(axios, basePath));
28974
+ },
28975
+ };
28976
+ };
28977
+
28978
+ /**
28979
+ * MailWebhooksApi - object-oriented interface
28980
+ * @export
28981
+ * @class MailWebhooksApi
28982
+ * @extends {BaseAPI}
28983
+ */
28984
+ export class MailWebhooksApi extends BaseAPI {
28985
+ /**
28986
+ * Create a webhook for the given mailbox. The generated secret is returned only in this response and is sent as a bearer token with every delivery.
28987
+ * @summary Create webhook
28988
+ * @param {string} mailboxId Mailbox resource ID
28989
+ * @param {MailV1SchemaCreateWebhookRequestSchema} mailV1SchemaCreateWebhookRequestSchema
28990
+ * @param {*} [options] Override http request option.
28991
+ * @throws {RequiredError}
28992
+ * @memberof MailWebhooksApi
28993
+ */
28994
+ public createWebhookV1(mailboxId: string, mailV1SchemaCreateWebhookRequestSchema: MailV1SchemaCreateWebhookRequestSchema, options?: RawAxiosRequestConfig) {
28995
+ return MailWebhooksApiFp(this.configuration).createWebhookV1(mailboxId, mailV1SchemaCreateWebhookRequestSchema, options).then((request) => request(this.axios, this.basePath));
28996
+ }
28997
+
28998
+ /**
28999
+ * Permanently delete a webhook. This action cannot be undone. After deletion the URL no longer receives event notifications.
29000
+ * @summary Delete webhook
29001
+ * @param {string} webhookId Webhook ID (returned when the webhook was created)
29002
+ * @param {*} [options] Override http request option.
29003
+ * @throws {RequiredError}
29004
+ * @memberof MailWebhooksApi
29005
+ */
29006
+ public deleteWebhookV1(webhookId: string, options?: RawAxiosRequestConfig) {
29007
+ return MailWebhooksApiFp(this.configuration).deleteWebhookV1(webhookId, options).then((request) => request(this.axios, this.basePath));
29008
+ }
29009
+
29010
+ /**
29011
+ * Retrieve the details of a single webhook. The webhook secret is never included; it is returned only when a webhook is created or its secret is regenerated.
29012
+ * @summary Get webhook
29013
+ * @param {string} webhookId Webhook ID (returned when the webhook was created)
29014
+ * @param {*} [options] Override http request option.
29015
+ * @throws {RequiredError}
29016
+ * @memberof MailWebhooksApi
29017
+ */
29018
+ public getWebhookV1(webhookId: string, options?: RawAxiosRequestConfig) {
29019
+ return MailWebhooksApiFp(this.configuration).getWebhookV1(webhookId, options).then((request) => request(this.axios, this.basePath));
29020
+ }
29021
+
29022
+ /**
29023
+ * Retrieve a paginated list of webhook delivery logs for the given mail order, including delivery outcome, duration, and retry counts. Supports filtering by mailbox.
29024
+ * @summary List webhook delivery logs
29025
+ * @param {string} orderId Order resource ID
29026
+ * @param {string | null} [mailboxId] Filter by the mailbox resource ID the webhooks are attached to
29027
+ * @param {number} [page] Page number
29028
+ * @param {number} [perPage] Number of items per page
29029
+ * @param {*} [options] Override http request option.
29030
+ * @throws {RequiredError}
29031
+ * @memberof MailWebhooksApi
29032
+ */
29033
+ public listWebhookDeliveryLogsV1(orderId: string, mailboxId?: string | null, page?: number, perPage?: number, options?: RawAxiosRequestConfig) {
29034
+ return MailWebhooksApiFp(this.configuration).listWebhookDeliveryLogsV1(orderId, mailboxId, page, perPage, options).then((request) => request(this.axios, this.basePath));
29035
+ }
29036
+
29037
+ /**
29038
+ * Retrieve a paginated list of webhooks belonging to the given mail order. Supports filtering by mailbox and status. The webhook secret is never included; it is returned only when a webhook is created or its secret is regenerated.
29039
+ * @summary List webhooks
29040
+ * @param {string} orderId Order resource ID
29041
+ * @param {string | null} [mailboxId] Filter by the mailbox resource ID the webhooks are attached to
29042
+ * @param {ListWebhooksV1StatusEnum} [status] Filter webhooks by status
29043
+ * @param {number} [page] Page number
29044
+ * @param {number} [perPage] Number of items per page
29045
+ * @param {*} [options] Override http request option.
29046
+ * @throws {RequiredError}
29047
+ * @memberof MailWebhooksApi
29048
+ */
29049
+ public listWebhooksV1(orderId: string, mailboxId?: string | null, status?: ListWebhooksV1StatusEnum, page?: number, perPage?: number, options?: RawAxiosRequestConfig) {
29050
+ return MailWebhooksApiFp(this.configuration).listWebhooksV1(orderId, mailboxId, status, page, perPage, options).then((request) => request(this.axios, this.basePath));
29051
+ }
29052
+
29053
+ /**
29054
+ * Regenerate the secret of a webhook. The previous secret is immediately invalidated. The new secret is returned only in this response and is sent as a bearer token with every delivery.
29055
+ * @summary Regenerate webhook secret
29056
+ * @param {string} webhookId Webhook ID (returned when the webhook was created)
29057
+ * @param {*} [options] Override http request option.
29058
+ * @throws {RequiredError}
29059
+ * @memberof MailWebhooksApi
29060
+ */
29061
+ public regenerateWebhookSecretV1(webhookId: string, options?: RawAxiosRequestConfig) {
29062
+ return MailWebhooksApiFp(this.configuration).regenerateWebhookSecretV1(webhookId, options).then((request) => request(this.axios, this.basePath));
29063
+ }
29064
+
29065
+ /**
29066
+ * Send a test delivery to the webhook URL and return the result. Test requests are rate limited upstream.
29067
+ * @summary Test webhook
29068
+ * @param {string} webhookId Webhook ID (returned when the webhook was created)
29069
+ * @param {*} [options] Override http request option.
29070
+ * @throws {RequiredError}
29071
+ * @memberof MailWebhooksApi
29072
+ */
29073
+ public testWebhookV1(webhookId: string, options?: RawAxiosRequestConfig) {
29074
+ return MailWebhooksApiFp(this.configuration).testWebhookV1(webhookId, options).then((request) => request(this.axios, this.basePath));
29075
+ }
29076
+
29077
+ /**
29078
+ * Partially update a webhook. Only the fields included in the request body are changed; omitted fields retain their current values. Pass `\"description\": null` to clear the description.
29079
+ * @summary Update webhook
29080
+ * @param {string} webhookId Webhook ID (returned when the webhook was created)
29081
+ * @param {MailV1SchemaUpdateWebhookRequestSchema} mailV1SchemaUpdateWebhookRequestSchema
29082
+ * @param {*} [options] Override http request option.
29083
+ * @throws {RequiredError}
29084
+ * @memberof MailWebhooksApi
29085
+ */
29086
+ public updateWebhookV1(webhookId: string, mailV1SchemaUpdateWebhookRequestSchema: MailV1SchemaUpdateWebhookRequestSchema, options?: RawAxiosRequestConfig) {
29087
+ return MailWebhooksApiFp(this.configuration).updateWebhookV1(webhookId, mailV1SchemaUpdateWebhookRequestSchema, options).then((request) => request(this.axios, this.basePath));
29088
+ }
29089
+ }
29090
+
29091
+ /**
29092
+ * @export
29093
+ */
29094
+ export const ListWebhooksV1StatusEnum = {
29095
+ Active: 'active',
29096
+ Disabled: 'disabled',
29097
+ Paused: 'paused'
29098
+ } as const;
29099
+ export type ListWebhooksV1StatusEnum = typeof ListWebhooksV1StatusEnum[keyof typeof ListWebhooksV1StatusEnum];
28038
29100
 
28039
- return {
28040
- url: toPathString(localVarUrlObj),
28041
- options: localVarRequestOptions,
28042
- };
28043
- },
29101
+
29102
+ /**
29103
+ * ReachAutomationsApi - axios parameter creator
29104
+ * @export
29105
+ */
29106
+ export const ReachAutomationsApiAxiosParamCreator = function (configuration?: Configuration) {
29107
+ return {
28044
29108
  /**
28045
- * Regenerate the secret of a webhook. The previous secret is immediately invalidated. The new secret is returned only in this response and is sent as a bearer token with every delivery.
28046
- * @summary Regenerate webhook secret
28047
- * @param {string} webhookId Webhook ID (returned when the webhook was created)
29109
+ * Get a single automation with the counts of contacts that entered it, are moving through it, finished it or failed on the way. This describes the automation itself. To see the workflow it runs, use the steps endpoint.
29110
+ * @summary Get automation details
29111
+ * @param {string} profileUuid Profile uuid parameter
29112
+ * @param {string} automationUuid Automation uuid parameter
28048
29113
  * @param {*} [options] Override http request option.
28049
29114
  * @throws {RequiredError}
28050
29115
  */
28051
- regenerateWebhookSecretV1: async (webhookId: string, options: RawAxiosRequestConfig = {}): Promise<RequestArgs> => {
28052
- // verify required parameter 'webhookId' is not null or undefined
28053
- assertParamExists('regenerateWebhookSecretV1', 'webhookId', webhookId)
28054
- const localVarPath = `/api/mail/v1/webhooks/{webhookId}/regenerate-secret`
28055
- .replace(`{${"webhookId"}}`, encodeURIComponent(String(webhookId)));
29116
+ getAutomationDetailsV1: async (profileUuid: string, automationUuid: string, options: RawAxiosRequestConfig = {}): Promise<RequestArgs> => {
29117
+ // verify required parameter 'profileUuid' is not null or undefined
29118
+ assertParamExists('getAutomationDetailsV1', 'profileUuid', profileUuid)
29119
+ // verify required parameter 'automationUuid' is not null or undefined
29120
+ assertParamExists('getAutomationDetailsV1', 'automationUuid', automationUuid)
29121
+ const localVarPath = `/api/reach/v1/profiles/{profileUuid}/automations/{automationUuid}`
29122
+ .replace(`{${"profileUuid"}}`, encodeURIComponent(String(profileUuid)))
29123
+ .replace(`{${"automationUuid"}}`, encodeURIComponent(String(automationUuid)));
28056
29124
  // use dummy base URL string because the URL constructor only accepts absolute URLs.
28057
29125
  const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL);
28058
29126
  let baseOptions;
@@ -28060,7 +29128,7 @@ export const MailWebhooksApiAxiosParamCreator = function (configuration?: Config
28060
29128
  baseOptions = configuration.baseOptions;
28061
29129
  }
28062
29130
 
28063
- const localVarRequestOptions = { method: 'POST', ...baseOptions, ...options};
29131
+ const localVarRequestOptions = { method: 'GET', ...baseOptions, ...options};
28064
29132
  const localVarHeaderParameter = {} as any;
28065
29133
  const localVarQueryParameter = {} as any;
28066
29134
 
@@ -28080,17 +29148,21 @@ export const MailWebhooksApiAxiosParamCreator = function (configuration?: Config
28080
29148
  };
28081
29149
  },
28082
29150
  /**
28083
- * Send a test delivery to the webhook URL and return the result. Test requests are rate limited upstream.
28084
- * @summary Test webhook
28085
- * @param {string} webhookId Webhook ID (returned when the webhook was created)
29151
+ * Get the workflow of an automation as a flat list of steps. The steps form a tree rather than a straight line: follow `parent_uuid` to reconstruct the branches, and use `step_order` to order the steps that share a parent. An automation with no steps yet returns an empty list.
29152
+ * @summary List automation steps
29153
+ * @param {string} profileUuid Profile uuid parameter
29154
+ * @param {string} automationUuid Automation uuid parameter
28086
29155
  * @param {*} [options] Override http request option.
28087
29156
  * @throws {RequiredError}
28088
29157
  */
28089
- testWebhookV1: async (webhookId: string, options: RawAxiosRequestConfig = {}): Promise<RequestArgs> => {
28090
- // verify required parameter 'webhookId' is not null or undefined
28091
- assertParamExists('testWebhookV1', 'webhookId', webhookId)
28092
- const localVarPath = `/api/mail/v1/webhooks/{webhookId}/test`
28093
- .replace(`{${"webhookId"}}`, encodeURIComponent(String(webhookId)));
29158
+ listAutomationStepsV1: async (profileUuid: string, automationUuid: string, options: RawAxiosRequestConfig = {}): Promise<RequestArgs> => {
29159
+ // verify required parameter 'profileUuid' is not null or undefined
29160
+ assertParamExists('listAutomationStepsV1', 'profileUuid', profileUuid)
29161
+ // verify required parameter 'automationUuid' is not null or undefined
29162
+ assertParamExists('listAutomationStepsV1', 'automationUuid', automationUuid)
29163
+ const localVarPath = `/api/reach/v1/profiles/{profileUuid}/automations/{automationUuid}/steps`
29164
+ .replace(`{${"profileUuid"}}`, encodeURIComponent(String(profileUuid)))
29165
+ .replace(`{${"automationUuid"}}`, encodeURIComponent(String(automationUuid)));
28094
29166
  // use dummy base URL string because the URL constructor only accepts absolute URLs.
28095
29167
  const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL);
28096
29168
  let baseOptions;
@@ -28098,7 +29170,7 @@ export const MailWebhooksApiAxiosParamCreator = function (configuration?: Config
28098
29170
  baseOptions = configuration.baseOptions;
28099
29171
  }
28100
29172
 
28101
- const localVarRequestOptions = { method: 'POST', ...baseOptions, ...options};
29173
+ const localVarRequestOptions = { method: 'GET', ...baseOptions, ...options};
28102
29174
  const localVarHeaderParameter = {} as any;
28103
29175
  const localVarQueryParameter = {} as any;
28104
29176
 
@@ -28118,20 +29190,21 @@ export const MailWebhooksApiAxiosParamCreator = function (configuration?: Config
28118
29190
  };
28119
29191
  },
28120
29192
  /**
28121
- * Partially update a webhook. Only the fields included in the request body are changed; omitted fields retain their current values. Pass `\"description\": null` to clear the description.
28122
- * @summary Update webhook
28123
- * @param {string} webhookId Webhook ID (returned when the webhook was created)
28124
- * @param {MailV1SchemaUpdateWebhookRequestSchema} mailV1SchemaUpdateWebhookRequestSchema
29193
+ * Get a paginated list of the automations in a profile. Every automation comes with the counts of contacts that entered it, are moving through it, finished it or failed on the way. Those counts describe the contact journey and are not email engagement metrics - for opens, clicks and unsubscribes use the campaign statistics endpoint instead.
29194
+ * @summary List automations
29195
+ * @param {string} profileUuid Profile uuid parameter
29196
+ * @param {ListAutomationsV1StatusEnum} [status] Filter automations by status. There is no &#x60;completed&#x60; status. An automation that has finished for every contact still reports &#x60;active&#x60;.
29197
+ * @param {ListAutomationsV1SortDirectionEnum} [sortDirection] Order automations by creation date. Newest first unless set to &#x60;asc&#x60;.
29198
+ * @param {number} [page] Page number
29199
+ * @param {number} [perPage] Number of items per page
28125
29200
  * @param {*} [options] Override http request option.
28126
29201
  * @throws {RequiredError}
28127
29202
  */
28128
- updateWebhookV1: async (webhookId: string, mailV1SchemaUpdateWebhookRequestSchema: MailV1SchemaUpdateWebhookRequestSchema, options: RawAxiosRequestConfig = {}): Promise<RequestArgs> => {
28129
- // verify required parameter 'webhookId' is not null or undefined
28130
- assertParamExists('updateWebhookV1', 'webhookId', webhookId)
28131
- // verify required parameter 'mailV1SchemaUpdateWebhookRequestSchema' is not null or undefined
28132
- assertParamExists('updateWebhookV1', 'mailV1SchemaUpdateWebhookRequestSchema', mailV1SchemaUpdateWebhookRequestSchema)
28133
- const localVarPath = `/api/mail/v1/webhooks/{webhookId}`
28134
- .replace(`{${"webhookId"}}`, encodeURIComponent(String(webhookId)));
29203
+ listAutomationsV1: async (profileUuid: string, status?: ListAutomationsV1StatusEnum, sortDirection?: ListAutomationsV1SortDirectionEnum, page?: number, perPage?: number, options: RawAxiosRequestConfig = {}): Promise<RequestArgs> => {
29204
+ // verify required parameter 'profileUuid' is not null or undefined
29205
+ assertParamExists('listAutomationsV1', 'profileUuid', profileUuid)
29206
+ const localVarPath = `/api/reach/v1/profiles/{profileUuid}/automations`
29207
+ .replace(`{${"profileUuid"}}`, encodeURIComponent(String(profileUuid)));
28135
29208
  // use dummy base URL string because the URL constructor only accepts absolute URLs.
28136
29209
  const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL);
28137
29210
  let baseOptions;
@@ -28139,7 +29212,7 @@ export const MailWebhooksApiAxiosParamCreator = function (configuration?: Config
28139
29212
  baseOptions = configuration.baseOptions;
28140
29213
  }
28141
29214
 
28142
- const localVarRequestOptions = { method: 'PATCH', ...baseOptions, ...options};
29215
+ const localVarRequestOptions = { method: 'GET', ...baseOptions, ...options};
28143
29216
  const localVarHeaderParameter = {} as any;
28144
29217
  const localVarQueryParameter = {} as any;
28145
29218
 
@@ -28147,14 +29220,27 @@ export const MailWebhooksApiAxiosParamCreator = function (configuration?: Config
28147
29220
  // http bearer authentication required
28148
29221
  await setBearerAuthToObject(localVarHeaderParameter, configuration)
28149
29222
 
29223
+ if (status !== undefined) {
29224
+ localVarQueryParameter['status'] = status;
29225
+ }
28150
29226
 
28151
-
28152
- localVarHeaderParameter['Content-Type'] = 'application/json';
29227
+ if (sortDirection !== undefined) {
29228
+ localVarQueryParameter['sort_direction'] = sortDirection;
29229
+ }
29230
+
29231
+ if (page !== undefined) {
29232
+ localVarQueryParameter['page'] = page;
29233
+ }
29234
+
29235
+ if (perPage !== undefined) {
29236
+ localVarQueryParameter['per_page'] = perPage;
29237
+ }
28153
29238
 
29239
+
29240
+
28154
29241
  setSearchParams(localVarUrlObj, localVarQueryParameter);
28155
29242
  let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
28156
29243
  localVarRequestOptions.headers = {...localVarHeaderParameter, ...headersFromBaseOptions, ...options.headers};
28157
- localVarRequestOptions.data = serializeDataIfNeeded(mailV1SchemaUpdateWebhookRequestSchema, localVarRequestOptions, configuration)
28158
29244
 
28159
29245
  return {
28160
29246
  url: toPathString(localVarUrlObj),
@@ -28165,341 +29251,507 @@ export const MailWebhooksApiAxiosParamCreator = function (configuration?: Config
28165
29251
  };
28166
29252
 
28167
29253
  /**
28168
- * MailWebhooksApi - functional programming interface
29254
+ * ReachAutomationsApi - functional programming interface
28169
29255
  * @export
28170
29256
  */
28171
- export const MailWebhooksApiFp = function(configuration?: Configuration) {
28172
- const localVarAxiosParamCreator = MailWebhooksApiAxiosParamCreator(configuration)
29257
+ export const ReachAutomationsApiFp = function(configuration?: Configuration) {
29258
+ const localVarAxiosParamCreator = ReachAutomationsApiAxiosParamCreator(configuration)
28173
29259
  return {
28174
29260
  /**
28175
- * Create a webhook for the given mailbox. The generated secret is returned only in this response and is sent as a bearer token with every delivery.
28176
- * @summary Create webhook
28177
- * @param {string} mailboxId Mailbox resource ID
28178
- * @param {MailV1SchemaCreateWebhookRequestSchema} mailV1SchemaCreateWebhookRequestSchema
29261
+ * Get a single automation with the counts of contacts that entered it, are moving through it, finished it or failed on the way. This describes the automation itself. To see the workflow it runs, use the steps endpoint.
29262
+ * @summary Get automation details
29263
+ * @param {string} profileUuid Profile uuid parameter
29264
+ * @param {string} automationUuid Automation uuid parameter
28179
29265
  * @param {*} [options] Override http request option.
28180
29266
  * @throws {RequiredError}
28181
29267
  */
28182
- async createWebhookV1(mailboxId: string, mailV1SchemaCreateWebhookRequestSchema: MailV1SchemaCreateWebhookRequestSchema, options?: RawAxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<MailV1WebhooksWebhookCreatedResource>> {
28183
- const localVarAxiosArgs = await localVarAxiosParamCreator.createWebhookV1(mailboxId, mailV1SchemaCreateWebhookRequestSchema, options);
28184
- const localVarOperationServerBasePath = operationServerMap['MailWebhooksApi.createWebhookV1']?.[0]?.url;
29268
+ async getAutomationDetailsV1(profileUuid: string, automationUuid: string, options?: RawAxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<ReachV1AutomationsAutomationResource>> {
29269
+ const localVarAxiosArgs = await localVarAxiosParamCreator.getAutomationDetailsV1(profileUuid, automationUuid, options);
29270
+ const localVarOperationServerBasePath = operationServerMap['ReachAutomationsApi.getAutomationDetailsV1']?.[0]?.url;
28185
29271
  return (axios, basePath) => createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration)(axios, localVarOperationServerBasePath || basePath);
28186
29272
  },
28187
29273
  /**
28188
- * Permanently delete a webhook. This action cannot be undone. After deletion the URL no longer receives event notifications.
28189
- * @summary Delete webhook
28190
- * @param {string} webhookId Webhook ID (returned when the webhook was created)
29274
+ * Get the workflow of an automation as a flat list of steps. The steps form a tree rather than a straight line: follow `parent_uuid` to reconstruct the branches, and use `step_order` to order the steps that share a parent. An automation with no steps yet returns an empty list.
29275
+ * @summary List automation steps
29276
+ * @param {string} profileUuid Profile uuid parameter
29277
+ * @param {string} automationUuid Automation uuid parameter
28191
29278
  * @param {*} [options] Override http request option.
28192
29279
  * @throws {RequiredError}
28193
29280
  */
28194
- async deleteWebhookV1(webhookId: string, options?: RawAxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<CommonSuccessEmptyResource>> {
28195
- const localVarAxiosArgs = await localVarAxiosParamCreator.deleteWebhookV1(webhookId, options);
28196
- const localVarOperationServerBasePath = operationServerMap['MailWebhooksApi.deleteWebhookV1']?.[0]?.url;
29281
+ async listAutomationStepsV1(profileUuid: string, automationUuid: string, options?: RawAxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<Array<ReachV1AutomationsStepsAutomationStepResource>>> {
29282
+ const localVarAxiosArgs = await localVarAxiosParamCreator.listAutomationStepsV1(profileUuid, automationUuid, options);
29283
+ const localVarOperationServerBasePath = operationServerMap['ReachAutomationsApi.listAutomationStepsV1']?.[0]?.url;
28197
29284
  return (axios, basePath) => createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration)(axios, localVarOperationServerBasePath || basePath);
28198
29285
  },
28199
29286
  /**
28200
- * Retrieve the details of a single webhook. The webhook secret is never included; it is returned only when a webhook is created or its secret is regenerated.
28201
- * @summary Get webhook
28202
- * @param {string} webhookId Webhook ID (returned when the webhook was created)
29287
+ * Get a paginated list of the automations in a profile. Every automation comes with the counts of contacts that entered it, are moving through it, finished it or failed on the way. Those counts describe the contact journey and are not email engagement metrics - for opens, clicks and unsubscribes use the campaign statistics endpoint instead.
29288
+ * @summary List automations
29289
+ * @param {string} profileUuid Profile uuid parameter
29290
+ * @param {ListAutomationsV1StatusEnum} [status] Filter automations by status. There is no &#x60;completed&#x60; status. An automation that has finished for every contact still reports &#x60;active&#x60;.
29291
+ * @param {ListAutomationsV1SortDirectionEnum} [sortDirection] Order automations by creation date. Newest first unless set to &#x60;asc&#x60;.
29292
+ * @param {number} [page] Page number
29293
+ * @param {number} [perPage] Number of items per page
28203
29294
  * @param {*} [options] Override http request option.
28204
29295
  * @throws {RequiredError}
28205
29296
  */
28206
- async getWebhookV1(webhookId: string, options?: RawAxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<MailV1WebhooksWebhookResource>> {
28207
- const localVarAxiosArgs = await localVarAxiosParamCreator.getWebhookV1(webhookId, options);
28208
- const localVarOperationServerBasePath = operationServerMap['MailWebhooksApi.getWebhookV1']?.[0]?.url;
29297
+ async listAutomationsV1(profileUuid: string, status?: ListAutomationsV1StatusEnum, sortDirection?: ListAutomationsV1SortDirectionEnum, page?: number, perPage?: number, options?: RawAxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<ReachListAutomationsV1200Response>> {
29298
+ const localVarAxiosArgs = await localVarAxiosParamCreator.listAutomationsV1(profileUuid, status, sortDirection, page, perPage, options);
29299
+ const localVarOperationServerBasePath = operationServerMap['ReachAutomationsApi.listAutomationsV1']?.[0]?.url;
28209
29300
  return (axios, basePath) => createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration)(axios, localVarOperationServerBasePath || basePath);
28210
29301
  },
29302
+ }
29303
+ };
29304
+
29305
+ /**
29306
+ * ReachAutomationsApi - factory interface
29307
+ * @export
29308
+ */
29309
+ export const ReachAutomationsApiFactory = function (configuration?: Configuration, basePath?: string, axios?: AxiosInstance) {
29310
+ const localVarFp = ReachAutomationsApiFp(configuration)
29311
+ return {
29312
+ /**
29313
+ * Get a single automation with the counts of contacts that entered it, are moving through it, finished it or failed on the way. This describes the automation itself. To see the workflow it runs, use the steps endpoint.
29314
+ * @summary Get automation details
29315
+ * @param {string} profileUuid Profile uuid parameter
29316
+ * @param {string} automationUuid Automation uuid parameter
29317
+ * @param {*} [options] Override http request option.
29318
+ * @throws {RequiredError}
29319
+ */
29320
+ getAutomationDetailsV1(profileUuid: string, automationUuid: string, options?: RawAxiosRequestConfig): AxiosPromise<ReachV1AutomationsAutomationResource> {
29321
+ return localVarFp.getAutomationDetailsV1(profileUuid, automationUuid, options).then((request) => request(axios, basePath));
29322
+ },
28211
29323
  /**
28212
- * Retrieve a paginated list of webhook delivery logs for the given mail order, including delivery outcome, duration, and retry counts. Supports filtering by mailbox.
28213
- * @summary List webhook delivery logs
28214
- * @param {string} orderId Order resource ID
28215
- * @param {string | null} [mailboxId] Filter by the mailbox resource ID the webhooks are attached to
28216
- * @param {number} [page] Page number
28217
- * @param {number} [perPage] Number of items per page
29324
+ * Get the workflow of an automation as a flat list of steps. The steps form a tree rather than a straight line: follow `parent_uuid` to reconstruct the branches, and use `step_order` to order the steps that share a parent. An automation with no steps yet returns an empty list.
29325
+ * @summary List automation steps
29326
+ * @param {string} profileUuid Profile uuid parameter
29327
+ * @param {string} automationUuid Automation uuid parameter
28218
29328
  * @param {*} [options] Override http request option.
28219
29329
  * @throws {RequiredError}
28220
29330
  */
28221
- async listWebhookDeliveryLogsV1(orderId: string, mailboxId?: string | null, page?: number, perPage?: number, options?: RawAxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<MailListWebhookDeliveryLogsV1200Response>> {
28222
- const localVarAxiosArgs = await localVarAxiosParamCreator.listWebhookDeliveryLogsV1(orderId, mailboxId, page, perPage, options);
28223
- const localVarOperationServerBasePath = operationServerMap['MailWebhooksApi.listWebhookDeliveryLogsV1']?.[0]?.url;
28224
- return (axios, basePath) => createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration)(axios, localVarOperationServerBasePath || basePath);
29331
+ listAutomationStepsV1(profileUuid: string, automationUuid: string, options?: RawAxiosRequestConfig): AxiosPromise<Array<ReachV1AutomationsStepsAutomationStepResource>> {
29332
+ return localVarFp.listAutomationStepsV1(profileUuid, automationUuid, options).then((request) => request(axios, basePath));
28225
29333
  },
28226
29334
  /**
28227
- * Retrieve a paginated list of webhooks belonging to the given mail order. Supports filtering by mailbox and status. The webhook secret is never included; it is returned only when a webhook is created or its secret is regenerated.
28228
- * @summary List webhooks
28229
- * @param {string} orderId Order resource ID
28230
- * @param {string | null} [mailboxId] Filter by the mailbox resource ID the webhooks are attached to
28231
- * @param {ListWebhooksV1StatusEnum} [status] Filter webhooks by status
29335
+ * Get a paginated list of the automations in a profile. Every automation comes with the counts of contacts that entered it, are moving through it, finished it or failed on the way. Those counts describe the contact journey and are not email engagement metrics - for opens, clicks and unsubscribes use the campaign statistics endpoint instead.
29336
+ * @summary List automations
29337
+ * @param {string} profileUuid Profile uuid parameter
29338
+ * @param {ListAutomationsV1StatusEnum} [status] Filter automations by status. There is no &#x60;completed&#x60; status. An automation that has finished for every contact still reports &#x60;active&#x60;.
29339
+ * @param {ListAutomationsV1SortDirectionEnum} [sortDirection] Order automations by creation date. Newest first unless set to &#x60;asc&#x60;.
28232
29340
  * @param {number} [page] Page number
28233
29341
  * @param {number} [perPage] Number of items per page
28234
29342
  * @param {*} [options] Override http request option.
28235
29343
  * @throws {RequiredError}
28236
29344
  */
28237
- async listWebhooksV1(orderId: string, mailboxId?: string | null, status?: ListWebhooksV1StatusEnum, page?: number, perPage?: number, options?: RawAxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<MailListWebhooksV1200Response>> {
28238
- const localVarAxiosArgs = await localVarAxiosParamCreator.listWebhooksV1(orderId, mailboxId, status, page, perPage, options);
28239
- const localVarOperationServerBasePath = operationServerMap['MailWebhooksApi.listWebhooksV1']?.[0]?.url;
28240
- return (axios, basePath) => createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration)(axios, localVarOperationServerBasePath || basePath);
29345
+ listAutomationsV1(profileUuid: string, status?: ListAutomationsV1StatusEnum, sortDirection?: ListAutomationsV1SortDirectionEnum, page?: number, perPage?: number, options?: RawAxiosRequestConfig): AxiosPromise<ReachListAutomationsV1200Response> {
29346
+ return localVarFp.listAutomationsV1(profileUuid, status, sortDirection, page, perPage, options).then((request) => request(axios, basePath));
28241
29347
  },
29348
+ };
29349
+ };
29350
+
29351
+ /**
29352
+ * ReachAutomationsApi - object-oriented interface
29353
+ * @export
29354
+ * @class ReachAutomationsApi
29355
+ * @extends {BaseAPI}
29356
+ */
29357
+ export class ReachAutomationsApi extends BaseAPI {
29358
+ /**
29359
+ * Get a single automation with the counts of contacts that entered it, are moving through it, finished it or failed on the way. This describes the automation itself. To see the workflow it runs, use the steps endpoint.
29360
+ * @summary Get automation details
29361
+ * @param {string} profileUuid Profile uuid parameter
29362
+ * @param {string} automationUuid Automation uuid parameter
29363
+ * @param {*} [options] Override http request option.
29364
+ * @throws {RequiredError}
29365
+ * @memberof ReachAutomationsApi
29366
+ */
29367
+ public getAutomationDetailsV1(profileUuid: string, automationUuid: string, options?: RawAxiosRequestConfig) {
29368
+ return ReachAutomationsApiFp(this.configuration).getAutomationDetailsV1(profileUuid, automationUuid, options).then((request) => request(this.axios, this.basePath));
29369
+ }
29370
+
29371
+ /**
29372
+ * Get the workflow of an automation as a flat list of steps. The steps form a tree rather than a straight line: follow `parent_uuid` to reconstruct the branches, and use `step_order` to order the steps that share a parent. An automation with no steps yet returns an empty list.
29373
+ * @summary List automation steps
29374
+ * @param {string} profileUuid Profile uuid parameter
29375
+ * @param {string} automationUuid Automation uuid parameter
29376
+ * @param {*} [options] Override http request option.
29377
+ * @throws {RequiredError}
29378
+ * @memberof ReachAutomationsApi
29379
+ */
29380
+ public listAutomationStepsV1(profileUuid: string, automationUuid: string, options?: RawAxiosRequestConfig) {
29381
+ return ReachAutomationsApiFp(this.configuration).listAutomationStepsV1(profileUuid, automationUuid, options).then((request) => request(this.axios, this.basePath));
29382
+ }
29383
+
29384
+ /**
29385
+ * Get a paginated list of the automations in a profile. Every automation comes with the counts of contacts that entered it, are moving through it, finished it or failed on the way. Those counts describe the contact journey and are not email engagement metrics - for opens, clicks and unsubscribes use the campaign statistics endpoint instead.
29386
+ * @summary List automations
29387
+ * @param {string} profileUuid Profile uuid parameter
29388
+ * @param {ListAutomationsV1StatusEnum} [status] Filter automations by status. There is no &#x60;completed&#x60; status. An automation that has finished for every contact still reports &#x60;active&#x60;.
29389
+ * @param {ListAutomationsV1SortDirectionEnum} [sortDirection] Order automations by creation date. Newest first unless set to &#x60;asc&#x60;.
29390
+ * @param {number} [page] Page number
29391
+ * @param {number} [perPage] Number of items per page
29392
+ * @param {*} [options] Override http request option.
29393
+ * @throws {RequiredError}
29394
+ * @memberof ReachAutomationsApi
29395
+ */
29396
+ public listAutomationsV1(profileUuid: string, status?: ListAutomationsV1StatusEnum, sortDirection?: ListAutomationsV1SortDirectionEnum, page?: number, perPage?: number, options?: RawAxiosRequestConfig) {
29397
+ return ReachAutomationsApiFp(this.configuration).listAutomationsV1(profileUuid, status, sortDirection, page, perPage, options).then((request) => request(this.axios, this.basePath));
29398
+ }
29399
+ }
29400
+
29401
+ /**
29402
+ * @export
29403
+ */
29404
+ export const ListAutomationsV1StatusEnum = {
29405
+ Active: 'active',
29406
+ Paused: 'paused',
29407
+ Draft: 'draft'
29408
+ } as const;
29409
+ export type ListAutomationsV1StatusEnum = typeof ListAutomationsV1StatusEnum[keyof typeof ListAutomationsV1StatusEnum];
29410
+ /**
29411
+ * @export
29412
+ */
29413
+ export const ListAutomationsV1SortDirectionEnum = {
29414
+ Asc: 'asc',
29415
+ Desc: 'desc'
29416
+ } as const;
29417
+ export type ListAutomationsV1SortDirectionEnum = typeof ListAutomationsV1SortDirectionEnum[keyof typeof ListAutomationsV1SortDirectionEnum];
29418
+
29419
+
29420
+ /**
29421
+ * ReachCampaignsApi - axios parameter creator
29422
+ * @export
29423
+ */
29424
+ export const ReachCampaignsApiAxiosParamCreator = function (configuration?: Configuration) {
29425
+ return {
28242
29426
  /**
28243
- * Regenerate the secret of a webhook. The previous secret is immediately invalidated. The new secret is returned only in this response and is sent as a bearer token with every delivery.
28244
- * @summary Regenerate webhook secret
28245
- * @param {string} webhookId Webhook ID (returned when the webhook was created)
29427
+ * Get a single campaign with its sender, subject, template reference, targeting and delivery progress. This describes how the campaign was set up and how far it has got. For opens, clicks and unsubscribes use the campaign statistics endpoint.
29428
+ * @summary Get campaign details
29429
+ * @param {string} profileUuid Profile uuid parameter
29430
+ * @param {string} campaignUuid Campaign uuid parameter
28246
29431
  * @param {*} [options] Override http request option.
28247
29432
  * @throws {RequiredError}
28248
29433
  */
28249
- async regenerateWebhookSecretV1(webhookId: string, options?: RawAxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<MailV1WebhooksWebhookSecretResource>> {
28250
- const localVarAxiosArgs = await localVarAxiosParamCreator.regenerateWebhookSecretV1(webhookId, options);
28251
- const localVarOperationServerBasePath = operationServerMap['MailWebhooksApi.regenerateWebhookSecretV1']?.[0]?.url;
28252
- return (axios, basePath) => createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration)(axios, localVarOperationServerBasePath || basePath);
29434
+ getCampaignDetailsV1: async (profileUuid: string, campaignUuid: string, options: RawAxiosRequestConfig = {}): Promise<RequestArgs> => {
29435
+ // verify required parameter 'profileUuid' is not null or undefined
29436
+ assertParamExists('getCampaignDetailsV1', 'profileUuid', profileUuid)
29437
+ // verify required parameter 'campaignUuid' is not null or undefined
29438
+ assertParamExists('getCampaignDetailsV1', 'campaignUuid', campaignUuid)
29439
+ const localVarPath = `/api/reach/v1/profiles/{profileUuid}/campaigns/{campaignUuid}`
29440
+ .replace(`{${"profileUuid"}}`, encodeURIComponent(String(profileUuid)))
29441
+ .replace(`{${"campaignUuid"}}`, encodeURIComponent(String(campaignUuid)));
29442
+ // use dummy base URL string because the URL constructor only accepts absolute URLs.
29443
+ const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL);
29444
+ let baseOptions;
29445
+ if (configuration) {
29446
+ baseOptions = configuration.baseOptions;
29447
+ }
29448
+
29449
+ const localVarRequestOptions = { method: 'GET', ...baseOptions, ...options};
29450
+ const localVarHeaderParameter = {} as any;
29451
+ const localVarQueryParameter = {} as any;
29452
+
29453
+ // authentication apiToken required
29454
+ // http bearer authentication required
29455
+ await setBearerAuthToObject(localVarHeaderParameter, configuration)
29456
+
29457
+
29458
+
29459
+ setSearchParams(localVarUrlObj, localVarQueryParameter);
29460
+ let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
29461
+ localVarRequestOptions.headers = {...localVarHeaderParameter, ...headersFromBaseOptions, ...options.headers};
29462
+
29463
+ return {
29464
+ url: toPathString(localVarUrlObj),
29465
+ options: localVarRequestOptions,
29466
+ };
28253
29467
  },
28254
29468
  /**
28255
- * Send a test delivery to the webhook URL and return the result. Test requests are rate limited upstream.
28256
- * @summary Test webhook
28257
- * @param {string} webhookId Webhook ID (returned when the webhook was created)
29469
+ * Get the performance of a campaign: delivery, opens, clicks and unsubscribes, with the matching rates. Every count is unique contacts rather than raw events, so a contact who opens the same email five times is counted once.
29470
+ * @summary Get campaign performance
29471
+ * @param {string} profileUuid Profile uuid parameter
29472
+ * @param {string} campaignUuid Campaign uuid parameter
28258
29473
  * @param {*} [options] Override http request option.
28259
29474
  * @throws {RequiredError}
28260
29475
  */
28261
- async testWebhookV1(webhookId: string, options?: RawAxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<MailV1WebhooksWebhookTestResultResource>> {
28262
- const localVarAxiosArgs = await localVarAxiosParamCreator.testWebhookV1(webhookId, options);
28263
- const localVarOperationServerBasePath = operationServerMap['MailWebhooksApi.testWebhookV1']?.[0]?.url;
28264
- return (axios, basePath) => createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration)(axios, localVarOperationServerBasePath || basePath);
29476
+ getCampaignPerformanceV1: async (profileUuid: string, campaignUuid: string, options: RawAxiosRequestConfig = {}): Promise<RequestArgs> => {
29477
+ // verify required parameter 'profileUuid' is not null or undefined
29478
+ assertParamExists('getCampaignPerformanceV1', 'profileUuid', profileUuid)
29479
+ // verify required parameter 'campaignUuid' is not null or undefined
29480
+ assertParamExists('getCampaignPerformanceV1', 'campaignUuid', campaignUuid)
29481
+ const localVarPath = `/api/reach/v1/profiles/{profileUuid}/campaigns/{campaignUuid}/statistics`
29482
+ .replace(`{${"profileUuid"}}`, encodeURIComponent(String(profileUuid)))
29483
+ .replace(`{${"campaignUuid"}}`, encodeURIComponent(String(campaignUuid)));
29484
+ // use dummy base URL string because the URL constructor only accepts absolute URLs.
29485
+ const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL);
29486
+ let baseOptions;
29487
+ if (configuration) {
29488
+ baseOptions = configuration.baseOptions;
29489
+ }
29490
+
29491
+ const localVarRequestOptions = { method: 'GET', ...baseOptions, ...options};
29492
+ const localVarHeaderParameter = {} as any;
29493
+ const localVarQueryParameter = {} as any;
29494
+
29495
+ // authentication apiToken required
29496
+ // http bearer authentication required
29497
+ await setBearerAuthToObject(localVarHeaderParameter, configuration)
29498
+
29499
+
29500
+
29501
+ setSearchParams(localVarUrlObj, localVarQueryParameter);
29502
+ let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
29503
+ localVarRequestOptions.headers = {...localVarHeaderParameter, ...headersFromBaseOptions, ...options.headers};
29504
+
29505
+ return {
29506
+ url: toPathString(localVarUrlObj),
29507
+ options: localVarRequestOptions,
29508
+ };
28265
29509
  },
28266
29510
  /**
28267
- * Partially update a webhook. Only the fields included in the request body are changed; omitted fields retain their current values. Pass `\"description\": null` to clear the description.
28268
- * @summary Update webhook
28269
- * @param {string} webhookId Webhook ID (returned when the webhook was created)
28270
- * @param {MailV1SchemaUpdateWebhookRequestSchema} mailV1SchemaUpdateWebhookRequestSchema
29511
+ * Get a paginated list of the campaigns in a profile. Each campaign carries its headline engagement rates. Filter by status to find drafts, scheduled, sending or sent campaigns, keeping in mind that a fully sent campaign has the status `publish`. By default only regular campaigns are returned - pass `type` to get the emails sent by automations or the double opt-in confirmations instead.
29512
+ * @summary List campaigns
29513
+ * @param {string} profileUuid Profile uuid parameter
29514
+ * @param {ListCampaignsV1StatusEnum} [status] Filter campaigns by status. A fully sent campaign has the status &#x60;publish&#x60;. There is no &#x60;sent&#x60; status, and campaigns can be neither paused nor archived.
29515
+ * @param {ListCampaignsV1TypeEnum} [type] Filter campaigns by type. Defaults to &#x60;campaign&#x60;, which leaves out the emails sent by automations and the double opt-in confirmations.
29516
+ * @param {ListCampaignsV1SortDirectionEnum} [sortDirection] Order campaigns by creation date. Newest first unless set to &#x60;asc&#x60;.
29517
+ * @param {number} [page] Page number
29518
+ * @param {number} [perPage] Number of items per page
28271
29519
  * @param {*} [options] Override http request option.
28272
29520
  * @throws {RequiredError}
28273
29521
  */
28274
- async updateWebhookV1(webhookId: string, mailV1SchemaUpdateWebhookRequestSchema: MailV1SchemaUpdateWebhookRequestSchema, options?: RawAxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<MailV1WebhooksWebhookResource>> {
28275
- const localVarAxiosArgs = await localVarAxiosParamCreator.updateWebhookV1(webhookId, mailV1SchemaUpdateWebhookRequestSchema, options);
28276
- const localVarOperationServerBasePath = operationServerMap['MailWebhooksApi.updateWebhookV1']?.[0]?.url;
28277
- return (axios, basePath) => createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration)(axios, localVarOperationServerBasePath || basePath);
29522
+ listCampaignsV1: async (profileUuid: string, status?: ListCampaignsV1StatusEnum, type?: ListCampaignsV1TypeEnum, sortDirection?: ListCampaignsV1SortDirectionEnum, page?: number, perPage?: number, options: RawAxiosRequestConfig = {}): Promise<RequestArgs> => {
29523
+ // verify required parameter 'profileUuid' is not null or undefined
29524
+ assertParamExists('listCampaignsV1', 'profileUuid', profileUuid)
29525
+ const localVarPath = `/api/reach/v1/profiles/{profileUuid}/campaigns`
29526
+ .replace(`{${"profileUuid"}}`, encodeURIComponent(String(profileUuid)));
29527
+ // use dummy base URL string because the URL constructor only accepts absolute URLs.
29528
+ const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL);
29529
+ let baseOptions;
29530
+ if (configuration) {
29531
+ baseOptions = configuration.baseOptions;
29532
+ }
29533
+
29534
+ const localVarRequestOptions = { method: 'GET', ...baseOptions, ...options};
29535
+ const localVarHeaderParameter = {} as any;
29536
+ const localVarQueryParameter = {} as any;
29537
+
29538
+ // authentication apiToken required
29539
+ // http bearer authentication required
29540
+ await setBearerAuthToObject(localVarHeaderParameter, configuration)
29541
+
29542
+ if (status !== undefined) {
29543
+ localVarQueryParameter['status'] = status;
29544
+ }
29545
+
29546
+ if (type !== undefined) {
29547
+ localVarQueryParameter['type'] = type;
29548
+ }
29549
+
29550
+ if (sortDirection !== undefined) {
29551
+ localVarQueryParameter['sort_direction'] = sortDirection;
29552
+ }
29553
+
29554
+ if (page !== undefined) {
29555
+ localVarQueryParameter['page'] = page;
29556
+ }
29557
+
29558
+ if (perPage !== undefined) {
29559
+ localVarQueryParameter['per_page'] = perPage;
29560
+ }
29561
+
29562
+
29563
+
29564
+ setSearchParams(localVarUrlObj, localVarQueryParameter);
29565
+ let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
29566
+ localVarRequestOptions.headers = {...localVarHeaderParameter, ...headersFromBaseOptions, ...options.headers};
29567
+
29568
+ return {
29569
+ url: toPathString(localVarUrlObj),
29570
+ options: localVarRequestOptions,
29571
+ };
28278
29572
  },
28279
29573
  }
28280
29574
  };
28281
29575
 
28282
29576
  /**
28283
- * MailWebhooksApi - factory interface
29577
+ * ReachCampaignsApi - functional programming interface
28284
29578
  * @export
28285
29579
  */
28286
- export const MailWebhooksApiFactory = function (configuration?: Configuration, basePath?: string, axios?: AxiosInstance) {
28287
- const localVarFp = MailWebhooksApiFp(configuration)
29580
+ export const ReachCampaignsApiFp = function(configuration?: Configuration) {
29581
+ const localVarAxiosParamCreator = ReachCampaignsApiAxiosParamCreator(configuration)
28288
29582
  return {
28289
29583
  /**
28290
- * Create a webhook for the given mailbox. The generated secret is returned only in this response and is sent as a bearer token with every delivery.
28291
- * @summary Create webhook
28292
- * @param {string} mailboxId Mailbox resource ID
28293
- * @param {MailV1SchemaCreateWebhookRequestSchema} mailV1SchemaCreateWebhookRequestSchema
28294
- * @param {*} [options] Override http request option.
28295
- * @throws {RequiredError}
28296
- */
28297
- createWebhookV1(mailboxId: string, mailV1SchemaCreateWebhookRequestSchema: MailV1SchemaCreateWebhookRequestSchema, options?: RawAxiosRequestConfig): AxiosPromise<MailV1WebhooksWebhookCreatedResource> {
28298
- return localVarFp.createWebhookV1(mailboxId, mailV1SchemaCreateWebhookRequestSchema, options).then((request) => request(axios, basePath));
28299
- },
28300
- /**
28301
- * Permanently delete a webhook. This action cannot be undone. After deletion the URL no longer receives event notifications.
28302
- * @summary Delete webhook
28303
- * @param {string} webhookId Webhook ID (returned when the webhook was created)
28304
- * @param {*} [options] Override http request option.
28305
- * @throws {RequiredError}
28306
- */
28307
- deleteWebhookV1(webhookId: string, options?: RawAxiosRequestConfig): AxiosPromise<CommonSuccessEmptyResource> {
28308
- return localVarFp.deleteWebhookV1(webhookId, options).then((request) => request(axios, basePath));
28309
- },
28310
- /**
28311
- * Retrieve the details of a single webhook. The webhook secret is never included; it is returned only when a webhook is created or its secret is regenerated.
28312
- * @summary Get webhook
28313
- * @param {string} webhookId Webhook ID (returned when the webhook was created)
29584
+ * Get a single campaign with its sender, subject, template reference, targeting and delivery progress. This describes how the campaign was set up and how far it has got. For opens, clicks and unsubscribes use the campaign statistics endpoint.
29585
+ * @summary Get campaign details
29586
+ * @param {string} profileUuid Profile uuid parameter
29587
+ * @param {string} campaignUuid Campaign uuid parameter
28314
29588
  * @param {*} [options] Override http request option.
28315
29589
  * @throws {RequiredError}
28316
29590
  */
28317
- getWebhookV1(webhookId: string, options?: RawAxiosRequestConfig): AxiosPromise<MailV1WebhooksWebhookResource> {
28318
- return localVarFp.getWebhookV1(webhookId, options).then((request) => request(axios, basePath));
29591
+ async getCampaignDetailsV1(profileUuid: string, campaignUuid: string, options?: RawAxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<ReachV1CampaignsCampaignDetailsResource>> {
29592
+ const localVarAxiosArgs = await localVarAxiosParamCreator.getCampaignDetailsV1(profileUuid, campaignUuid, options);
29593
+ const localVarOperationServerBasePath = operationServerMap['ReachCampaignsApi.getCampaignDetailsV1']?.[0]?.url;
29594
+ return (axios, basePath) => createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration)(axios, localVarOperationServerBasePath || basePath);
28319
29595
  },
28320
29596
  /**
28321
- * Retrieve a paginated list of webhook delivery logs for the given mail order, including delivery outcome, duration, and retry counts. Supports filtering by mailbox.
28322
- * @summary List webhook delivery logs
28323
- * @param {string} orderId Order resource ID
28324
- * @param {string | null} [mailboxId] Filter by the mailbox resource ID the webhooks are attached to
28325
- * @param {number} [page] Page number
28326
- * @param {number} [perPage] Number of items per page
29597
+ * Get the performance of a campaign: delivery, opens, clicks and unsubscribes, with the matching rates. Every count is unique contacts rather than raw events, so a contact who opens the same email five times is counted once.
29598
+ * @summary Get campaign performance
29599
+ * @param {string} profileUuid Profile uuid parameter
29600
+ * @param {string} campaignUuid Campaign uuid parameter
28327
29601
  * @param {*} [options] Override http request option.
28328
29602
  * @throws {RequiredError}
28329
29603
  */
28330
- listWebhookDeliveryLogsV1(orderId: string, mailboxId?: string | null, page?: number, perPage?: number, options?: RawAxiosRequestConfig): AxiosPromise<MailListWebhookDeliveryLogsV1200Response> {
28331
- return localVarFp.listWebhookDeliveryLogsV1(orderId, mailboxId, page, perPage, options).then((request) => request(axios, basePath));
29604
+ async getCampaignPerformanceV1(profileUuid: string, campaignUuid: string, options?: RawAxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<ReachV1CampaignsCampaignStatisticsResource>> {
29605
+ const localVarAxiosArgs = await localVarAxiosParamCreator.getCampaignPerformanceV1(profileUuid, campaignUuid, options);
29606
+ const localVarOperationServerBasePath = operationServerMap['ReachCampaignsApi.getCampaignPerformanceV1']?.[0]?.url;
29607
+ return (axios, basePath) => createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration)(axios, localVarOperationServerBasePath || basePath);
28332
29608
  },
28333
29609
  /**
28334
- * Retrieve a paginated list of webhooks belonging to the given mail order. Supports filtering by mailbox and status. The webhook secret is never included; it is returned only when a webhook is created or its secret is regenerated.
28335
- * @summary List webhooks
28336
- * @param {string} orderId Order resource ID
28337
- * @param {string | null} [mailboxId] Filter by the mailbox resource ID the webhooks are attached to
28338
- * @param {ListWebhooksV1StatusEnum} [status] Filter webhooks by status
29610
+ * Get a paginated list of the campaigns in a profile. Each campaign carries its headline engagement rates. Filter by status to find drafts, scheduled, sending or sent campaigns, keeping in mind that a fully sent campaign has the status `publish`. By default only regular campaigns are returned - pass `type` to get the emails sent by automations or the double opt-in confirmations instead.
29611
+ * @summary List campaigns
29612
+ * @param {string} profileUuid Profile uuid parameter
29613
+ * @param {ListCampaignsV1StatusEnum} [status] Filter campaigns by status. A fully sent campaign has the status &#x60;publish&#x60;. There is no &#x60;sent&#x60; status, and campaigns can be neither paused nor archived.
29614
+ * @param {ListCampaignsV1TypeEnum} [type] Filter campaigns by type. Defaults to &#x60;campaign&#x60;, which leaves out the emails sent by automations and the double opt-in confirmations.
29615
+ * @param {ListCampaignsV1SortDirectionEnum} [sortDirection] Order campaigns by creation date. Newest first unless set to &#x60;asc&#x60;.
28339
29616
  * @param {number} [page] Page number
28340
29617
  * @param {number} [perPage] Number of items per page
28341
29618
  * @param {*} [options] Override http request option.
28342
29619
  * @throws {RequiredError}
28343
29620
  */
28344
- listWebhooksV1(orderId: string, mailboxId?: string | null, status?: ListWebhooksV1StatusEnum, page?: number, perPage?: number, options?: RawAxiosRequestConfig): AxiosPromise<MailListWebhooksV1200Response> {
28345
- return localVarFp.listWebhooksV1(orderId, mailboxId, status, page, perPage, options).then((request) => request(axios, basePath));
29621
+ async listCampaignsV1(profileUuid: string, status?: ListCampaignsV1StatusEnum, type?: ListCampaignsV1TypeEnum, sortDirection?: ListCampaignsV1SortDirectionEnum, page?: number, perPage?: number, options?: RawAxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<ReachListCampaignsV1200Response>> {
29622
+ const localVarAxiosArgs = await localVarAxiosParamCreator.listCampaignsV1(profileUuid, status, type, sortDirection, page, perPage, options);
29623
+ const localVarOperationServerBasePath = operationServerMap['ReachCampaignsApi.listCampaignsV1']?.[0]?.url;
29624
+ return (axios, basePath) => createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration)(axios, localVarOperationServerBasePath || basePath);
28346
29625
  },
29626
+ }
29627
+ };
29628
+
29629
+ /**
29630
+ * ReachCampaignsApi - factory interface
29631
+ * @export
29632
+ */
29633
+ export const ReachCampaignsApiFactory = function (configuration?: Configuration, basePath?: string, axios?: AxiosInstance) {
29634
+ const localVarFp = ReachCampaignsApiFp(configuration)
29635
+ return {
28347
29636
  /**
28348
- * Regenerate the secret of a webhook. The previous secret is immediately invalidated. The new secret is returned only in this response and is sent as a bearer token with every delivery.
28349
- * @summary Regenerate webhook secret
28350
- * @param {string} webhookId Webhook ID (returned when the webhook was created)
29637
+ * Get a single campaign with its sender, subject, template reference, targeting and delivery progress. This describes how the campaign was set up and how far it has got. For opens, clicks and unsubscribes use the campaign statistics endpoint.
29638
+ * @summary Get campaign details
29639
+ * @param {string} profileUuid Profile uuid parameter
29640
+ * @param {string} campaignUuid Campaign uuid parameter
28351
29641
  * @param {*} [options] Override http request option.
28352
29642
  * @throws {RequiredError}
28353
29643
  */
28354
- regenerateWebhookSecretV1(webhookId: string, options?: RawAxiosRequestConfig): AxiosPromise<MailV1WebhooksWebhookSecretResource> {
28355
- return localVarFp.regenerateWebhookSecretV1(webhookId, options).then((request) => request(axios, basePath));
29644
+ getCampaignDetailsV1(profileUuid: string, campaignUuid: string, options?: RawAxiosRequestConfig): AxiosPromise<ReachV1CampaignsCampaignDetailsResource> {
29645
+ return localVarFp.getCampaignDetailsV1(profileUuid, campaignUuid, options).then((request) => request(axios, basePath));
28356
29646
  },
28357
29647
  /**
28358
- * Send a test delivery to the webhook URL and return the result. Test requests are rate limited upstream.
28359
- * @summary Test webhook
28360
- * @param {string} webhookId Webhook ID (returned when the webhook was created)
29648
+ * Get the performance of a campaign: delivery, opens, clicks and unsubscribes, with the matching rates. Every count is unique contacts rather than raw events, so a contact who opens the same email five times is counted once.
29649
+ * @summary Get campaign performance
29650
+ * @param {string} profileUuid Profile uuid parameter
29651
+ * @param {string} campaignUuid Campaign uuid parameter
28361
29652
  * @param {*} [options] Override http request option.
28362
29653
  * @throws {RequiredError}
28363
29654
  */
28364
- testWebhookV1(webhookId: string, options?: RawAxiosRequestConfig): AxiosPromise<MailV1WebhooksWebhookTestResultResource> {
28365
- return localVarFp.testWebhookV1(webhookId, options).then((request) => request(axios, basePath));
29655
+ getCampaignPerformanceV1(profileUuid: string, campaignUuid: string, options?: RawAxiosRequestConfig): AxiosPromise<ReachV1CampaignsCampaignStatisticsResource> {
29656
+ return localVarFp.getCampaignPerformanceV1(profileUuid, campaignUuid, options).then((request) => request(axios, basePath));
28366
29657
  },
28367
29658
  /**
28368
- * Partially update a webhook. Only the fields included in the request body are changed; omitted fields retain their current values. Pass `\"description\": null` to clear the description.
28369
- * @summary Update webhook
28370
- * @param {string} webhookId Webhook ID (returned when the webhook was created)
28371
- * @param {MailV1SchemaUpdateWebhookRequestSchema} mailV1SchemaUpdateWebhookRequestSchema
29659
+ * Get a paginated list of the campaigns in a profile. Each campaign carries its headline engagement rates. Filter by status to find drafts, scheduled, sending or sent campaigns, keeping in mind that a fully sent campaign has the status `publish`. By default only regular campaigns are returned - pass `type` to get the emails sent by automations or the double opt-in confirmations instead.
29660
+ * @summary List campaigns
29661
+ * @param {string} profileUuid Profile uuid parameter
29662
+ * @param {ListCampaignsV1StatusEnum} [status] Filter campaigns by status. A fully sent campaign has the status &#x60;publish&#x60;. There is no &#x60;sent&#x60; status, and campaigns can be neither paused nor archived.
29663
+ * @param {ListCampaignsV1TypeEnum} [type] Filter campaigns by type. Defaults to &#x60;campaign&#x60;, which leaves out the emails sent by automations and the double opt-in confirmations.
29664
+ * @param {ListCampaignsV1SortDirectionEnum} [sortDirection] Order campaigns by creation date. Newest first unless set to &#x60;asc&#x60;.
29665
+ * @param {number} [page] Page number
29666
+ * @param {number} [perPage] Number of items per page
28372
29667
  * @param {*} [options] Override http request option.
28373
29668
  * @throws {RequiredError}
28374
29669
  */
28375
- updateWebhookV1(webhookId: string, mailV1SchemaUpdateWebhookRequestSchema: MailV1SchemaUpdateWebhookRequestSchema, options?: RawAxiosRequestConfig): AxiosPromise<MailV1WebhooksWebhookResource> {
28376
- return localVarFp.updateWebhookV1(webhookId, mailV1SchemaUpdateWebhookRequestSchema, options).then((request) => request(axios, basePath));
29670
+ listCampaignsV1(profileUuid: string, status?: ListCampaignsV1StatusEnum, type?: ListCampaignsV1TypeEnum, sortDirection?: ListCampaignsV1SortDirectionEnum, page?: number, perPage?: number, options?: RawAxiosRequestConfig): AxiosPromise<ReachListCampaignsV1200Response> {
29671
+ return localVarFp.listCampaignsV1(profileUuid, status, type, sortDirection, page, perPage, options).then((request) => request(axios, basePath));
28377
29672
  },
28378
29673
  };
28379
29674
  };
28380
29675
 
28381
29676
  /**
28382
- * MailWebhooksApi - object-oriented interface
29677
+ * ReachCampaignsApi - object-oriented interface
28383
29678
  * @export
28384
- * @class MailWebhooksApi
29679
+ * @class ReachCampaignsApi
28385
29680
  * @extends {BaseAPI}
28386
29681
  */
28387
- export class MailWebhooksApi extends BaseAPI {
28388
- /**
28389
- * Create a webhook for the given mailbox. The generated secret is returned only in this response and is sent as a bearer token with every delivery.
28390
- * @summary Create webhook
28391
- * @param {string} mailboxId Mailbox resource ID
28392
- * @param {MailV1SchemaCreateWebhookRequestSchema} mailV1SchemaCreateWebhookRequestSchema
28393
- * @param {*} [options] Override http request option.
28394
- * @throws {RequiredError}
28395
- * @memberof MailWebhooksApi
28396
- */
28397
- public createWebhookV1(mailboxId: string, mailV1SchemaCreateWebhookRequestSchema: MailV1SchemaCreateWebhookRequestSchema, options?: RawAxiosRequestConfig) {
28398
- return MailWebhooksApiFp(this.configuration).createWebhookV1(mailboxId, mailV1SchemaCreateWebhookRequestSchema, options).then((request) => request(this.axios, this.basePath));
28399
- }
28400
-
28401
- /**
28402
- * Permanently delete a webhook. This action cannot be undone. After deletion the URL no longer receives event notifications.
28403
- * @summary Delete webhook
28404
- * @param {string} webhookId Webhook ID (returned when the webhook was created)
28405
- * @param {*} [options] Override http request option.
28406
- * @throws {RequiredError}
28407
- * @memberof MailWebhooksApi
28408
- */
28409
- public deleteWebhookV1(webhookId: string, options?: RawAxiosRequestConfig) {
28410
- return MailWebhooksApiFp(this.configuration).deleteWebhookV1(webhookId, options).then((request) => request(this.axios, this.basePath));
28411
- }
28412
-
29682
+ export class ReachCampaignsApi extends BaseAPI {
28413
29683
  /**
28414
- * Retrieve the details of a single webhook. The webhook secret is never included; it is returned only when a webhook is created or its secret is regenerated.
28415
- * @summary Get webhook
28416
- * @param {string} webhookId Webhook ID (returned when the webhook was created)
29684
+ * Get a single campaign with its sender, subject, template reference, targeting and delivery progress. This describes how the campaign was set up and how far it has got. For opens, clicks and unsubscribes use the campaign statistics endpoint.
29685
+ * @summary Get campaign details
29686
+ * @param {string} profileUuid Profile uuid parameter
29687
+ * @param {string} campaignUuid Campaign uuid parameter
28417
29688
  * @param {*} [options] Override http request option.
28418
29689
  * @throws {RequiredError}
28419
- * @memberof MailWebhooksApi
29690
+ * @memberof ReachCampaignsApi
28420
29691
  */
28421
- public getWebhookV1(webhookId: string, options?: RawAxiosRequestConfig) {
28422
- return MailWebhooksApiFp(this.configuration).getWebhookV1(webhookId, options).then((request) => request(this.axios, this.basePath));
29692
+ public getCampaignDetailsV1(profileUuid: string, campaignUuid: string, options?: RawAxiosRequestConfig) {
29693
+ return ReachCampaignsApiFp(this.configuration).getCampaignDetailsV1(profileUuid, campaignUuid, options).then((request) => request(this.axios, this.basePath));
28423
29694
  }
28424
29695
 
28425
29696
  /**
28426
- * Retrieve a paginated list of webhook delivery logs for the given mail order, including delivery outcome, duration, and retry counts. Supports filtering by mailbox.
28427
- * @summary List webhook delivery logs
28428
- * @param {string} orderId Order resource ID
28429
- * @param {string | null} [mailboxId] Filter by the mailbox resource ID the webhooks are attached to
28430
- * @param {number} [page] Page number
28431
- * @param {number} [perPage] Number of items per page
29697
+ * Get the performance of a campaign: delivery, opens, clicks and unsubscribes, with the matching rates. Every count is unique contacts rather than raw events, so a contact who opens the same email five times is counted once.
29698
+ * @summary Get campaign performance
29699
+ * @param {string} profileUuid Profile uuid parameter
29700
+ * @param {string} campaignUuid Campaign uuid parameter
28432
29701
  * @param {*} [options] Override http request option.
28433
29702
  * @throws {RequiredError}
28434
- * @memberof MailWebhooksApi
29703
+ * @memberof ReachCampaignsApi
28435
29704
  */
28436
- public listWebhookDeliveryLogsV1(orderId: string, mailboxId?: string | null, page?: number, perPage?: number, options?: RawAxiosRequestConfig) {
28437
- return MailWebhooksApiFp(this.configuration).listWebhookDeliveryLogsV1(orderId, mailboxId, page, perPage, options).then((request) => request(this.axios, this.basePath));
29705
+ public getCampaignPerformanceV1(profileUuid: string, campaignUuid: string, options?: RawAxiosRequestConfig) {
29706
+ return ReachCampaignsApiFp(this.configuration).getCampaignPerformanceV1(profileUuid, campaignUuid, options).then((request) => request(this.axios, this.basePath));
28438
29707
  }
28439
29708
 
28440
29709
  /**
28441
- * Retrieve a paginated list of webhooks belonging to the given mail order. Supports filtering by mailbox and status. The webhook secret is never included; it is returned only when a webhook is created or its secret is regenerated.
28442
- * @summary List webhooks
28443
- * @param {string} orderId Order resource ID
28444
- * @param {string | null} [mailboxId] Filter by the mailbox resource ID the webhooks are attached to
28445
- * @param {ListWebhooksV1StatusEnum} [status] Filter webhooks by status
29710
+ * Get a paginated list of the campaigns in a profile. Each campaign carries its headline engagement rates. Filter by status to find drafts, scheduled, sending or sent campaigns, keeping in mind that a fully sent campaign has the status `publish`. By default only regular campaigns are returned - pass `type` to get the emails sent by automations or the double opt-in confirmations instead.
29711
+ * @summary List campaigns
29712
+ * @param {string} profileUuid Profile uuid parameter
29713
+ * @param {ListCampaignsV1StatusEnum} [status] Filter campaigns by status. A fully sent campaign has the status &#x60;publish&#x60;. There is no &#x60;sent&#x60; status, and campaigns can be neither paused nor archived.
29714
+ * @param {ListCampaignsV1TypeEnum} [type] Filter campaigns by type. Defaults to &#x60;campaign&#x60;, which leaves out the emails sent by automations and the double opt-in confirmations.
29715
+ * @param {ListCampaignsV1SortDirectionEnum} [sortDirection] Order campaigns by creation date. Newest first unless set to &#x60;asc&#x60;.
28446
29716
  * @param {number} [page] Page number
28447
29717
  * @param {number} [perPage] Number of items per page
28448
29718
  * @param {*} [options] Override http request option.
28449
29719
  * @throws {RequiredError}
28450
- * @memberof MailWebhooksApi
28451
- */
28452
- public listWebhooksV1(orderId: string, mailboxId?: string | null, status?: ListWebhooksV1StatusEnum, page?: number, perPage?: number, options?: RawAxiosRequestConfig) {
28453
- return MailWebhooksApiFp(this.configuration).listWebhooksV1(orderId, mailboxId, status, page, perPage, options).then((request) => request(this.axios, this.basePath));
28454
- }
28455
-
28456
- /**
28457
- * Regenerate the secret of a webhook. The previous secret is immediately invalidated. The new secret is returned only in this response and is sent as a bearer token with every delivery.
28458
- * @summary Regenerate webhook secret
28459
- * @param {string} webhookId Webhook ID (returned when the webhook was created)
28460
- * @param {*} [options] Override http request option.
28461
- * @throws {RequiredError}
28462
- * @memberof MailWebhooksApi
28463
- */
28464
- public regenerateWebhookSecretV1(webhookId: string, options?: RawAxiosRequestConfig) {
28465
- return MailWebhooksApiFp(this.configuration).regenerateWebhookSecretV1(webhookId, options).then((request) => request(this.axios, this.basePath));
28466
- }
28467
-
28468
- /**
28469
- * Send a test delivery to the webhook URL and return the result. Test requests are rate limited upstream.
28470
- * @summary Test webhook
28471
- * @param {string} webhookId Webhook ID (returned when the webhook was created)
28472
- * @param {*} [options] Override http request option.
28473
- * @throws {RequiredError}
28474
- * @memberof MailWebhooksApi
28475
- */
28476
- public testWebhookV1(webhookId: string, options?: RawAxiosRequestConfig) {
28477
- return MailWebhooksApiFp(this.configuration).testWebhookV1(webhookId, options).then((request) => request(this.axios, this.basePath));
28478
- }
28479
-
28480
- /**
28481
- * Partially update a webhook. Only the fields included in the request body are changed; omitted fields retain their current values. Pass `\"description\": null` to clear the description.
28482
- * @summary Update webhook
28483
- * @param {string} webhookId Webhook ID (returned when the webhook was created)
28484
- * @param {MailV1SchemaUpdateWebhookRequestSchema} mailV1SchemaUpdateWebhookRequestSchema
28485
- * @param {*} [options] Override http request option.
28486
- * @throws {RequiredError}
28487
- * @memberof MailWebhooksApi
29720
+ * @memberof ReachCampaignsApi
28488
29721
  */
28489
- public updateWebhookV1(webhookId: string, mailV1SchemaUpdateWebhookRequestSchema: MailV1SchemaUpdateWebhookRequestSchema, options?: RawAxiosRequestConfig) {
28490
- return MailWebhooksApiFp(this.configuration).updateWebhookV1(webhookId, mailV1SchemaUpdateWebhookRequestSchema, options).then((request) => request(this.axios, this.basePath));
29722
+ public listCampaignsV1(profileUuid: string, status?: ListCampaignsV1StatusEnum, type?: ListCampaignsV1TypeEnum, sortDirection?: ListCampaignsV1SortDirectionEnum, page?: number, perPage?: number, options?: RawAxiosRequestConfig) {
29723
+ return ReachCampaignsApiFp(this.configuration).listCampaignsV1(profileUuid, status, type, sortDirection, page, perPage, options).then((request) => request(this.axios, this.basePath));
28491
29724
  }
28492
29725
  }
28493
29726
 
28494
29727
  /**
28495
29728
  * @export
28496
29729
  */
28497
- export const ListWebhooksV1StatusEnum = {
28498
- Active: 'active',
28499
- Disabled: 'disabled',
28500
- Paused: 'paused'
29730
+ export const ListCampaignsV1StatusEnum = {
29731
+ Draft: 'draft',
29732
+ Scheduled: 'scheduled',
29733
+ Sending: 'sending',
29734
+ Publish: 'publish',
29735
+ Failed: 'failed'
28501
29736
  } as const;
28502
- export type ListWebhooksV1StatusEnum = typeof ListWebhooksV1StatusEnum[keyof typeof ListWebhooksV1StatusEnum];
29737
+ export type ListCampaignsV1StatusEnum = typeof ListCampaignsV1StatusEnum[keyof typeof ListCampaignsV1StatusEnum];
29738
+ /**
29739
+ * @export
29740
+ */
29741
+ export const ListCampaignsV1TypeEnum = {
29742
+ Campaign: 'campaign',
29743
+ Automation: 'automation',
29744
+ DoubleOptIn: 'double_opt_in'
29745
+ } as const;
29746
+ export type ListCampaignsV1TypeEnum = typeof ListCampaignsV1TypeEnum[keyof typeof ListCampaignsV1TypeEnum];
29747
+ /**
29748
+ * @export
29749
+ */
29750
+ export const ListCampaignsV1SortDirectionEnum = {
29751
+ Asc: 'asc',
29752
+ Desc: 'desc'
29753
+ } as const;
29754
+ export type ListCampaignsV1SortDirectionEnum = typeof ListCampaignsV1SortDirectionEnum[keyof typeof ListCampaignsV1SortDirectionEnum];
28503
29755
 
28504
29756
 
28505
29757
  /**