@prezly/sdk 16.8.0 → 17.0.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/Client.cjs +0 -1
- package/dist/Client.d.ts +1 -2
- package/dist/Client.js +1 -2
- package/dist/api/constants.cjs +1 -1
- package/dist/api/constants.js +1 -1
- package/dist/endpoints/index.cjs +1 -3
- package/dist/endpoints/index.d.ts +0 -1
- package/dist/endpoints/index.js +0 -1
- package/dist/types/NewsroomTheme.cjs +1 -0
- package/dist/types/NewsroomTheme.d.ts +2 -1
- package/dist/types/NewsroomTheme.js +1 -0
- package/package.json +1 -1
- package/dist/endpoints/Signup/Client.cjs +0 -21
- package/dist/endpoints/Signup/Client.d.ts +0 -7
- package/dist/endpoints/Signup/Client.js +0 -14
- package/dist/endpoints/Signup/index.cjs +0 -25
- package/dist/endpoints/Signup/index.d.ts +0 -2
- package/dist/endpoints/Signup/index.js +0 -2
- package/dist/endpoints/Signup/types.cjs +0 -12
- package/dist/endpoints/Signup/types.d.ts +0 -9
- package/dist/endpoints/Signup/types.js +0 -5
package/dist/Client.cjs
CHANGED
|
@@ -40,7 +40,6 @@ function createClient({
|
|
|
40
40
|
newsroomHub: new _index2.NewsroomHub.Client(apiClient),
|
|
41
41
|
pricingTables: new _index2.PricingTables.Client(apiClient),
|
|
42
42
|
senderAddresses: new _index2.SenderAddresses.Client(apiClient),
|
|
43
|
-
signup: new _index2.Signup.Client(apiClient),
|
|
44
43
|
stories: new _index2.Stories.Client(apiClient),
|
|
45
44
|
snippets: new _index2.Snippets.Client(apiClient),
|
|
46
45
|
subscriptions: new _index2.Subscriptions.Client(apiClient),
|
package/dist/Client.d.ts
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { DeferredJobsApiClient } from './api';
|
|
2
2
|
import { Contacts } from './endpoints';
|
|
3
|
-
import { Accounts, Billing, Campaigns, CampaignRecipients, ContactsExports, Coverage, Jobs, Licenses, Newsrooms, NewsroomCategories, NewsroomContacts, NewsroomLanguages, NewsroomThemes, NewsroomWebhooks, NewsroomPrivacyRequests, NewsroomDomains, NewsroomGalleries, NewsroomHub, PricingTables, SenderAddresses,
|
|
3
|
+
import { Accounts, Billing, Campaigns, CampaignRecipients, ContactsExports, Coverage, Jobs, Licenses, Newsrooms, NewsroomCategories, NewsroomContacts, NewsroomLanguages, NewsroomThemes, NewsroomWebhooks, NewsroomPrivacyRequests, NewsroomDomains, NewsroomGalleries, NewsroomHub, PricingTables, SenderAddresses, Stories, Snippets, Subscriptions, NotificationSubscriptions } from './endpoints';
|
|
4
4
|
import type { HeadersMap } from './http';
|
|
5
5
|
export interface ClientOptions {
|
|
6
6
|
accessToken: string;
|
|
@@ -30,7 +30,6 @@ export interface Client {
|
|
|
30
30
|
newsroomHub: NewsroomHub.Client;
|
|
31
31
|
pricingTables: PricingTables.Client;
|
|
32
32
|
senderAddresses: SenderAddresses.Client;
|
|
33
|
-
signup: Signup.Client;
|
|
34
33
|
stories: Stories.Client;
|
|
35
34
|
snippets: Snippets.Client;
|
|
36
35
|
subscriptions: Subscriptions.Client;
|
package/dist/Client.js
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { ApiClient, DeferredJobsApiClient } from "./api/index.js";
|
|
2
2
|
import { Contacts } from "./endpoints/index.js";
|
|
3
|
-
import { Accounts, Billing, Campaigns, CampaignRecipients, ContactsExports, Coverage, Jobs, Licenses, Newsrooms, NewsroomCategories, NewsroomContacts, NewsroomLanguages, NewsroomThemes, NewsroomWebhooks, NewsroomPrivacyRequests, NewsroomDomains, NewsroomGalleries, NewsroomHub, PricingTables, SenderAddresses,
|
|
3
|
+
import { Accounts, Billing, Campaigns, CampaignRecipients, ContactsExports, Coverage, Jobs, Licenses, Newsrooms, NewsroomCategories, NewsroomContacts, NewsroomLanguages, NewsroomThemes, NewsroomWebhooks, NewsroomPrivacyRequests, NewsroomDomains, NewsroomGalleries, NewsroomHub, PricingTables, SenderAddresses, Stories, Snippets, Subscriptions, NotificationSubscriptions } from "./endpoints/index.js";
|
|
4
4
|
const DEFAULT_BASE_URL = 'https://api.prezly.com';
|
|
5
5
|
export function createClient({
|
|
6
6
|
accessToken,
|
|
@@ -35,7 +35,6 @@ export function createClient({
|
|
|
35
35
|
newsroomHub: new NewsroomHub.Client(apiClient),
|
|
36
36
|
pricingTables: new PricingTables.Client(apiClient),
|
|
37
37
|
senderAddresses: new SenderAddresses.Client(apiClient),
|
|
38
|
-
signup: new Signup.Client(apiClient),
|
|
39
38
|
stories: new Stories.Client(apiClient),
|
|
40
39
|
snippets: new Snippets.Client(apiClient),
|
|
41
40
|
subscriptions: new Subscriptions.Client(apiClient),
|
package/dist/api/constants.cjs
CHANGED
|
@@ -4,7 +4,7 @@ Object.defineProperty(exports, "__esModule", {
|
|
|
4
4
|
value: true
|
|
5
5
|
});
|
|
6
6
|
exports.DEFAULT_USER_AGENT = void 0;
|
|
7
|
-
const VERSION = "16.
|
|
7
|
+
const VERSION = "16.9.0";
|
|
8
8
|
const URL = 'https://github.com/prezly/javascript-sdk';
|
|
9
9
|
const DEFAULT_USER_AGENT = `prezly-javascript-sdk/${VERSION} (+${URL})`;
|
|
10
10
|
exports.DEFAULT_USER_AGENT = DEFAULT_USER_AGENT;
|
package/dist/api/constants.js
CHANGED
package/dist/endpoints/index.cjs
CHANGED
|
@@ -3,7 +3,7 @@
|
|
|
3
3
|
Object.defineProperty(exports, "__esModule", {
|
|
4
4
|
value: true
|
|
5
5
|
});
|
|
6
|
-
exports.NotificationSubscriptions = exports.Subscriptions = exports.Stories = exports.Snippets = exports.
|
|
6
|
+
exports.NotificationSubscriptions = exports.Subscriptions = exports.Stories = exports.Snippets = exports.SenderAddresses = exports.PricingTables = exports.NewsroomWebhooks = exports.NewsroomThemes = exports.NewsroomSubscriptions = exports.Newsrooms = exports.NewsroomPrivacyRequests = exports.NewsroomLanguages = exports.NewsroomHub = exports.NewsroomGalleries = exports.NewsroomDomains = exports.NewsroomContacts = exports.NewsroomCategories = exports.Licenses = exports.Jobs = exports.Coverage = exports.ContactsExports = exports.Contacts = exports.Campaigns = exports.CampaignRecipients = exports.Billing = exports.Accounts = void 0;
|
|
7
7
|
var _Accounts = _interopRequireWildcard(require("./Accounts/index.cjs"));
|
|
8
8
|
exports.Accounts = _Accounts;
|
|
9
9
|
var _Billing = _interopRequireWildcard(require("./Billing/index.cjs"));
|
|
@@ -48,8 +48,6 @@ var _PricingTables = _interopRequireWildcard(require("./PricingTables/index.cjs"
|
|
|
48
48
|
exports.PricingTables = _PricingTables;
|
|
49
49
|
var _SenderAddresses = _interopRequireWildcard(require("./SenderAddresses/index.cjs"));
|
|
50
50
|
exports.SenderAddresses = _SenderAddresses;
|
|
51
|
-
var _Signup = _interopRequireWildcard(require("./Signup/index.cjs"));
|
|
52
|
-
exports.Signup = _Signup;
|
|
53
51
|
var _Snippets = _interopRequireWildcard(require("./Snippets/index.cjs"));
|
|
54
52
|
exports.Snippets = _Snippets;
|
|
55
53
|
var _Stories = _interopRequireWildcard(require("./Stories/index.cjs"));
|
|
@@ -20,7 +20,6 @@ export * as NewsroomThemes from './NewsroomThemes';
|
|
|
20
20
|
export * as NewsroomWebhooks from './NewsroomWebhooks';
|
|
21
21
|
export * as PricingTables from './PricingTables';
|
|
22
22
|
export * as SenderAddresses from './SenderAddresses';
|
|
23
|
-
export * as Signup from './Signup';
|
|
24
23
|
export * as Snippets from './Snippets';
|
|
25
24
|
export * as Stories from './Stories';
|
|
26
25
|
export * as Subscriptions from './Subscriptions';
|
package/dist/endpoints/index.js
CHANGED
|
@@ -20,7 +20,6 @@ export * as NewsroomThemes from "./NewsroomThemes/index.js";
|
|
|
20
20
|
export * as NewsroomWebhooks from "./NewsroomWebhooks/index.js";
|
|
21
21
|
export * as PricingTables from "./PricingTables/index.js";
|
|
22
22
|
export * as SenderAddresses from "./SenderAddresses/index.js";
|
|
23
|
-
export * as Signup from "./Signup/index.js";
|
|
24
23
|
export * as Snippets from "./Snippets/index.js";
|
|
25
24
|
export * as Stories from "./Stories/index.js";
|
|
26
25
|
export * as Subscriptions from "./Subscriptions/index.js";
|
|
@@ -29,6 +29,7 @@ exports.NewsroomTheme = NewsroomTheme;
|
|
|
29
29
|
Feature["TITLE_FORMATTING"] = "title_formatting";
|
|
30
30
|
Feature["CTA_BUTTONS"] = "cta_buttons";
|
|
31
31
|
Feature["VIDEO_LAYOUT"] = "video_layout";
|
|
32
|
+
Feature["EMBED_LAYOUT"] = "embed_layout";
|
|
32
33
|
})(Feature || (Feature = {}));
|
|
33
34
|
_NewsroomTheme.Feature = Feature;
|
|
34
35
|
function isFeatureSupported(theme, feature) {
|
|
@@ -32,7 +32,8 @@ export declare namespace NewsroomTheme {
|
|
|
32
32
|
STORY_PINNING = "story_pinning",
|
|
33
33
|
TITLE_FORMATTING = "title_formatting",
|
|
34
34
|
CTA_BUTTONS = "cta_buttons",
|
|
35
|
-
VIDEO_LAYOUT = "video_layout"
|
|
35
|
+
VIDEO_LAYOUT = "video_layout",
|
|
36
|
+
EMBED_LAYOUT = "embed_layout"
|
|
36
37
|
}
|
|
37
38
|
function isFeatureSupported(theme: NewsroomTheme, feature: NewsroomTheme.Feature): boolean;
|
|
38
39
|
}
|
|
@@ -22,6 +22,7 @@ export let NewsroomTheme;
|
|
|
22
22
|
Feature["TITLE_FORMATTING"] = "title_formatting";
|
|
23
23
|
Feature["CTA_BUTTONS"] = "cta_buttons";
|
|
24
24
|
Feature["VIDEO_LAYOUT"] = "video_layout";
|
|
25
|
+
Feature["EMBED_LAYOUT"] = "embed_layout";
|
|
25
26
|
})(Feature || (Feature = {}));
|
|
26
27
|
_NewsroomTheme.Feature = Feature;
|
|
27
28
|
function isFeatureSupported(theme, feature) {
|
package/package.json
CHANGED
|
@@ -1,21 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
|
|
3
|
-
Object.defineProperty(exports, "__esModule", {
|
|
4
|
-
value: true
|
|
5
|
-
});
|
|
6
|
-
exports.Client = void 0;
|
|
7
|
-
var _routing = require("../../routing.cjs");
|
|
8
|
-
class Client {
|
|
9
|
-
constructor(apiClient) {
|
|
10
|
-
this.apiClient = apiClient;
|
|
11
|
-
}
|
|
12
|
-
async checkEmailAvailability(email) {
|
|
13
|
-
const url = `${_routing.routing.signup}/check-availability`;
|
|
14
|
-
return this.apiClient.post(url, {
|
|
15
|
-
payload: {
|
|
16
|
-
email
|
|
17
|
-
}
|
|
18
|
-
});
|
|
19
|
-
}
|
|
20
|
-
}
|
|
21
|
-
exports.Client = Client;
|
|
@@ -1,7 +0,0 @@
|
|
|
1
|
-
import type { DeferredJobsApiClient } from '../../api';
|
|
2
|
-
import type { CheckEmailAvailabilityResponse } from './types';
|
|
3
|
-
export declare class Client {
|
|
4
|
-
private readonly apiClient;
|
|
5
|
-
constructor(apiClient: DeferredJobsApiClient);
|
|
6
|
-
checkEmailAvailability(email: string): Promise<CheckEmailAvailabilityResponse>;
|
|
7
|
-
}
|
|
@@ -1,14 +0,0 @@
|
|
|
1
|
-
import { routing } from "../../routing.js";
|
|
2
|
-
export class Client {
|
|
3
|
-
constructor(apiClient) {
|
|
4
|
-
this.apiClient = apiClient;
|
|
5
|
-
}
|
|
6
|
-
async checkEmailAvailability(email) {
|
|
7
|
-
const url = `${routing.signup}/check-availability`;
|
|
8
|
-
return this.apiClient.post(url, {
|
|
9
|
-
payload: {
|
|
10
|
-
email
|
|
11
|
-
}
|
|
12
|
-
});
|
|
13
|
-
}
|
|
14
|
-
}
|
|
@@ -1,25 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
|
|
3
|
-
Object.defineProperty(exports, "__esModule", {
|
|
4
|
-
value: true
|
|
5
|
-
});
|
|
6
|
-
var _Client = require("./Client.cjs");
|
|
7
|
-
Object.keys(_Client).forEach(function (key) {
|
|
8
|
-
if (key === "default" || key === "__esModule") return;
|
|
9
|
-
Object.defineProperty(exports, key, {
|
|
10
|
-
enumerable: true,
|
|
11
|
-
get: function () {
|
|
12
|
-
return _Client[key];
|
|
13
|
-
}
|
|
14
|
-
});
|
|
15
|
-
});
|
|
16
|
-
var _types = require("./types.cjs");
|
|
17
|
-
Object.keys(_types).forEach(function (key) {
|
|
18
|
-
if (key === "default" || key === "__esModule") return;
|
|
19
|
-
Object.defineProperty(exports, key, {
|
|
20
|
-
enumerable: true,
|
|
21
|
-
get: function () {
|
|
22
|
-
return _types[key];
|
|
23
|
-
}
|
|
24
|
-
});
|
|
25
|
-
});
|
|
@@ -1,12 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
|
|
3
|
-
Object.defineProperty(exports, "__esModule", {
|
|
4
|
-
value: true
|
|
5
|
-
});
|
|
6
|
-
exports.EmailAvailability = void 0;
|
|
7
|
-
let EmailAvailability;
|
|
8
|
-
exports.EmailAvailability = EmailAvailability;
|
|
9
|
-
(function (EmailAvailability) {
|
|
10
|
-
EmailAvailability["AVAILABLE"] = "available";
|
|
11
|
-
EmailAvailability["TAKEN"] = "taken";
|
|
12
|
-
})(EmailAvailability || (exports.EmailAvailability = EmailAvailability = {}));
|