@prezly/sdk 25.1.0 → 25.2.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.
- package/dist/api/ApiClient.d.ts +4 -4
- package/dist/api/DeferredJobsApiClient.d.ts +4 -4
- package/dist/api/constants.cjs +1 -1
- package/dist/api/constants.js +1 -1
- package/dist/endpoints/Accounts/Client.d.ts +1 -1
- package/dist/endpoints/Billing/types.cjs +6 -6
- package/dist/endpoints/Billing/types.js +6 -6
- package/dist/endpoints/CampaignRecipients/Client.d.ts +1 -1
- package/dist/endpoints/Campaigns/Client.d.ts +8 -8
- package/dist/endpoints/ContactTagGroups/types.cjs +3 -3
- package/dist/endpoints/ContactTagGroups/types.js +3 -3
- package/dist/endpoints/ContactTags/Client.d.ts +4 -4
- package/dist/endpoints/Contacts/Client.d.ts +6 -6
- package/dist/endpoints/ContactsExports/Client.d.ts +2 -2
- package/dist/endpoints/CoverageIntegrations/Client.d.ts +3 -3
- package/dist/endpoints/NewsroomCategories/Client.d.ts +3 -3
- package/dist/endpoints/NewsroomGalleries/Client.d.ts +1 -1
- package/dist/endpoints/NewsroomLanguages/Client.d.ts +10 -10
- package/dist/endpoints/NewsroomPrivacyRequests/Client.d.ts +2 -2
- package/dist/endpoints/NewsroomThemes/Client.d.ts +1 -1
- package/dist/endpoints/NewsroomWebhooks/Client.d.ts +3 -3
- package/dist/endpoints/PricingTables/types.cjs +12 -12
- package/dist/endpoints/PricingTables/types.js +12 -12
- package/dist/endpoints/SenderAddresses/Client.d.ts +3 -3
- package/dist/endpoints/Stories/Client.d.ts +102 -102
- package/dist/endpoints/Stories/types.d.ts +2 -4
- package/dist/endpoints/Subscriptions/Client.d.ts +2 -2
- package/dist/endpoints/Subscriptions/types.cjs +3 -3
- package/dist/endpoints/Subscriptions/types.js +3 -3
- package/dist/endpoints/index.cjs +1 -1
- package/dist/http/lib.cjs +1 -1
- package/dist/http/types.cjs +6 -6
- package/dist/http/types.js +6 -6
- package/dist/types/BillingCycle.cjs +3 -3
- package/dist/types/BillingCycle.js +3 -3
- package/dist/types/Campaign.cjs +18 -18
- package/dist/types/Campaign.js +18 -18
- package/dist/types/Category.cjs +1 -0
- package/dist/types/Category.js +1 -0
- package/dist/types/Contact.cjs +18 -18
- package/dist/types/Contact.js +18 -18
- package/dist/types/ContactDuplicateSuggestion.cjs +3 -3
- package/dist/types/ContactDuplicateSuggestion.js +4 -3
- package/dist/types/ContactTag.cjs +2 -1
- package/dist/types/ContactTag.d.ts +1 -2
- package/dist/types/ContactTag.js +2 -1
- package/dist/types/ContactsExport.cjs +3 -3
- package/dist/types/ContactsExport.d.ts +1 -2
- package/dist/types/ContactsExport.js +3 -3
- package/dist/types/ContactsScope.cjs +3 -3
- package/dist/types/ContactsScope.js +3 -3
- package/dist/types/CoverageEntry.cjs +9 -9
- package/dist/types/CoverageEntry.js +9 -9
- package/dist/types/CoverageIntegration.cjs +3 -3
- package/dist/types/CoverageIntegration.d.ts +1 -2
- package/dist/types/CoverageIntegration.js +3 -3
- package/dist/types/CoverageIntegrationRun.cjs +3 -3
- package/dist/types/CoverageIntegrationRun.d.ts +1 -2
- package/dist/types/CoverageIntegrationRun.js +3 -3
- package/dist/types/Culture.cjs +3 -3
- package/dist/types/Culture.js +3 -3
- package/dist/types/Currency.cjs +3 -3
- package/dist/types/Currency.js +3 -3
- package/dist/types/EmailRecipient.cjs +6 -6
- package/dist/types/EmailRecipient.js +6 -6
- package/dist/types/JobState.cjs +3 -3
- package/dist/types/JobState.js +3 -3
- package/dist/types/License.cjs +12 -12
- package/dist/types/License.js +12 -12
- package/dist/types/Newsroom.cjs +12 -12
- package/dist/types/Newsroom.d.ts +3 -1
- package/dist/types/Newsroom.js +12 -12
- package/dist/types/NewsroomDomain.cjs +6 -6
- package/dist/types/NewsroomDomain.js +6 -6
- package/dist/types/NewsroomGallery.cjs +6 -6
- package/dist/types/NewsroomGallery.js +6 -6
- package/dist/types/NewsroomTheme.cjs +8 -7
- package/dist/types/NewsroomTheme.js +8 -7
- package/dist/types/NewsroomWebhook.cjs +3 -3
- package/dist/types/NewsroomWebhook.js +3 -3
- package/dist/types/NotificationSubscription.cjs +3 -3
- package/dist/types/NotificationSubscription.js +3 -3
- package/dist/types/Permissions.cjs +3 -3
- package/dist/types/Permissions.js +3 -3
- package/dist/types/Plan.cjs +10 -10
- package/dist/types/Plan.js +11 -11
- package/dist/types/Price.cjs +6 -6
- package/dist/types/Price.js +6 -6
- package/dist/types/PrivacyRequest.cjs +6 -6
- package/dist/types/PrivacyRequest.js +6 -6
- package/dist/types/SenderAddress.cjs +3 -3
- package/dist/types/SenderAddress.js +3 -3
- package/dist/types/SenderDomain.cjs +3 -3
- package/dist/types/SenderDomain.js +3 -3
- package/dist/types/SortOrder.cjs +3 -3
- package/dist/types/SortOrder.js +3 -3
- package/dist/types/Story.cjs +12 -12
- package/dist/types/Story.js +12 -12
- package/dist/types/User.cjs +6 -6
- package/dist/types/User.js +6 -6
- package/dist/types/common/Iso8601DateTime.cjs +1 -0
- package/dist/types/common/Iso8601DateTime.d.ts +1 -0
- package/dist/types/common/Iso8601DateTime.js +1 -0
- package/dist/types/common/Notification.cjs +3 -3
- package/dist/types/common/Notification.js +3 -3
- package/dist/types/common/OEmbedInfo.cjs +3 -3
- package/dist/types/common/OEmbedInfo.js +3 -3
- package/dist/types/common/Pagination.cjs +3 -3
- package/dist/types/common/Pagination.js +3 -3
- package/dist/types/common/Query.js +1 -0
- package/dist/types/common/index.cjs +11 -0
- package/dist/types/common/index.d.ts +1 -0
- package/dist/types/common/index.js +1 -0
- package/package.json +1 -1
|
@@ -15,110 +15,110 @@ type Exactly<Concrete, Abstract> = Concrete & Record<Exclude<keyof Concrete, key
|
|
|
15
15
|
type InferExtraFields<T> = T extends Required<IncludeOptions<infer I>> ? Pick<Story.ExtraFields, I> : unknown;
|
|
16
16
|
export type Client = ReturnType<typeof createClient>;
|
|
17
17
|
export declare function createClient(api: DeferredJobsApiClient): {
|
|
18
|
-
list: <Options extends ListOptions
|
|
19
|
-
search: <
|
|
18
|
+
list: <Options extends ListOptions<keyof Story.ExtraFields>>(options?: Exactly<Options, ListOptions<keyof Story.ExtraFields>> | undefined) => Promise<ListResponse<Story & InferExtraFields<Options>>>;
|
|
19
|
+
search: <Options_1 extends SearchOptions<keyof Story.ExtraFields>>(options?: Exactly<Options_1, SearchOptions<keyof Story.ExtraFields>> | undefined) => Promise<ListResponse<Story & InferExtraFields<Options_1>>>;
|
|
20
20
|
get: {
|
|
21
|
-
<
|
|
22
|
-
formats?: Formats;
|
|
23
|
-
}>(id: Story[
|
|
24
|
-
formats?: Formats;
|
|
25
|
-
}>): Promise<ExtendedStory & InferExtraFields<
|
|
26
|
-
<
|
|
27
|
-
formats?: Formats;
|
|
28
|
-
}>(ids: Story[
|
|
29
|
-
formats?: Formats;
|
|
30
|
-
}>): Promise<(ExtendedStory & InferExtraFields<
|
|
31
|
-
<
|
|
32
|
-
formats?: Formats;
|
|
33
|
-
}>(id: Story[
|
|
34
|
-
formats?: Formats;
|
|
35
|
-
}>): Promise<ExtendedStory & InferExtraFields<
|
|
36
|
-
<
|
|
37
|
-
formats?: Formats;
|
|
38
|
-
}>(ids: Story[
|
|
39
|
-
formats?: Formats;
|
|
40
|
-
}>): Promise<(ExtendedStory & InferExtraFields<
|
|
21
|
+
<Options_2 extends IncludeOptions<keyof Story.ExtraFields> & {
|
|
22
|
+
formats?: Formats | undefined;
|
|
23
|
+
}>(id: Story['uuid'], options?: Exactly<Options_2, IncludeOptions<keyof Story.ExtraFields> & {
|
|
24
|
+
formats?: Formats | undefined;
|
|
25
|
+
}> | undefined): Promise<ExtendedStory & InferExtraFields<Options_2>>;
|
|
26
|
+
<Options_3 extends IncludeOptions<keyof Story.ExtraFields> & {
|
|
27
|
+
formats?: Formats | undefined;
|
|
28
|
+
}>(ids: Story['uuid'][], options?: Exactly<Options_3, IncludeOptions<keyof Story.ExtraFields> & {
|
|
29
|
+
formats?: Formats | undefined;
|
|
30
|
+
}> | undefined): Promise<(ExtendedStory & InferExtraFields<Options_3>)[]>;
|
|
31
|
+
<Options_4 extends IncludeOptions<keyof Story.ExtraFields> & {
|
|
32
|
+
formats?: Formats | undefined;
|
|
33
|
+
}>(id: Story['id'] | Story['uuid'], options?: Exactly<Options_4, IncludeOptions<keyof Story.ExtraFields> & {
|
|
34
|
+
formats?: Formats | undefined;
|
|
35
|
+
}> | undefined): Promise<ExtendedStory & InferExtraFields<Options_4>>;
|
|
36
|
+
<Options_5 extends IncludeOptions<keyof Story.ExtraFields> & {
|
|
37
|
+
formats?: Formats | undefined;
|
|
38
|
+
}>(ids: Story['id'][], options?: Exactly<Options_5, IncludeOptions<keyof Story.ExtraFields> & {
|
|
39
|
+
formats?: Formats | undefined;
|
|
40
|
+
}> | undefined): Promise<(ExtendedStory & InferExtraFields<Options_5>)[]>;
|
|
41
41
|
};
|
|
42
|
-
getBySlug: <
|
|
43
|
-
formats?: Formats;
|
|
44
|
-
query?: Query;
|
|
45
|
-
}>(slug: Story[
|
|
46
|
-
formats?: Formats;
|
|
47
|
-
query?: Query;
|
|
48
|
-
}>) => Promise<ExtendedStory & InferExtraFields<
|
|
49
|
-
create: <
|
|
50
|
-
formats?: Formats;
|
|
51
|
-
force?: boolean;
|
|
52
|
-
}>(payload: CreateRequest, options?: Exactly<
|
|
53
|
-
formats?: Formats;
|
|
54
|
-
force?: boolean;
|
|
55
|
-
}>) => Promise<ExtendedStory & InferExtraFields<
|
|
56
|
-
duplicate: <
|
|
57
|
-
formats?: Formats;
|
|
58
|
-
}>(id: StoryId, options?: Exactly<
|
|
59
|
-
formats?: Formats;
|
|
60
|
-
}>) => Promise<ExtendedStory & InferExtraFields<
|
|
61
|
-
translate: <
|
|
62
|
-
formats?: Formats;
|
|
63
|
-
}>(id: StoryId, payload?: TranslateRequest, options?: Exactly<
|
|
64
|
-
formats?: Formats;
|
|
65
|
-
}>) => Promise<ExtendedStory & InferExtraFields<
|
|
66
|
-
move: <
|
|
67
|
-
formats?: Formats;
|
|
68
|
-
force?: boolean;
|
|
69
|
-
}>(id: StoryId, payload: MoveRequest, options?: Exactly<
|
|
70
|
-
formats?: Formats;
|
|
71
|
-
force?: boolean;
|
|
72
|
-
}>) => Promise<ChangeNewsroomSuccessResponse<ExtendedStory & InferExtraFields<
|
|
73
|
-
update: <
|
|
74
|
-
formats?: Formats;
|
|
75
|
-
force?: boolean;
|
|
76
|
-
}>(id: StoryId, payload: UpdateRequest, options?: Exactly<
|
|
77
|
-
formats?: Formats;
|
|
78
|
-
force?: boolean;
|
|
79
|
-
}>) => Promise<ExtendedStory & InferExtraFields<
|
|
80
|
-
autosave: <
|
|
81
|
-
formats?: Formats;
|
|
82
|
-
}>(id: StoryId, payload: AutosaveRequest, options?: Exactly<
|
|
83
|
-
formats?: Formats;
|
|
84
|
-
}>) => Promise<ExtendedStory & InferExtraFields<
|
|
85
|
-
revert: <
|
|
86
|
-
formats?: Formats;
|
|
87
|
-
}>(id: StoryId, payload?: RevertRequest, options?: Exactly<
|
|
88
|
-
formats?: Formats;
|
|
89
|
-
}>) => Promise<ExtendedStory & InferExtraFields<
|
|
90
|
-
publish: <
|
|
91
|
-
formats?: Formats;
|
|
92
|
-
}>(id: StoryId, payload?: PublishRequest, options?: Exactly<
|
|
93
|
-
formats?: Formats;
|
|
94
|
-
}>) => Promise<ExtendedStory & InferExtraFields<
|
|
95
|
-
unpublish: <
|
|
96
|
-
formats?: Formats;
|
|
97
|
-
}>(id: StoryId, payload?: UnpublishRequest, options?: Exactly<
|
|
98
|
-
formats?: Formats;
|
|
99
|
-
}>) => Promise<ExtendedStory & InferExtraFields<
|
|
100
|
-
schedule: <
|
|
101
|
-
formats?: Formats;
|
|
102
|
-
}>(id: StoryId, payload?: ScheduleRequest, options?: Exactly<
|
|
103
|
-
formats?: Formats;
|
|
104
|
-
}>) => Promise<ExtendedStory & InferExtraFields<
|
|
105
|
-
unschedule: <
|
|
106
|
-
formats?: Formats;
|
|
107
|
-
}>(id: StoryId, payload?: UnscheduleRequest, options?: Exactly<
|
|
108
|
-
formats?: Formats;
|
|
109
|
-
}>) => Promise<ExtendedStory & InferExtraFields<
|
|
110
|
-
pin: <
|
|
111
|
-
formats?: Formats;
|
|
112
|
-
force?: boolean;
|
|
113
|
-
}>(id: StoryId, options?: Exactly<
|
|
114
|
-
formats?: Formats;
|
|
115
|
-
force?: boolean;
|
|
116
|
-
}>) => Promise<ExtendedStory & InferExtraFields<
|
|
117
|
-
unpin: <
|
|
118
|
-
formats?: Formats;
|
|
119
|
-
}>(id: StoryId, options?: Exactly<
|
|
120
|
-
formats?: Formats;
|
|
121
|
-
}>) => Promise<ExtendedStory & InferExtraFields<
|
|
42
|
+
getBySlug: <Options_6 extends IncludeOptions<keyof Story.ExtraFields> & {
|
|
43
|
+
formats?: Formats | undefined;
|
|
44
|
+
query?: Query | undefined;
|
|
45
|
+
}>(slug: Story['slug'], options?: Exactly<Options_6, IncludeOptions<keyof Story.ExtraFields> & {
|
|
46
|
+
formats?: Formats | undefined;
|
|
47
|
+
query?: Query | undefined;
|
|
48
|
+
}> | undefined) => Promise<ExtendedStory & InferExtraFields<Options_6>>;
|
|
49
|
+
create: <Options_7 extends IncludeOptions<keyof Story.ExtraFields> & {
|
|
50
|
+
formats?: Formats | undefined;
|
|
51
|
+
force?: boolean | undefined;
|
|
52
|
+
}>(payload: CreateRequest, options?: Exactly<Options_7, IncludeOptions<keyof Story.ExtraFields> & {
|
|
53
|
+
formats?: Formats | undefined;
|
|
54
|
+
force?: boolean | undefined;
|
|
55
|
+
}> | undefined) => Promise<ExtendedStory & InferExtraFields<Options_7>>;
|
|
56
|
+
duplicate: <Options_8 extends IncludeOptions<keyof Story.ExtraFields> & {
|
|
57
|
+
formats?: Formats | undefined;
|
|
58
|
+
}>(id: StoryId, options?: Exactly<Options_8, IncludeOptions<keyof Story.ExtraFields> & {
|
|
59
|
+
formats?: Formats | undefined;
|
|
60
|
+
}> | undefined) => Promise<ExtendedStory & InferExtraFields<Options_8>>;
|
|
61
|
+
translate: <Options_9 extends IncludeOptions<keyof Story.ExtraFields> & {
|
|
62
|
+
formats?: Formats | undefined;
|
|
63
|
+
}>(id: StoryId, payload?: TranslateRequest, options?: Exactly<Options_9, IncludeOptions<keyof Story.ExtraFields> & {
|
|
64
|
+
formats?: Formats | undefined;
|
|
65
|
+
}> | undefined) => Promise<ExtendedStory & InferExtraFields<Options_9>>;
|
|
66
|
+
move: <Options_10 extends IncludeOptions<keyof Story.ExtraFields> & {
|
|
67
|
+
formats?: Formats | undefined;
|
|
68
|
+
force?: boolean | undefined;
|
|
69
|
+
}>(id: StoryId, payload: MoveRequest, options?: Exactly<Options_10, IncludeOptions<keyof Story.ExtraFields> & {
|
|
70
|
+
formats?: Formats | undefined;
|
|
71
|
+
force?: boolean | undefined;
|
|
72
|
+
}> | undefined) => Promise<ChangeNewsroomUnsafeResponse | ChangeNewsroomSuccessResponse<ExtendedStory & InferExtraFields<Options_10>>>;
|
|
73
|
+
update: <Options_11 extends IncludeOptions<keyof Story.ExtraFields> & {
|
|
74
|
+
formats?: Formats | undefined;
|
|
75
|
+
force?: boolean | undefined;
|
|
76
|
+
}>(id: StoryId, payload: UpdateRequest, options?: Exactly<Options_11, IncludeOptions<keyof Story.ExtraFields> & {
|
|
77
|
+
formats?: Formats | undefined;
|
|
78
|
+
force?: boolean | undefined;
|
|
79
|
+
}> | undefined) => Promise<ExtendedStory & InferExtraFields<Options_11>>;
|
|
80
|
+
autosave: <Options_12 extends IncludeOptions<keyof Story.ExtraFields> & {
|
|
81
|
+
formats?: Formats | undefined;
|
|
82
|
+
}>(id: StoryId, payload: AutosaveRequest, options?: Exactly<Options_12, IncludeOptions<keyof Story.ExtraFields> & {
|
|
83
|
+
formats?: Formats | undefined;
|
|
84
|
+
}> | undefined) => Promise<ExtendedStory & InferExtraFields<Options_12>>;
|
|
85
|
+
revert: <Options_13 extends IncludeOptions<keyof Story.ExtraFields> & {
|
|
86
|
+
formats?: Formats | undefined;
|
|
87
|
+
}>(id: StoryId, payload?: RevertRequest, options?: Exactly<Options_13, IncludeOptions<keyof Story.ExtraFields> & {
|
|
88
|
+
formats?: Formats | undefined;
|
|
89
|
+
}> | undefined) => Promise<ExtendedStory & InferExtraFields<Options_13>>;
|
|
90
|
+
publish: <Options_14 extends IncludeOptions<keyof Story.ExtraFields> & {
|
|
91
|
+
formats?: Formats | undefined;
|
|
92
|
+
}>(id: StoryId, payload?: PublishRequest, options?: Exactly<Options_14, IncludeOptions<keyof Story.ExtraFields> & {
|
|
93
|
+
formats?: Formats | undefined;
|
|
94
|
+
}> | undefined) => Promise<ExtendedStory & InferExtraFields<Options_14>>;
|
|
95
|
+
unpublish: <Options_15 extends IncludeOptions<keyof Story.ExtraFields> & {
|
|
96
|
+
formats?: Formats | undefined;
|
|
97
|
+
}>(id: StoryId, payload?: UnpublishRequest, options?: Exactly<Options_15, IncludeOptions<keyof Story.ExtraFields> & {
|
|
98
|
+
formats?: Formats | undefined;
|
|
99
|
+
}> | undefined) => Promise<ExtendedStory & InferExtraFields<Options_15>>;
|
|
100
|
+
schedule: <Options_16 extends IncludeOptions<keyof Story.ExtraFields> & {
|
|
101
|
+
formats?: Formats | undefined;
|
|
102
|
+
}>(id: StoryId, payload?: ScheduleRequest, options?: Exactly<Options_16, IncludeOptions<keyof Story.ExtraFields> & {
|
|
103
|
+
formats?: Formats | undefined;
|
|
104
|
+
}> | undefined) => Promise<ExtendedStory & InferExtraFields<Options_16>>;
|
|
105
|
+
unschedule: <Options_17 extends IncludeOptions<keyof Story.ExtraFields> & {
|
|
106
|
+
formats?: Formats | undefined;
|
|
107
|
+
}>(id: StoryId, payload?: UnscheduleRequest, options?: Exactly<Options_17, IncludeOptions<keyof Story.ExtraFields> & {
|
|
108
|
+
formats?: Formats | undefined;
|
|
109
|
+
}> | undefined) => Promise<ExtendedStory & InferExtraFields<Options_17>>;
|
|
110
|
+
pin: <Options_18 extends IncludeOptions<keyof Story.ExtraFields> & {
|
|
111
|
+
formats?: Formats | undefined;
|
|
112
|
+
force?: boolean | undefined;
|
|
113
|
+
}>(id: StoryId, options?: Exactly<Options_18, IncludeOptions<keyof Story.ExtraFields> & {
|
|
114
|
+
formats?: Formats | undefined;
|
|
115
|
+
force?: boolean | undefined;
|
|
116
|
+
}> | undefined) => Promise<ExtendedStory & InferExtraFields<Options_18>>;
|
|
117
|
+
unpin: <Options_19 extends IncludeOptions<keyof Story.ExtraFields> & {
|
|
118
|
+
formats?: Formats | undefined;
|
|
119
|
+
}>(id: StoryId, options?: Exactly<Options_19, IncludeOptions<keyof Story.ExtraFields> & {
|
|
120
|
+
formats?: Formats | undefined;
|
|
121
|
+
}> | undefined) => Promise<ExtendedStory & InferExtraFields<Options_19>>;
|
|
122
122
|
delete: (id: StoryId) => Promise<void>;
|
|
123
123
|
bulkDelete: (selector: StoriesBulkSelector) => ProgressPromise<{
|
|
124
124
|
records_deleted_number: number;
|
|
@@ -254,8 +254,6 @@ export interface ChangeNewsroomUnsafeResponse {
|
|
|
254
254
|
message: string;
|
|
255
255
|
warnings: ChangeNewsroomWarning[];
|
|
256
256
|
}
|
|
257
|
-
declare const
|
|
258
|
-
declare const
|
|
259
|
-
export declare const ALL_EXTRA_FIELDS: (keyof typeof ALL_EXTRA_FIELDS_SHAPE)[];
|
|
260
|
-
export declare const EXTENDED_STORY_INCLUDED_EXTRA_FIELDS: (keyof typeof EXTENDED_STORY_INCLUDED_EXTRA_FIELDS_SHAPE)[];
|
|
257
|
+
export declare const ALL_EXTRA_FIELDS: (keyof Story.ExtraFields)[];
|
|
258
|
+
export declare const EXTENDED_STORY_INCLUDED_EXTRA_FIELDS: ("content" | "preview_image" | "thumbnail_image" | "header_image" | "social_image" | "social_text" | "tag_names" | "attached_gallery_content" | "referenced_entities")[];
|
|
261
259
|
export {};
|
|
@@ -7,7 +7,7 @@ export declare function createClient(api: DeferredJobsApiClient): {
|
|
|
7
7
|
subscribeToNewsroom: <Type extends Contact.Type>(newsroomId: NewsroomId, payload: SubscribeRequest<Type>) => Promise<EmailSubscription>;
|
|
8
8
|
unsubscribeFromNewsroom: (newsroomId: NewsroomId, payload: UnsubscribeRequest) => Promise<EmailSubscription>;
|
|
9
9
|
unsubscribeFromLicense: (payload: UnsubscribeRequest) => Promise<EmailSubscription>;
|
|
10
|
-
updateNewsroomUnsubscribeDetails: (newsroomId: NewsroomId, subscriptionId: EmailSubscription[
|
|
11
|
-
updateLicenseUnsubscribeDetails: (subscriptionId: EmailSubscription[
|
|
10
|
+
updateNewsroomUnsubscribeDetails: (newsroomId: NewsroomId, subscriptionId: EmailSubscription['id'], payload: UpdateUnsubscribeDetailsRequest) => Promise<EmailSubscription>;
|
|
11
|
+
updateLicenseUnsubscribeDetails: (subscriptionId: EmailSubscription['id'], payload: UpdateUnsubscribeDetailsRequest) => Promise<EmailSubscription>;
|
|
12
12
|
};
|
|
13
13
|
export {};
|
|
@@ -4,11 +4,11 @@ Object.defineProperty(exports, "__esModule", {
|
|
|
4
4
|
value: true
|
|
5
5
|
});
|
|
6
6
|
exports.UnsubscribeReason = void 0;
|
|
7
|
-
let UnsubscribeReason = exports.UnsubscribeReason =
|
|
7
|
+
let UnsubscribeReason = exports.UnsubscribeReason = void 0;
|
|
8
|
+
(function (UnsubscribeReason) {
|
|
8
9
|
UnsubscribeReason["UNKNOWN"] = "unknown";
|
|
9
10
|
UnsubscribeReason["UNWANTED"] = "unwanted";
|
|
10
11
|
UnsubscribeReason["SPAM"] = "spam";
|
|
11
12
|
UnsubscribeReason["NEVER_SIGNED_UP"] = "never_signed_up";
|
|
12
13
|
UnsubscribeReason["OTHER"] = "other";
|
|
13
|
-
|
|
14
|
-
}({});
|
|
14
|
+
})(UnsubscribeReason || (exports.UnsubscribeReason = UnsubscribeReason = {}));
|
|
@@ -1,8 +1,8 @@
|
|
|
1
|
-
export let UnsubscribeReason
|
|
1
|
+
export let UnsubscribeReason;
|
|
2
|
+
(function (UnsubscribeReason) {
|
|
2
3
|
UnsubscribeReason["UNKNOWN"] = "unknown";
|
|
3
4
|
UnsubscribeReason["UNWANTED"] = "unwanted";
|
|
4
5
|
UnsubscribeReason["SPAM"] = "spam";
|
|
5
6
|
UnsubscribeReason["NEVER_SIGNED_UP"] = "never_signed_up";
|
|
6
7
|
UnsubscribeReason["OTHER"] = "other";
|
|
7
|
-
|
|
8
|
-
}({});
|
|
8
|
+
})(UnsubscribeReason || (UnsubscribeReason = {}));
|
package/dist/endpoints/index.cjs
CHANGED
|
@@ -63,4 +63,4 @@ exports.Subscriptions = _Subscriptions;
|
|
|
63
63
|
var _NotificationSubscriptions = _interopRequireWildcard(require("./NotificationSubscriptions/index.cjs"));
|
|
64
64
|
exports.NotificationSubscriptions = _NotificationSubscriptions;
|
|
65
65
|
function _getRequireWildcardCache(e) { if ("function" != typeof WeakMap) return null; var r = new WeakMap(), t = new WeakMap(); return (_getRequireWildcardCache = function (e) { return e ? t : r; })(e); }
|
|
66
|
-
function _interopRequireWildcard(e, r) { if (!r && e && e.__esModule) return e; if (null === e || "object" != typeof e && "function" != typeof e) return { default: e }; var t = _getRequireWildcardCache(r); if (t && t.has(e)) return t.get(e); var n = { __proto__: null }, a = Object.defineProperty && Object.getOwnPropertyDescriptor; for (var u in e) if ("default" !== u &&
|
|
66
|
+
function _interopRequireWildcard(e, r) { if (!r && e && e.__esModule) return e; if (null === e || "object" != typeof e && "function" != typeof e) return { default: e }; var t = _getRequireWildcardCache(r); if (t && t.has(e)) return t.get(e); var n = { __proto__: null }, a = Object.defineProperty && Object.getOwnPropertyDescriptor; for (var u in e) if ("default" !== u && Object.prototype.hasOwnProperty.call(e, u)) { var i = a ? Object.getOwnPropertyDescriptor(e, u) : null; i && (i.get || i.set) ? Object.defineProperty(n, u, i) : n[u] = e[u]; } return n.default = e, t && t.set(e, n), n; }
|
package/dist/http/lib.cjs
CHANGED
|
@@ -6,7 +6,7 @@ Object.defineProperty(exports, "__esModule", {
|
|
|
6
6
|
exports.createUrlWithQuery = createUrlWithQuery;
|
|
7
7
|
exports.isDeferredJobResponse = isDeferredJobResponse;
|
|
8
8
|
var _queryString = _interopRequireDefault(require("query-string"));
|
|
9
|
-
function _interopRequireDefault(
|
|
9
|
+
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
|
|
10
10
|
function parseUrlParams(query) {
|
|
11
11
|
return _queryString.default.parse(query, {
|
|
12
12
|
arrayFormat: 'bracket'
|
package/dist/http/types.cjs
CHANGED
|
@@ -4,20 +4,20 @@ Object.defineProperty(exports, "__esModule", {
|
|
|
4
4
|
value: true
|
|
5
5
|
});
|
|
6
6
|
exports.Method = exports.HttpCodes = void 0;
|
|
7
|
-
let HttpCodes = exports.HttpCodes =
|
|
7
|
+
let HttpCodes = exports.HttpCodes = void 0;
|
|
8
|
+
(function (HttpCodes) {
|
|
8
9
|
HttpCodes[HttpCodes["ACCEPTED"] = 202] = "ACCEPTED";
|
|
9
10
|
HttpCodes[HttpCodes["NO_CONTENT"] = 204] = "NO_CONTENT";
|
|
10
11
|
HttpCodes[HttpCodes["NOT_FOUND"] = 404] = "NOT_FOUND";
|
|
11
12
|
HttpCodes[HttpCodes["CONFLICT"] = 409] = "CONFLICT";
|
|
12
13
|
HttpCodes[HttpCodes["GONE"] = 410] = "GONE";
|
|
13
14
|
HttpCodes[HttpCodes["PRECONDITION_FAILED"] = 412] = "PRECONDITION_FAILED";
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
15
|
+
})(HttpCodes || (exports.HttpCodes = HttpCodes = {}));
|
|
16
|
+
let Method = exports.Method = void 0;
|
|
17
|
+
(function (Method) {
|
|
17
18
|
Method["DELETE"] = "DELETE";
|
|
18
19
|
Method["GET"] = "GET";
|
|
19
20
|
Method["PATCH"] = "PATCH";
|
|
20
21
|
Method["POST"] = "POST";
|
|
21
22
|
Method["PUT"] = "PUT";
|
|
22
|
-
|
|
23
|
-
}({});
|
|
23
|
+
})(Method || (exports.Method = Method = {}));
|
package/dist/http/types.js
CHANGED
|
@@ -1,17 +1,17 @@
|
|
|
1
|
-
export let HttpCodes
|
|
1
|
+
export let HttpCodes;
|
|
2
|
+
(function (HttpCodes) {
|
|
2
3
|
HttpCodes[HttpCodes["ACCEPTED"] = 202] = "ACCEPTED";
|
|
3
4
|
HttpCodes[HttpCodes["NO_CONTENT"] = 204] = "NO_CONTENT";
|
|
4
5
|
HttpCodes[HttpCodes["NOT_FOUND"] = 404] = "NOT_FOUND";
|
|
5
6
|
HttpCodes[HttpCodes["CONFLICT"] = 409] = "CONFLICT";
|
|
6
7
|
HttpCodes[HttpCodes["GONE"] = 410] = "GONE";
|
|
7
8
|
HttpCodes[HttpCodes["PRECONDITION_FAILED"] = 412] = "PRECONDITION_FAILED";
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
9
|
+
})(HttpCodes || (HttpCodes = {}));
|
|
10
|
+
export let Method;
|
|
11
|
+
(function (Method) {
|
|
11
12
|
Method["DELETE"] = "DELETE";
|
|
12
13
|
Method["GET"] = "GET";
|
|
13
14
|
Method["PATCH"] = "PATCH";
|
|
14
15
|
Method["POST"] = "POST";
|
|
15
16
|
Method["PUT"] = "PUT";
|
|
16
|
-
|
|
17
|
-
}({});
|
|
17
|
+
})(Method || (Method = {}));
|
|
@@ -4,8 +4,8 @@ Object.defineProperty(exports, "__esModule", {
|
|
|
4
4
|
value: true
|
|
5
5
|
});
|
|
6
6
|
exports.BillingCycle = void 0;
|
|
7
|
-
let BillingCycle = exports.BillingCycle =
|
|
7
|
+
let BillingCycle = exports.BillingCycle = void 0;
|
|
8
|
+
(function (BillingCycle) {
|
|
8
9
|
BillingCycle["YEAR"] = "year";
|
|
9
10
|
BillingCycle["MONTH"] = "month";
|
|
10
|
-
|
|
11
|
-
}({});
|
|
11
|
+
})(BillingCycle || (exports.BillingCycle = BillingCycle = {}));
|
package/dist/types/Campaign.cjs
CHANGED
|
@@ -8,48 +8,48 @@ var _SenderDomain = require("./SenderDomain.cjs");
|
|
|
8
8
|
let Campaign = exports.Campaign = void 0;
|
|
9
9
|
(function (_Campaign) {
|
|
10
10
|
const SenderDomainVerificationFlow = _Campaign.SenderDomainVerificationFlow = _SenderDomain.SenderDomain.VerificationFlowVersion;
|
|
11
|
-
let LifecycleStatus
|
|
11
|
+
let LifecycleStatus;
|
|
12
|
+
(function (LifecycleStatus) {
|
|
12
13
|
LifecycleStatus["DRAFT"] = "draft";
|
|
13
14
|
LifecycleStatus["SCHEDULED"] = "scheduled";
|
|
14
15
|
LifecycleStatus["PENDING"] = "pending";
|
|
15
16
|
LifecycleStatus["SENT"] = "sent";
|
|
16
|
-
|
|
17
|
-
}({});
|
|
17
|
+
})(LifecycleStatus || (LifecycleStatus = {}));
|
|
18
18
|
_Campaign.LifecycleStatus = LifecycleStatus;
|
|
19
|
-
let StoryAlignment
|
|
19
|
+
let StoryAlignment;
|
|
20
|
+
(function (StoryAlignment) {
|
|
20
21
|
StoryAlignment["CENTER"] = "center";
|
|
21
22
|
StoryAlignment["LEFT"] = "left";
|
|
22
23
|
StoryAlignment["RIGHT"] = "right";
|
|
23
|
-
|
|
24
|
-
}({});
|
|
24
|
+
})(StoryAlignment || (StoryAlignment = {}));
|
|
25
25
|
_Campaign.StoryAlignment = StoryAlignment;
|
|
26
|
-
let StoryAppearance
|
|
26
|
+
let StoryAppearance;
|
|
27
|
+
(function (StoryAppearance) {
|
|
27
28
|
StoryAppearance["INTRO"] = "intro";
|
|
28
29
|
StoryAppearance["FULL"] = "full";
|
|
29
|
-
|
|
30
|
-
}({});
|
|
30
|
+
})(StoryAppearance || (StoryAppearance = {}));
|
|
31
31
|
_Campaign.StoryAppearance = StoryAppearance;
|
|
32
|
-
let StoryHeaderFooter
|
|
32
|
+
let StoryHeaderFooter;
|
|
33
|
+
(function (StoryHeaderFooter) {
|
|
33
34
|
StoryHeaderFooter["NONE"] = "none";
|
|
34
35
|
StoryHeaderFooter["STANDARD"] = "standard";
|
|
35
36
|
StoryHeaderFooter["FULL"] = "full";
|
|
36
|
-
|
|
37
|
-
}({});
|
|
37
|
+
})(StoryHeaderFooter || (StoryHeaderFooter = {}));
|
|
38
38
|
_Campaign.StoryHeaderFooter = StoryHeaderFooter;
|
|
39
|
-
let SenderDomainVerificationStatus
|
|
39
|
+
let SenderDomainVerificationStatus;
|
|
40
|
+
(function (SenderDomainVerificationStatus) {
|
|
40
41
|
SenderDomainVerificationStatus["UNKNOWN"] = "unknown";
|
|
41
42
|
SenderDomainVerificationStatus["VALID"] = "valid";
|
|
42
43
|
SenderDomainVerificationStatus["INVALID"] = "invalid";
|
|
43
44
|
SenderDomainVerificationStatus["NOT_APPLICABLE"] = "not-applicable";
|
|
44
|
-
|
|
45
|
-
}({});
|
|
45
|
+
})(SenderDomainVerificationStatus || (SenderDomainVerificationStatus = {}));
|
|
46
46
|
_Campaign.SenderDomainVerificationStatus = SenderDomainVerificationStatus;
|
|
47
|
-
let ClickTrackingVersion
|
|
47
|
+
let ClickTrackingVersion;
|
|
48
|
+
(function (ClickTrackingVersion) {
|
|
48
49
|
ClickTrackingVersion[ClickTrackingVersion["DEPRECATED"] = 1] = "DEPRECATED";
|
|
49
50
|
ClickTrackingVersion[ClickTrackingVersion["ENHANCED"] = 2] = "ENHANCED";
|
|
50
51
|
ClickTrackingVersion[ClickTrackingVersion["INHOUSE"] = 3] = "INHOUSE";
|
|
51
|
-
|
|
52
|
-
}({});
|
|
52
|
+
})(ClickTrackingVersion || (ClickTrackingVersion = {}));
|
|
53
53
|
_Campaign.ClickTrackingVersion = ClickTrackingVersion;
|
|
54
54
|
function isDraft(arg) {
|
|
55
55
|
if (typeof arg === 'object') {
|
package/dist/types/Campaign.js
CHANGED
|
@@ -2,48 +2,48 @@ import { SenderDomain } from "./SenderDomain.js";
|
|
|
2
2
|
export let Campaign;
|
|
3
3
|
(function (_Campaign) {
|
|
4
4
|
const SenderDomainVerificationFlow = _Campaign.SenderDomainVerificationFlow = SenderDomain.VerificationFlowVersion;
|
|
5
|
-
let LifecycleStatus
|
|
5
|
+
let LifecycleStatus;
|
|
6
|
+
(function (LifecycleStatus) {
|
|
6
7
|
LifecycleStatus["DRAFT"] = "draft";
|
|
7
8
|
LifecycleStatus["SCHEDULED"] = "scheduled";
|
|
8
9
|
LifecycleStatus["PENDING"] = "pending";
|
|
9
10
|
LifecycleStatus["SENT"] = "sent";
|
|
10
|
-
|
|
11
|
-
}({});
|
|
11
|
+
})(LifecycleStatus || (LifecycleStatus = {}));
|
|
12
12
|
_Campaign.LifecycleStatus = LifecycleStatus;
|
|
13
|
-
let StoryAlignment
|
|
13
|
+
let StoryAlignment;
|
|
14
|
+
(function (StoryAlignment) {
|
|
14
15
|
StoryAlignment["CENTER"] = "center";
|
|
15
16
|
StoryAlignment["LEFT"] = "left";
|
|
16
17
|
StoryAlignment["RIGHT"] = "right";
|
|
17
|
-
|
|
18
|
-
}({});
|
|
18
|
+
})(StoryAlignment || (StoryAlignment = {}));
|
|
19
19
|
_Campaign.StoryAlignment = StoryAlignment;
|
|
20
|
-
let StoryAppearance
|
|
20
|
+
let StoryAppearance;
|
|
21
|
+
(function (StoryAppearance) {
|
|
21
22
|
StoryAppearance["INTRO"] = "intro";
|
|
22
23
|
StoryAppearance["FULL"] = "full";
|
|
23
|
-
|
|
24
|
-
}({});
|
|
24
|
+
})(StoryAppearance || (StoryAppearance = {}));
|
|
25
25
|
_Campaign.StoryAppearance = StoryAppearance;
|
|
26
|
-
let StoryHeaderFooter
|
|
26
|
+
let StoryHeaderFooter;
|
|
27
|
+
(function (StoryHeaderFooter) {
|
|
27
28
|
StoryHeaderFooter["NONE"] = "none";
|
|
28
29
|
StoryHeaderFooter["STANDARD"] = "standard";
|
|
29
30
|
StoryHeaderFooter["FULL"] = "full";
|
|
30
|
-
|
|
31
|
-
}({});
|
|
31
|
+
})(StoryHeaderFooter || (StoryHeaderFooter = {}));
|
|
32
32
|
_Campaign.StoryHeaderFooter = StoryHeaderFooter;
|
|
33
|
-
let SenderDomainVerificationStatus
|
|
33
|
+
let SenderDomainVerificationStatus;
|
|
34
|
+
(function (SenderDomainVerificationStatus) {
|
|
34
35
|
SenderDomainVerificationStatus["UNKNOWN"] = "unknown";
|
|
35
36
|
SenderDomainVerificationStatus["VALID"] = "valid";
|
|
36
37
|
SenderDomainVerificationStatus["INVALID"] = "invalid";
|
|
37
38
|
SenderDomainVerificationStatus["NOT_APPLICABLE"] = "not-applicable";
|
|
38
|
-
|
|
39
|
-
}({});
|
|
39
|
+
})(SenderDomainVerificationStatus || (SenderDomainVerificationStatus = {}));
|
|
40
40
|
_Campaign.SenderDomainVerificationStatus = SenderDomainVerificationStatus;
|
|
41
|
-
let ClickTrackingVersion
|
|
41
|
+
let ClickTrackingVersion;
|
|
42
|
+
(function (ClickTrackingVersion) {
|
|
42
43
|
ClickTrackingVersion[ClickTrackingVersion["DEPRECATED"] = 1] = "DEPRECATED";
|
|
43
44
|
ClickTrackingVersion[ClickTrackingVersion["ENHANCED"] = 2] = "ENHANCED";
|
|
44
45
|
ClickTrackingVersion[ClickTrackingVersion["INHOUSE"] = 3] = "INHOUSE";
|
|
45
|
-
|
|
46
|
-
}({});
|
|
46
|
+
})(ClickTrackingVersion || (ClickTrackingVersion = {}));
|
|
47
47
|
_Campaign.ClickTrackingVersion = ClickTrackingVersion;
|
|
48
48
|
function isDraft(arg) {
|
|
49
49
|
if (typeof arg === 'object') {
|
package/dist/types/Category.cjs
CHANGED
|
@@ -5,6 +5,7 @@ Object.defineProperty(exports, "__esModule", {
|
|
|
5
5
|
});
|
|
6
6
|
exports.CategoryRef = exports.Category = void 0;
|
|
7
7
|
let CategoryRef = exports.CategoryRef = void 0;
|
|
8
|
+
(function (_CategoryRef) {})(CategoryRef || (exports.CategoryRef = CategoryRef = {}));
|
|
8
9
|
let Category = exports.Category = void 0;
|
|
9
10
|
(function (_Category) {
|
|
10
11
|
function isTranslated(category, locale) {
|
package/dist/types/Category.js
CHANGED
package/dist/types/Contact.cjs
CHANGED
|
@@ -6,20 +6,21 @@ Object.defineProperty(exports, "__esModule", {
|
|
|
6
6
|
exports.Contact = void 0;
|
|
7
7
|
let Contact = exports.Contact = void 0;
|
|
8
8
|
(function (_Contact) {
|
|
9
|
-
let Type
|
|
9
|
+
let Type;
|
|
10
|
+
(function (Type) {
|
|
10
11
|
Type["PERSON"] = "person";
|
|
11
12
|
Type["ORGANISATION"] = "organisation";
|
|
12
|
-
|
|
13
|
-
}({});
|
|
13
|
+
})(Type || (Type = {}));
|
|
14
14
|
_Contact.Type = Type;
|
|
15
|
-
let Gender
|
|
15
|
+
let Gender;
|
|
16
|
+
(function (Gender) {
|
|
16
17
|
Gender["MALE"] = "male";
|
|
17
18
|
Gender["FEMALE"] = "female";
|
|
18
19
|
Gender["UNSPECIFIED"] = "unspecified";
|
|
19
|
-
|
|
20
|
-
}({});
|
|
20
|
+
})(Gender || (Gender = {}));
|
|
21
21
|
_Contact.Gender = Gender;
|
|
22
|
-
let Periodicity
|
|
22
|
+
let Periodicity;
|
|
23
|
+
(function (Periodicity) {
|
|
23
24
|
Periodicity["DAILY"] = "daily";
|
|
24
25
|
Periodicity["WEEKDAYS"] = "weekdays";
|
|
25
26
|
Periodicity["WEEKLY"] = "weekly";
|
|
@@ -30,10 +31,10 @@ let Contact = exports.Contact = void 0;
|
|
|
30
31
|
Periodicity["ANNUALLY"] = "annually";
|
|
31
32
|
Periodicity["BI_ANUALLY"] = "bi-annually";
|
|
32
33
|
Periodicity["SEMI_ANNUALLY"] = "semi-annually";
|
|
33
|
-
|
|
34
|
-
}({});
|
|
34
|
+
})(Periodicity || (Periodicity = {}));
|
|
35
35
|
_Contact.Periodicity = Periodicity;
|
|
36
|
-
let MediumType
|
|
36
|
+
let MediumType;
|
|
37
|
+
(function (MediumType) {
|
|
37
38
|
MediumType["WIRE"] = "wire";
|
|
38
39
|
MediumType["PRINT"] = "print";
|
|
39
40
|
MediumType["RADIO"] = "radio";
|
|
@@ -51,10 +52,10 @@ let Contact = exports.Contact = void 0;
|
|
|
51
52
|
MediumType["PODCAST"] = "podcast";
|
|
52
53
|
MediumType["NEWSLETTER"] = "newsletter";
|
|
53
54
|
MediumType["NEWS_SITE"] = "news website";
|
|
54
|
-
|
|
55
|
-
}({});
|
|
55
|
+
})(MediumType || (MediumType = {}));
|
|
56
56
|
_Contact.MediumType = MediumType;
|
|
57
|
-
let SocialNetwork
|
|
57
|
+
let SocialNetwork;
|
|
58
|
+
(function (SocialNetwork) {
|
|
58
59
|
SocialNetwork["DISCORD"] = "discord";
|
|
59
60
|
SocialNetwork["FACEBOOK"] = "facebook";
|
|
60
61
|
SocialNetwork["INSTAGRAM"] = "instagram";
|
|
@@ -66,16 +67,15 @@ let Contact = exports.Contact = void 0;
|
|
|
66
67
|
SocialNetwork["TWITCH"] = "twitch";
|
|
67
68
|
SocialNetwork["TWITTER"] = "twitter";
|
|
68
69
|
SocialNetwork["YOUTUBE"] = "youtube";
|
|
69
|
-
|
|
70
|
-
}({});
|
|
70
|
+
})(SocialNetwork || (SocialNetwork = {}));
|
|
71
71
|
_Contact.SocialNetwork = SocialNetwork;
|
|
72
72
|
let PhoneNumber;
|
|
73
73
|
(function (_PhoneNumber) {
|
|
74
|
-
let Type
|
|
74
|
+
let Type;
|
|
75
|
+
(function (Type) {
|
|
75
76
|
Type["TELEPHONE"] = "tel";
|
|
76
77
|
Type["CELLPHONE"] = "cell";
|
|
77
|
-
|
|
78
|
-
}({});
|
|
78
|
+
})(Type || (Type = {}));
|
|
79
79
|
_PhoneNumber.Type = Type;
|
|
80
80
|
})(PhoneNumber || (PhoneNumber = _Contact.PhoneNumber || (_Contact.PhoneNumber = {})));
|
|
81
81
|
function isPerson(arg) {
|