@prezly/sdk 23.19.0 → 24.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.
@@ -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.18.0";
7
+ const VERSION = "23.20.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.18.0";
1
+ const VERSION = "23.20.0";
2
2
  const URL = 'https://github.com/prezly/javascript-sdk';
3
3
  export const DEFAULT_USER_AGENT = `prezly-javascript-sdk/${VERSION} (+${URL})`;
@@ -101,8 +101,8 @@ function createClient(api) {
101
101
  };
102
102
  }
103
103
  async function doDeleteMany(ids) {
104
- const data = await api.delete(_routing.routing.contactTagsUrl, {
105
- query: {
104
+ const data = await api.post(_routing.routing.contactTagsDeleteManyUrl, {
105
+ payload: {
106
106
  id: ids
107
107
  }
108
108
  });
@@ -111,8 +111,8 @@ function createClient(api) {
111
111
  };
112
112
  }
113
113
  async function doDeleteUnused() {
114
- const data = await api.delete(_routing.routing.contactTagsUrl, {
115
- query: {
114
+ const data = await api.post(_routing.routing.contactTagsDeleteManyUrl, {
115
+ payload: {
116
116
  filter: 'unused'
117
117
  }
118
118
  });
@@ -93,8 +93,8 @@ export function createClient(api) {
93
93
  };
94
94
  }
95
95
  async function doDeleteMany(ids) {
96
- const data = await api.delete(routing.contactTagsUrl, {
97
- query: {
96
+ const data = await api.post(routing.contactTagsDeleteManyUrl, {
97
+ payload: {
98
98
  id: ids
99
99
  }
100
100
  });
@@ -103,8 +103,8 @@ export function createClient(api) {
103
103
  };
104
104
  }
105
105
  async function doDeleteUnused() {
106
- const data = await api.delete(routing.contactTagsUrl, {
107
- query: {
106
+ const data = await api.post(routing.contactTagsDeleteManyUrl, {
107
+ payload: {
108
108
  filter: 'unused'
109
109
  }
110
110
  });
@@ -16,7 +16,7 @@ export interface SearchOptions extends ListOptions {
16
16
  query?: Query;
17
17
  }
18
18
  export interface ListResponse {
19
- newsrooms: Newsroom[];
19
+ newsrooms: Omit<Newsroom, 'policies'>[];
20
20
  pagination: Pagination;
21
21
  sort: string;
22
22
  }
package/dist/routing.cjs CHANGED
@@ -13,6 +13,7 @@ const routing = exports.routing = {
13
13
  contactsUrl: '/v2/contacts',
14
14
  contactTagGroupsUrl: '/v2/contact-tag-groups',
15
15
  contactTagsUrl: '/v2/contact-tags',
16
+ contactTagsDeleteManyUrl: '/v2/contact-tags/delete-many',
16
17
  coverageUrl: '/v2/coverage',
17
18
  coverageIntegrationsUrl: '/v2/coverage/integrations',
18
19
  jobsUrl: '/v2/jobs',
package/dist/routing.d.ts CHANGED
@@ -7,6 +7,7 @@ export declare const routing: {
7
7
  contactsUrl: string;
8
8
  contactTagGroupsUrl: string;
9
9
  contactTagsUrl: string;
10
+ contactTagsDeleteManyUrl: string;
10
11
  coverageUrl: string;
11
12
  coverageIntegrationsUrl: string;
12
13
  jobsUrl: string;
package/dist/routing.js CHANGED
@@ -7,6 +7,7 @@ export const routing = {
7
7
  contactsUrl: '/v2/contacts',
8
8
  contactTagGroupsUrl: '/v2/contact-tag-groups',
9
9
  contactTagsUrl: '/v2/contact-tags',
10
+ contactTagsDeleteManyUrl: '/v2/contact-tags/delete-many',
10
11
  coverageUrl: '/v2/coverage',
11
12
  coverageIntegrationsUrl: '/v2/coverage/integrations',
12
13
  jobsUrl: '/v2/jobs',
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@prezly/sdk",
3
- "version": "23.19.0",
3
+ "version": "24.0.0",
4
4
  "description": "Prezly API SDK",
5
5
  "type": "module",
6
6
  "main": "dist/index.cjs",