@prezly/sdk 23.1.0 → 23.3.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.
@@ -4,6 +4,6 @@ Object.defineProperty(exports, "__esModule", {
4
4
  value: true
5
5
  });
6
6
  exports.DEFAULT_USER_AGENT = void 0;
7
- const VERSION = "23.0.1";
7
+ const VERSION = "23.2.0";
8
8
  const URL = 'https://github.com/prezly/javascript-sdk';
9
9
  const DEFAULT_USER_AGENT = exports.DEFAULT_USER_AGENT = `prezly-javascript-sdk/${VERSION} (+${URL})`;
@@ -1,3 +1,3 @@
1
- const VERSION = "23.0.1";
1
+ const VERSION = "23.2.0";
2
2
  const URL = 'https://github.com/prezly/javascript-sdk';
3
3
  export const DEFAULT_USER_AGENT = `prezly-javascript-sdk/${VERSION} (+${URL})`;
@@ -20,6 +20,15 @@ export interface CoverageEntry {
20
20
  headline: string;
21
21
  user: UserRef;
22
22
  story: Story | null;
23
+ /**
24
+ * Tells whether the story reference has been manually set, or automatically matched.
25
+ * `none` means no information (which is only used for null references).
26
+ */
27
+ story_reference_origin: 'manual' | 'auto' | 'none';
28
+ /**
29
+ * Number of displayed story suggestions (if the automatic matching was not sure enough about it).
30
+ */
31
+ suggested_stories_count: number;
23
32
  newsroom: NewsroomRef | null;
24
33
  author_contact: Contact | null;
25
34
  organisation_contact: Contact | null;
@@ -27,6 +27,14 @@ let License = exports.License = void 0;
27
27
  return Status;
28
28
  }({});
29
29
  _License.Status = Status;
30
+ let SubscriptionStatus = /*#__PURE__*/function (SubscriptionStatus) {
31
+ SubscriptionStatus["TRIALING"] = "trialing";
32
+ SubscriptionStatus["EXPIRED"] = "expired";
33
+ SubscriptionStatus["ACTIVE"] = "active";
34
+ SubscriptionStatus["CANCELED"] = "canceled";
35
+ return SubscriptionStatus;
36
+ }({});
37
+ _License.SubscriptionStatus = SubscriptionStatus;
30
38
  let CompanyType = /*#__PURE__*/function (CompanyType) {
31
39
  CompanyType["BRAND"] = "brand";
32
40
  CompanyType["AGENCY"] = "agency";
@@ -8,6 +8,7 @@ export interface LicenseRef {
8
8
  is_sso_required: boolean;
9
9
  avatar_url: string;
10
10
  status: License.Status;
11
+ subscription_status: License.SubscriptionStatus | null;
11
12
  }
12
13
  export interface License extends LicenseRef {
13
14
  company_type: License.CompanyType | null;
@@ -119,6 +120,12 @@ export declare namespace License {
119
120
  CANCELED = "canceled",
120
121
  UNPAID = "unpaid"
121
122
  }
123
+ enum SubscriptionStatus {
124
+ TRIALING = "trialing",
125
+ EXPIRED = "expired",
126
+ ACTIVE = "active",
127
+ CANCELED = "canceled"
128
+ }
122
129
  enum CompanyType {
123
130
  BRAND = "brand",
124
131
  AGENCY = "agency",
@@ -21,6 +21,14 @@ export let License;
21
21
  return Status;
22
22
  }({});
23
23
  _License.Status = Status;
24
+ let SubscriptionStatus = /*#__PURE__*/function (SubscriptionStatus) {
25
+ SubscriptionStatus["TRIALING"] = "trialing";
26
+ SubscriptionStatus["EXPIRED"] = "expired";
27
+ SubscriptionStatus["ACTIVE"] = "active";
28
+ SubscriptionStatus["CANCELED"] = "canceled";
29
+ return SubscriptionStatus;
30
+ }({});
31
+ _License.SubscriptionStatus = SubscriptionStatus;
24
32
  let CompanyType = /*#__PURE__*/function (CompanyType) {
25
33
  CompanyType["BRAND"] = "brand";
26
34
  CompanyType["AGENCY"] = "agency";
@@ -5,6 +5,7 @@ import type { BillingCycle } from './BillingCycle';
5
5
  import type { Currency } from './Currency';
6
6
  import type { TiersMode, BillingSchema, Tier } from './Price';
7
7
  export interface PlanReference {
8
+ id: string | null;
8
9
  display_name: string;
9
10
  description: string | null;
10
11
  is_legacy: boolean;
@@ -80,6 +80,7 @@ export interface Story {
80
80
  translations: StoryRef[];
81
81
  oembed: OEmbedInfo;
82
82
  coverage_number: number;
83
+ auto_matched_coverage_number: number;
83
84
  language: string;
84
85
  last_coverage_at: string | null;
85
86
  thumbnail_url: string;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@prezly/sdk",
3
- "version": "23.1.0",
3
+ "version": "23.3.0",
4
4
  "description": "Prezly API SDK",
5
5
  "type": "module",
6
6
  "main": "dist/index.cjs",