contentful-management 12.5.0 → 12.6.0-dev.1
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/README.md +3 -3
- package/dist/browser/index.js +1070 -737
- package/dist/browser/index.js.map +1 -1
- package/dist/browser/index.min.js +1 -1
- package/dist/browser/index.min.js.map +1 -1
- package/dist/cjs/index.cjs +1062 -729
- package/dist/cjs/index.cjs.map +1 -1
- package/dist/esm/adapters/REST/endpoints/component-type.mjs +43 -3
- package/dist/esm/adapters/REST/endpoints/component-type.mjs.map +1 -1
- package/dist/esm/adapters/REST/endpoints/data-assembly.mjs +62 -0
- package/dist/esm/adapters/REST/endpoints/data-assembly.mjs.map +1 -0
- package/dist/esm/adapters/REST/endpoints/experience.mjs +52 -0
- package/dist/esm/adapters/REST/endpoints/experience.mjs.map +1 -0
- package/dist/esm/adapters/REST/endpoints/fragment.mjs +50 -0
- package/dist/esm/adapters/REST/endpoints/fragment.mjs.map +1 -0
- package/dist/esm/adapters/REST/endpoints/index.mjs +8 -0
- package/dist/esm/adapters/REST/endpoints/index.mjs.map +1 -1
- package/dist/esm/adapters/REST/endpoints/template.mjs +50 -0
- package/dist/esm/adapters/REST/endpoints/template.mjs.map +1 -0
- package/dist/esm/common-types.mjs.map +1 -1
- package/dist/esm/plain/plain-client.mjs +44 -0
- package/dist/esm/plain/plain-client.mjs.map +1 -1
- package/dist/types/adapters/REST/endpoints/component-type.d.ts +6 -0
- package/dist/types/adapters/REST/endpoints/component-type.js +43 -3
- package/dist/types/adapters/REST/endpoints/component-type.js.map +1 -1
- package/dist/types/adapters/REST/endpoints/data-assembly.d.ts +10 -0
- package/dist/types/adapters/REST/endpoints/data-assembly.js +62 -0
- package/dist/types/adapters/REST/endpoints/data-assembly.js.map +1 -0
- package/dist/types/adapters/REST/endpoints/experience.d.ts +8 -0
- package/dist/types/adapters/REST/endpoints/experience.js +52 -0
- package/dist/types/adapters/REST/endpoints/experience.js.map +1 -0
- package/dist/types/adapters/REST/endpoints/fragment.d.ts +8 -0
- package/dist/types/adapters/REST/endpoints/fragment.js +50 -0
- package/dist/types/adapters/REST/endpoints/fragment.js.map +1 -0
- package/dist/types/adapters/REST/endpoints/index.d.ts +8 -0
- package/dist/types/adapters/REST/endpoints/index.js +8 -0
- package/dist/types/adapters/REST/endpoints/index.js.map +1 -1
- package/dist/types/adapters/REST/endpoints/template.d.ts +8 -0
- package/dist/types/adapters/REST/endpoints/template.js +50 -0
- package/dist/types/adapters/REST/endpoints/template.js.map +1 -0
- package/dist/types/common-types.d.ts +330 -5
- package/dist/types/common-types.js.map +1 -1
- package/dist/types/entities/component-type.d.ts +89 -45
- package/dist/types/entities/data-assembly.d.ts +119 -0
- package/dist/types/entities/experience.d.ts +89 -0
- package/dist/types/entities/fragment.d.ts +52 -0
- package/dist/types/entities/template.d.ts +48 -0
- package/dist/types/export-types.d.ts +5 -0
- package/dist/types/plain/entities/component-type.d.ts +119 -7
- package/dist/types/plain/entities/data-assembly.d.ts +178 -0
- package/dist/types/plain/entities/experience.d.ts +165 -0
- package/dist/types/plain/entities/fragment.d.ts +134 -0
- package/dist/types/plain/entities/template.d.ts +139 -0
- package/dist/types/plain/plain-client-types.d.ts +8 -0
- package/dist/types/plain/plain-client.js +44 -0
- package/dist/types/plain/plain-client.js.map +1 -1
- package/package.json +1 -1
package/dist/cjs/index.cjs
CHANGED
|
@@ -10,13 +10,13 @@ var axios__default = /*#__PURE__*/_interopDefault(axios);
|
|
|
10
10
|
var copy__default = /*#__PURE__*/_interopDefault(copy);
|
|
11
11
|
|
|
12
12
|
/* eslint-disable @typescript-eslint/no-explicit-any */
|
|
13
|
-
function getBaseUrl$
|
|
13
|
+
function getBaseUrl$x(http) {
|
|
14
14
|
return http.defaults.baseURL?.split('/spaces')[0];
|
|
15
15
|
}
|
|
16
|
-
function get$
|
|
16
|
+
function get$19(http, url, config) {
|
|
17
17
|
return http
|
|
18
18
|
.get(url, {
|
|
19
|
-
baseURL: getBaseUrl$
|
|
19
|
+
baseURL: getBaseUrl$x(http),
|
|
20
20
|
...config,
|
|
21
21
|
})
|
|
22
22
|
.then((response) => response.data, contentfulSdkCore.errorHandler);
|
|
@@ -24,7 +24,7 @@ function get$14(http, url, config) {
|
|
|
24
24
|
function patch$5(http, url, payload, config) {
|
|
25
25
|
return http
|
|
26
26
|
.patch(url, payload, {
|
|
27
|
-
baseURL: getBaseUrl$
|
|
27
|
+
baseURL: getBaseUrl$x(http),
|
|
28
28
|
...config,
|
|
29
29
|
})
|
|
30
30
|
.then((response) => response.data, contentfulSdkCore.errorHandler);
|
|
@@ -32,7 +32,7 @@ function patch$5(http, url, payload, config) {
|
|
|
32
32
|
function post$1(http, url, payload, config) {
|
|
33
33
|
return http
|
|
34
34
|
.post(url, payload, {
|
|
35
|
-
baseURL: getBaseUrl$
|
|
35
|
+
baseURL: getBaseUrl$x(http),
|
|
36
36
|
...config,
|
|
37
37
|
})
|
|
38
38
|
.then((response) => response.data, contentfulSdkCore.errorHandler);
|
|
@@ -40,41 +40,41 @@ function post$1(http, url, payload, config) {
|
|
|
40
40
|
function put$1(http, url, payload, config) {
|
|
41
41
|
return http
|
|
42
42
|
.put(url, payload, {
|
|
43
|
-
baseURL: getBaseUrl$
|
|
43
|
+
baseURL: getBaseUrl$x(http),
|
|
44
44
|
...config,
|
|
45
45
|
})
|
|
46
46
|
.then((response) => response.data, contentfulSdkCore.errorHandler);
|
|
47
47
|
}
|
|
48
|
-
function del$
|
|
48
|
+
function del$M(http, url, config) {
|
|
49
49
|
return http
|
|
50
50
|
.delete(url, {
|
|
51
|
-
baseURL: getBaseUrl$
|
|
51
|
+
baseURL: getBaseUrl$x(http),
|
|
52
52
|
...config,
|
|
53
53
|
})
|
|
54
54
|
.then((response) => response.data, contentfulSdkCore.errorHandler);
|
|
55
55
|
}
|
|
56
56
|
function http(http, url, config) {
|
|
57
57
|
return http(url, {
|
|
58
|
-
baseURL: getBaseUrl$
|
|
58
|
+
baseURL: getBaseUrl$x(http),
|
|
59
59
|
...config,
|
|
60
60
|
}).then((response) => response.data, contentfulSdkCore.errorHandler);
|
|
61
61
|
}
|
|
62
62
|
|
|
63
|
-
const get$
|
|
64
|
-
return get$
|
|
63
|
+
const get$18 = (http, params, headers) => {
|
|
64
|
+
return get$19(http, `/spaces/${params.spaceId}/ai/actions/${params.aiActionId}`, {
|
|
65
65
|
headers,
|
|
66
66
|
});
|
|
67
67
|
};
|
|
68
|
-
const getMany$
|
|
69
|
-
return get$
|
|
68
|
+
const getMany$V = (http, params, headers) => {
|
|
69
|
+
return get$19(http, `/spaces/${params.spaceId}/ai/actions`, {
|
|
70
70
|
params: params.query,
|
|
71
71
|
headers,
|
|
72
72
|
});
|
|
73
73
|
};
|
|
74
|
-
const create$
|
|
74
|
+
const create$K = (http, params, data, headers) => {
|
|
75
75
|
return post$1(http, `/spaces/${params.spaceId}/ai/actions`, data, { headers });
|
|
76
76
|
};
|
|
77
|
-
const update$
|
|
77
|
+
const update$B = (http, params, rawData, headers) => {
|
|
78
78
|
const data = copy__default.default(rawData);
|
|
79
79
|
const { sys, ...payload } = data;
|
|
80
80
|
return put$1(http, `/spaces/${params.spaceId}/ai/actions/${params.aiActionId}`, payload, {
|
|
@@ -84,10 +84,10 @@ const update$z = (http, params, rawData, headers) => {
|
|
|
84
84
|
},
|
|
85
85
|
});
|
|
86
86
|
};
|
|
87
|
-
const del$
|
|
88
|
-
return del$
|
|
87
|
+
const del$L = (http, params, headers) => {
|
|
88
|
+
return del$M(http, `/spaces/${params.spaceId}/ai/actions/${params.aiActionId}`, { headers });
|
|
89
89
|
};
|
|
90
|
-
const publish$
|
|
90
|
+
const publish$a = (http, params, rawData, headers) => {
|
|
91
91
|
return put$1(http, `/spaces/${params.spaceId}/ai/actions/${params.aiActionId}/published`, null, {
|
|
92
92
|
headers: {
|
|
93
93
|
'X-Contentful-Version': params.version,
|
|
@@ -95,8 +95,8 @@ const publish$5 = (http, params, rawData, headers) => {
|
|
|
95
95
|
},
|
|
96
96
|
});
|
|
97
97
|
};
|
|
98
|
-
const unpublish$
|
|
99
|
-
return del$
|
|
98
|
+
const unpublish$a = (http, params, headers) => {
|
|
99
|
+
return del$M(http, `/spaces/${params.spaceId}/ai/actions/${params.aiActionId}/published`, {
|
|
100
100
|
headers,
|
|
101
101
|
});
|
|
102
102
|
};
|
|
@@ -106,38 +106,38 @@ const invoke = (http, params, data, headers) => {
|
|
|
106
106
|
|
|
107
107
|
var AiAction = /*#__PURE__*/Object.freeze({
|
|
108
108
|
__proto__: null,
|
|
109
|
-
create: create$
|
|
110
|
-
del: del$
|
|
111
|
-
get: get$
|
|
112
|
-
getMany: getMany$
|
|
109
|
+
create: create$K,
|
|
110
|
+
del: del$L,
|
|
111
|
+
get: get$18,
|
|
112
|
+
getMany: getMany$V,
|
|
113
113
|
invoke: invoke,
|
|
114
|
-
publish: publish$
|
|
115
|
-
unpublish: unpublish$
|
|
116
|
-
update: update$
|
|
114
|
+
publish: publish$a,
|
|
115
|
+
unpublish: unpublish$a,
|
|
116
|
+
update: update$B
|
|
117
117
|
});
|
|
118
118
|
|
|
119
|
-
const get$
|
|
120
|
-
return get$
|
|
119
|
+
const get$17 = (http, params, headers) => {
|
|
120
|
+
return get$19(http, `/spaces/${params.spaceId}/environments/${params.environmentId}/ai/actions/${params.aiActionId}/invocations/${params.invocationId}`, { headers });
|
|
121
121
|
};
|
|
122
122
|
|
|
123
123
|
var AiActionInvocation = /*#__PURE__*/Object.freeze({
|
|
124
124
|
__proto__: null,
|
|
125
|
-
get: get$
|
|
125
|
+
get: get$17
|
|
126
126
|
});
|
|
127
127
|
|
|
128
128
|
const AgentAlphaHeaders = {
|
|
129
129
|
'x-contentful-enable-alpha-feature': 'agents-api',
|
|
130
130
|
};
|
|
131
|
-
const get$
|
|
132
|
-
return get$
|
|
131
|
+
const get$16 = (http, params, headers) => {
|
|
132
|
+
return get$19(http, `/spaces/${params.spaceId}/environments/${params.environmentId}/ai/agents/${params.agentId}`, {
|
|
133
133
|
headers: {
|
|
134
134
|
...AgentAlphaHeaders,
|
|
135
135
|
...headers,
|
|
136
136
|
},
|
|
137
137
|
});
|
|
138
138
|
};
|
|
139
|
-
const getMany$
|
|
140
|
-
return get$
|
|
139
|
+
const getMany$U = (http, params, headers) => {
|
|
140
|
+
return get$19(http, `/spaces/${params.spaceId}/environments/${params.environmentId}/ai/agents`, {
|
|
141
141
|
headers: {
|
|
142
142
|
...AgentAlphaHeaders,
|
|
143
143
|
...headers,
|
|
@@ -156,23 +156,23 @@ const generate = (http, params, data, headers) => {
|
|
|
156
156
|
var Agent = /*#__PURE__*/Object.freeze({
|
|
157
157
|
__proto__: null,
|
|
158
158
|
generate: generate,
|
|
159
|
-
get: get$
|
|
160
|
-
getMany: getMany$
|
|
159
|
+
get: get$16,
|
|
160
|
+
getMany: getMany$U
|
|
161
161
|
});
|
|
162
162
|
|
|
163
163
|
const AgentRunAlphaHeaders = {
|
|
164
164
|
'x-contentful-enable-alpha-feature': 'agents-api',
|
|
165
165
|
};
|
|
166
|
-
const get$
|
|
167
|
-
return get$
|
|
166
|
+
const get$15 = (http, params, headers) => {
|
|
167
|
+
return get$19(http, `/spaces/${params.spaceId}/environments/${params.environmentId}/ai/agents/runs/${params.runId}`, {
|
|
168
168
|
headers: {
|
|
169
169
|
...AgentRunAlphaHeaders,
|
|
170
170
|
...headers,
|
|
171
171
|
},
|
|
172
172
|
});
|
|
173
173
|
};
|
|
174
|
-
const getMany$
|
|
175
|
-
return get$
|
|
174
|
+
const getMany$T = (http, params, headers) => {
|
|
175
|
+
return get$19(http, `/spaces/${params.spaceId}/environments/${params.environmentId}/ai/agents/runs`, {
|
|
176
176
|
params: params.query,
|
|
177
177
|
headers: {
|
|
178
178
|
...AgentRunAlphaHeaders,
|
|
@@ -191,8 +191,8 @@ const resumeRun = (http, params, data, headers) => {
|
|
|
191
191
|
|
|
192
192
|
var AgentRun = /*#__PURE__*/Object.freeze({
|
|
193
193
|
__proto__: null,
|
|
194
|
-
get: get$
|
|
195
|
-
getMany: getMany$
|
|
194
|
+
get: get$15,
|
|
195
|
+
getMany: getMany$T,
|
|
196
196
|
resumeRun: resumeRun
|
|
197
197
|
});
|
|
198
198
|
|
|
@@ -217,8 +217,8 @@ var AgentRun = /*#__PURE__*/Object.freeze({
|
|
|
217
217
|
* .catch(console.error)
|
|
218
218
|
* ```
|
|
219
219
|
*/
|
|
220
|
-
const get
|
|
221
|
-
return get$
|
|
220
|
+
const get$14 = (http, params) => {
|
|
221
|
+
return get$19(http, `/users/me/access_tokens/${params.tokenId}`);
|
|
222
222
|
};
|
|
223
223
|
/**
|
|
224
224
|
* Retrieves multiple access tokens associated with the currently authenticated user.
|
|
@@ -240,8 +240,8 @@ const get$$ = (http, params) => {
|
|
|
240
240
|
* .catch(console.error)
|
|
241
241
|
* ```
|
|
242
242
|
*/
|
|
243
|
-
const getMany$
|
|
244
|
-
return get$
|
|
243
|
+
const getMany$S = (http, params) => {
|
|
244
|
+
return get$19(http, '/users/me/access_tokens', {
|
|
245
245
|
params: params.query,
|
|
246
246
|
});
|
|
247
247
|
};
|
|
@@ -318,7 +318,7 @@ const revoke$1 = (http, params) => {
|
|
|
318
318
|
* ```
|
|
319
319
|
*/
|
|
320
320
|
const getManyForOrganization$7 = (http, params) => {
|
|
321
|
-
return get$
|
|
321
|
+
return get$19(http, `/organizations/${params.organizationId}/access_tokens`, {
|
|
322
322
|
params: params.query,
|
|
323
323
|
});
|
|
324
324
|
};
|
|
@@ -326,28 +326,28 @@ const getManyForOrganization$7 = (http, params) => {
|
|
|
326
326
|
var AccessToken = /*#__PURE__*/Object.freeze({
|
|
327
327
|
__proto__: null,
|
|
328
328
|
createPersonalAccessToken: createPersonalAccessToken,
|
|
329
|
-
get: get
|
|
330
|
-
getMany: getMany$
|
|
329
|
+
get: get$14,
|
|
330
|
+
getMany: getMany$S,
|
|
331
331
|
getManyForOrganization: getManyForOrganization$7,
|
|
332
332
|
revoke: revoke$1
|
|
333
333
|
});
|
|
334
334
|
|
|
335
|
-
const getBaseUrl$
|
|
336
|
-
const getAutomationDefinitionUrl = (params) => `${getBaseUrl$
|
|
337
|
-
const get$
|
|
335
|
+
const getBaseUrl$w = (params) => `/spaces/${params.spaceId}/environments/${params.environmentId}/automation_definitions`;
|
|
336
|
+
const getAutomationDefinitionUrl = (params) => `${getBaseUrl$w(params)}/${params.automationDefinitionId}`;
|
|
337
|
+
const get$13 = (http, params, headers) => get$19(http, getAutomationDefinitionUrl(params), {
|
|
338
338
|
headers,
|
|
339
339
|
});
|
|
340
|
-
const getMany$
|
|
340
|
+
const getMany$R = (http, params, headers) => get$19(http, getBaseUrl$w(params), {
|
|
341
341
|
headers,
|
|
342
342
|
params: params.query,
|
|
343
343
|
});
|
|
344
|
-
const create$
|
|
344
|
+
const create$J = (http, params, rawData, headers) => {
|
|
345
345
|
const data = copy__default.default(rawData);
|
|
346
|
-
return post$1(http, getBaseUrl$
|
|
346
|
+
return post$1(http, getBaseUrl$w(params), data, {
|
|
347
347
|
headers,
|
|
348
348
|
});
|
|
349
349
|
};
|
|
350
|
-
const update$
|
|
350
|
+
const update$A = (http, params, rawData, headers) => {
|
|
351
351
|
const data = copy__default.default(rawData);
|
|
352
352
|
delete data.sys;
|
|
353
353
|
return put$1(http, getAutomationDefinitionUrl(params), data, {
|
|
@@ -357,52 +357,52 @@ const update$y = (http, params, rawData, headers) => {
|
|
|
357
357
|
},
|
|
358
358
|
});
|
|
359
359
|
};
|
|
360
|
-
const del$
|
|
361
|
-
return del$
|
|
360
|
+
const del$K = (http, params, headers) => {
|
|
361
|
+
return del$M(http, getAutomationDefinitionUrl(params), {
|
|
362
362
|
headers: { 'X-Contentful-Version': params.version, ...headers },
|
|
363
363
|
});
|
|
364
364
|
};
|
|
365
365
|
|
|
366
366
|
var AutomationDefinition = /*#__PURE__*/Object.freeze({
|
|
367
367
|
__proto__: null,
|
|
368
|
-
create: create$
|
|
369
|
-
del: del$
|
|
370
|
-
get: get$
|
|
371
|
-
getMany: getMany$
|
|
372
|
-
update: update$
|
|
368
|
+
create: create$J,
|
|
369
|
+
del: del$K,
|
|
370
|
+
get: get$13,
|
|
371
|
+
getMany: getMany$R,
|
|
372
|
+
update: update$A
|
|
373
373
|
});
|
|
374
374
|
|
|
375
|
-
const getBaseUrl$
|
|
376
|
-
const getAutomationExecutionUrl = (params) => `${getBaseUrl$
|
|
375
|
+
const getBaseUrl$v = (params) => `/spaces/${params.spaceId}/environments/${params.environmentId}/automation_executions`;
|
|
376
|
+
const getAutomationExecutionUrl = (params) => `${getBaseUrl$v(params)}/${params.automationExecutionId}`;
|
|
377
377
|
const getExecutionsByDefinitionUrl = (params) => `/spaces/${params.spaceId}/environments/${params.environmentId}/automation_definitions/${params.automationDefinitionId}/automation_executions`;
|
|
378
|
-
const get$
|
|
378
|
+
const get$12 = (http, params, headers) => get$19(http, getAutomationExecutionUrl(params), {
|
|
379
379
|
headers,
|
|
380
380
|
});
|
|
381
|
-
const getMany$
|
|
381
|
+
const getMany$Q = (http, params, headers) => get$19(http, getBaseUrl$v(params), {
|
|
382
382
|
headers,
|
|
383
383
|
params: params.query,
|
|
384
384
|
});
|
|
385
|
-
const getForAutomationDefinition = (http, params, headers) => get$
|
|
385
|
+
const getForAutomationDefinition = (http, params, headers) => get$19(http, getExecutionsByDefinitionUrl(params), {
|
|
386
386
|
headers,
|
|
387
387
|
params: params.query,
|
|
388
388
|
});
|
|
389
389
|
|
|
390
390
|
var AutomationExecution = /*#__PURE__*/Object.freeze({
|
|
391
391
|
__proto__: null,
|
|
392
|
-
get: get$
|
|
392
|
+
get: get$12,
|
|
393
393
|
getForAutomationDefinition: getForAutomationDefinition,
|
|
394
|
-
getMany: getMany$
|
|
394
|
+
getMany: getMany$Q
|
|
395
395
|
});
|
|
396
396
|
|
|
397
|
-
const get$
|
|
398
|
-
return get$
|
|
397
|
+
const get$11 = (http, params) => {
|
|
398
|
+
return get$19(http, `/spaces/${params.spaceId}/api_keys/${params.apiKeyId}`);
|
|
399
399
|
};
|
|
400
|
-
const getMany$
|
|
401
|
-
return get$
|
|
400
|
+
const getMany$P = (http, params) => {
|
|
401
|
+
return get$19(http, `/spaces/${params.spaceId}/api_keys`, {
|
|
402
402
|
params: params.query,
|
|
403
403
|
});
|
|
404
404
|
};
|
|
405
|
-
const create$
|
|
405
|
+
const create$I = (http, params, data, headers) => {
|
|
406
406
|
return post$1(http, `/spaces/${params.spaceId}/api_keys`, data, { headers });
|
|
407
407
|
};
|
|
408
408
|
const createWithId$e = (http, params, data, headers) => {
|
|
@@ -410,7 +410,7 @@ const createWithId$e = (http, params, data, headers) => {
|
|
|
410
410
|
headers,
|
|
411
411
|
});
|
|
412
412
|
};
|
|
413
|
-
const update$
|
|
413
|
+
const update$z = (http, params, rawData, headers) => {
|
|
414
414
|
const data = copy__default.default(rawData);
|
|
415
415
|
if ('accessToken' in data) {
|
|
416
416
|
delete data.accessToken;
|
|
@@ -429,27 +429,27 @@ const update$x = (http, params, rawData, headers) => {
|
|
|
429
429
|
},
|
|
430
430
|
});
|
|
431
431
|
};
|
|
432
|
-
const del$
|
|
433
|
-
return del$
|
|
432
|
+
const del$J = (http, params) => {
|
|
433
|
+
return del$M(http, `/spaces/${params.spaceId}/api_keys/${params.apiKeyId}`);
|
|
434
434
|
};
|
|
435
435
|
|
|
436
436
|
var ApiKey = /*#__PURE__*/Object.freeze({
|
|
437
437
|
__proto__: null,
|
|
438
|
-
create: create$
|
|
438
|
+
create: create$I,
|
|
439
439
|
createWithId: createWithId$e,
|
|
440
|
-
del: del$
|
|
441
|
-
get: get$
|
|
442
|
-
getMany: getMany$
|
|
443
|
-
update: update$
|
|
440
|
+
del: del$J,
|
|
441
|
+
get: get$11,
|
|
442
|
+
getMany: getMany$P,
|
|
443
|
+
update: update$z
|
|
444
444
|
});
|
|
445
445
|
|
|
446
|
-
const create$
|
|
446
|
+
const create$H = (http, params, data) => {
|
|
447
447
|
return post$1(http, `/spaces/${params.spaceId}/environments/${params.environmentId}/app_installations/${params.appDefinitionId}/access_tokens`, undefined, { headers: { Authorization: `Bearer ${data.jwt}` } });
|
|
448
448
|
};
|
|
449
449
|
|
|
450
450
|
var AppAccessToken = /*#__PURE__*/Object.freeze({
|
|
451
451
|
__proto__: null,
|
|
452
|
-
create: create$
|
|
452
|
+
create: create$H
|
|
453
453
|
});
|
|
454
454
|
|
|
455
455
|
function normalizeSelect(query) {
|
|
@@ -472,45 +472,45 @@ function normalizeSpaceId(query) {
|
|
|
472
472
|
return query;
|
|
473
473
|
}
|
|
474
474
|
|
|
475
|
-
const getBaseUrl$
|
|
476
|
-
const getAppActionUrl = (params) => `${getBaseUrl$
|
|
475
|
+
const getBaseUrl$u = (params) => `/organizations/${params.organizationId}/app_definitions/${params.appDefinitionId}/actions`;
|
|
476
|
+
const getAppActionUrl = (params) => `${getBaseUrl$u(params)}/${params.appActionId}`;
|
|
477
477
|
const getAppActionsEnvUrl = (params) => {
|
|
478
478
|
if (params.environmentId) {
|
|
479
479
|
return `/spaces/${params.spaceId}/environments/${params.environmentId}/actions`;
|
|
480
480
|
}
|
|
481
481
|
return `/spaces/${params.spaceId}/actions`;
|
|
482
482
|
};
|
|
483
|
-
const get$
|
|
484
|
-
return get$
|
|
483
|
+
const get$10 = (http, params) => {
|
|
484
|
+
return get$19(http, getAppActionUrl(params));
|
|
485
485
|
};
|
|
486
|
-
const getMany$
|
|
487
|
-
return get$
|
|
486
|
+
const getMany$O = (http, params) => {
|
|
487
|
+
return get$19(http, getBaseUrl$u(params), {
|
|
488
488
|
params: normalizeSelect(params.query),
|
|
489
489
|
});
|
|
490
490
|
};
|
|
491
491
|
const getManyForEnvironment$2 = (http, params) => {
|
|
492
|
-
return get$
|
|
492
|
+
return get$19(http, getAppActionsEnvUrl(params), {
|
|
493
493
|
params: normalizeSelect(params.query),
|
|
494
494
|
});
|
|
495
495
|
};
|
|
496
|
-
const del$
|
|
497
|
-
return del$
|
|
496
|
+
const del$I = (http, params) => {
|
|
497
|
+
return del$M(http, getAppActionUrl(params));
|
|
498
498
|
};
|
|
499
|
-
const create$
|
|
500
|
-
return post$1(http, getBaseUrl$
|
|
499
|
+
const create$G = (http, params, data) => {
|
|
500
|
+
return post$1(http, getBaseUrl$u(params), data);
|
|
501
501
|
};
|
|
502
|
-
const update$
|
|
502
|
+
const update$y = (http, params, data) => {
|
|
503
503
|
return put$1(http, getAppActionUrl(params), data);
|
|
504
504
|
};
|
|
505
505
|
|
|
506
506
|
var AppAction = /*#__PURE__*/Object.freeze({
|
|
507
507
|
__proto__: null,
|
|
508
|
-
create: create$
|
|
509
|
-
del: del$
|
|
510
|
-
get: get$
|
|
511
|
-
getMany: getMany$
|
|
508
|
+
create: create$G,
|
|
509
|
+
del: del$I,
|
|
510
|
+
get: get$10,
|
|
511
|
+
getMany: getMany$O,
|
|
512
512
|
getManyForEnvironment: getManyForEnvironment$2,
|
|
513
|
-
update: update$
|
|
513
|
+
update: update$y
|
|
514
514
|
});
|
|
515
515
|
|
|
516
516
|
/**
|
|
@@ -576,11 +576,11 @@ function normalizeCursorPaginationResponse(data) {
|
|
|
576
576
|
};
|
|
577
577
|
}
|
|
578
578
|
|
|
579
|
-
const create$
|
|
579
|
+
const create$F = (http, params, data) => {
|
|
580
580
|
return post$1(http, `/spaces/${params.spaceId}/environments/${params.environmentId}/app_installations/${params.appDefinitionId}/actions/${params.appActionId}/calls`, data);
|
|
581
581
|
};
|
|
582
582
|
const getCallDetails$1 = (http, params) => {
|
|
583
|
-
return get$
|
|
583
|
+
return get$19(http, `/spaces/${params.spaceId}/environments/${params.environmentId}/actions/${params.appActionId}/calls/${params.callId}`);
|
|
584
584
|
};
|
|
585
585
|
const APP_ACTION_CALL_RETRY_INTERVAL = 2000;
|
|
586
586
|
const APP_ACTION_CALL_RETRIES = 15;
|
|
@@ -632,12 +632,12 @@ const createWithResponse = async (http, params, data) => {
|
|
|
632
632
|
return callAppActionResult(http, params, { callId });
|
|
633
633
|
};
|
|
634
634
|
// Get structured AppActionCall (status/result/error) via new route that includes app installation context
|
|
635
|
-
const get
|
|
636
|
-
return get$
|
|
635
|
+
const get$$ = (http, params) => {
|
|
636
|
+
return get$19(http, `/spaces/${params.spaceId}/environments/${params.environmentId}/app_installations/${params.appDefinitionId}/actions/${params.appActionId}/calls/${params.callId}`);
|
|
637
637
|
};
|
|
638
638
|
// Get raw AppActionCall response (headers/body) for a completed call
|
|
639
639
|
const getResponse = (http, params) => {
|
|
640
|
-
return get$
|
|
640
|
+
return get$19(http, `/spaces/${params.spaceId}/environments/${params.environmentId}/app_installations/${params.appDefinitionId}/actions/${params.appActionId}/calls/${params.callId}/response`);
|
|
641
641
|
};
|
|
642
642
|
async function pollStructuredAppActionCall(http, params, { callId }) {
|
|
643
643
|
let checkCount = 1;
|
|
@@ -646,7 +646,7 @@ async function pollStructuredAppActionCall(http, params, { callId }) {
|
|
|
646
646
|
return new Promise((resolve, reject) => {
|
|
647
647
|
const poll = async () => {
|
|
648
648
|
try {
|
|
649
|
-
const result = await get
|
|
649
|
+
const result = await get$$(http, { ...params, callId });
|
|
650
650
|
// If backend has not yet written the record, keep polling up to retries
|
|
651
651
|
// Otherwise, resolve when status is terminal
|
|
652
652
|
if (result?.sys.status === 'succeeded' || result?.sys.status === 'failed') {
|
|
@@ -685,28 +685,28 @@ const createWithResult = async (http, params, data) => {
|
|
|
685
685
|
|
|
686
686
|
var AppActionCall = /*#__PURE__*/Object.freeze({
|
|
687
687
|
__proto__: null,
|
|
688
|
-
create: create$
|
|
688
|
+
create: create$F,
|
|
689
689
|
createWithResponse: createWithResponse,
|
|
690
690
|
createWithResult: createWithResult,
|
|
691
|
-
get: get
|
|
691
|
+
get: get$$,
|
|
692
692
|
getCallDetails: getCallDetails$1,
|
|
693
693
|
getResponse: getResponse
|
|
694
694
|
});
|
|
695
695
|
|
|
696
|
-
const getBaseUrl$
|
|
697
|
-
const getAppBundleUrl = (params) => `${getBaseUrl$
|
|
698
|
-
const get$
|
|
699
|
-
return get$
|
|
696
|
+
const getBaseUrl$t = (params) => `/organizations/${params.organizationId}/app_definitions/${params.appDefinitionId}/app_bundles`;
|
|
697
|
+
const getAppBundleUrl = (params) => `${getBaseUrl$t(params)}/${params.appBundleId}`;
|
|
698
|
+
const get$_ = (http, params) => {
|
|
699
|
+
return get$19(http, getAppBundleUrl(params));
|
|
700
700
|
};
|
|
701
|
-
const getMany$
|
|
702
|
-
return get$
|
|
701
|
+
const getMany$N = (http, params) => {
|
|
702
|
+
return get$19(http, getBaseUrl$t(params), {
|
|
703
703
|
params: normalizeSelect(params.query),
|
|
704
704
|
});
|
|
705
705
|
};
|
|
706
|
-
const del$
|
|
707
|
-
return del$
|
|
706
|
+
const del$H = (http, params) => {
|
|
707
|
+
return del$M(http, getAppBundleUrl(params));
|
|
708
708
|
};
|
|
709
|
-
const create$
|
|
709
|
+
const create$E = (http, params, payload) => {
|
|
710
710
|
const { appUploadId, comment, actions, functions } = payload;
|
|
711
711
|
const data = {
|
|
712
712
|
upload: {
|
|
@@ -720,35 +720,35 @@ const create$z = (http, params, payload) => {
|
|
|
720
720
|
actions,
|
|
721
721
|
functions,
|
|
722
722
|
};
|
|
723
|
-
return post$1(http, getBaseUrl$
|
|
723
|
+
return post$1(http, getBaseUrl$t(params), data);
|
|
724
724
|
};
|
|
725
725
|
|
|
726
726
|
var AppBundle = /*#__PURE__*/Object.freeze({
|
|
727
727
|
__proto__: null,
|
|
728
|
-
create: create$
|
|
729
|
-
del: del$
|
|
730
|
-
get: get$
|
|
731
|
-
getMany: getMany$
|
|
728
|
+
create: create$E,
|
|
729
|
+
del: del$H,
|
|
730
|
+
get: get$_,
|
|
731
|
+
getMany: getMany$N
|
|
732
732
|
});
|
|
733
733
|
|
|
734
|
-
const getBaseUrl$
|
|
735
|
-
const getAppDefinitionUrl = (params) => getBaseUrl$
|
|
734
|
+
const getBaseUrl$s = (params) => `/organizations/${params.organizationId}/app_definitions`;
|
|
735
|
+
const getAppDefinitionUrl = (params) => getBaseUrl$s(params) + `/${params.appDefinitionId}`;
|
|
736
736
|
const getBaseUrlForOrgInstallations$1 = (params) => `/app_definitions/${params.appDefinitionId}/app_installations`;
|
|
737
|
-
const get$
|
|
738
|
-
return get$
|
|
737
|
+
const get$Z = (http, params) => {
|
|
738
|
+
return get$19(http, getAppDefinitionUrl(params), {
|
|
739
739
|
params: normalizeSelect(params.query),
|
|
740
740
|
});
|
|
741
741
|
};
|
|
742
|
-
const getMany$
|
|
743
|
-
return get$
|
|
742
|
+
const getMany$M = (http, params) => {
|
|
743
|
+
return get$19(http, getBaseUrl$s(params), {
|
|
744
744
|
params: params.query,
|
|
745
745
|
});
|
|
746
746
|
};
|
|
747
|
-
const create$
|
|
747
|
+
const create$D = (http, params, rawData) => {
|
|
748
748
|
const data = copy__default.default(rawData);
|
|
749
|
-
return post$1(http, getBaseUrl$
|
|
749
|
+
return post$1(http, getBaseUrl$s(params), data);
|
|
750
750
|
};
|
|
751
|
-
const update$
|
|
751
|
+
const update$x = (http, params, rawData, headers) => {
|
|
752
752
|
const data = copy__default.default(rawData);
|
|
753
753
|
delete data.sys;
|
|
754
754
|
return put$1(http, getAppDefinitionUrl(params), data, {
|
|
@@ -758,11 +758,11 @@ const update$v = (http, params, rawData, headers) => {
|
|
|
758
758
|
},
|
|
759
759
|
});
|
|
760
760
|
};
|
|
761
|
-
const del$
|
|
762
|
-
return del$
|
|
761
|
+
const del$G = (http, params) => {
|
|
762
|
+
return del$M(http, getAppDefinitionUrl(params));
|
|
763
763
|
};
|
|
764
764
|
const getInstallationsForOrg = (http, params) => {
|
|
765
|
-
return get$
|
|
765
|
+
return get$19(http, getBaseUrlForOrgInstallations$1(params), {
|
|
766
766
|
params: {
|
|
767
767
|
...normalizeSpaceId(normalizeSelect(params.query)),
|
|
768
768
|
'sys.organization.sys.id[in]': params.organizationId,
|
|
@@ -772,63 +772,63 @@ const getInstallationsForOrg = (http, params) => {
|
|
|
772
772
|
|
|
773
773
|
var AppDefinition = /*#__PURE__*/Object.freeze({
|
|
774
774
|
__proto__: null,
|
|
775
|
-
create: create$
|
|
776
|
-
del: del$
|
|
777
|
-
get: get$
|
|
775
|
+
create: create$D,
|
|
776
|
+
del: del$G,
|
|
777
|
+
get: get$Z,
|
|
778
778
|
getAppDefinitionUrl: getAppDefinitionUrl,
|
|
779
779
|
getInstallationsForOrg: getInstallationsForOrg,
|
|
780
|
-
getMany: getMany$
|
|
781
|
-
update: update$
|
|
780
|
+
getMany: getMany$M,
|
|
781
|
+
update: update$x
|
|
782
782
|
});
|
|
783
783
|
|
|
784
|
-
const get$
|
|
785
|
-
return get$
|
|
784
|
+
const get$Y = (http, params) => {
|
|
785
|
+
return get$19(http, `/organizations/${params.organizationId}/app_definitions/${params.appDefinitionId}/details`);
|
|
786
786
|
};
|
|
787
|
-
const upsert$
|
|
787
|
+
const upsert$8 = (http, params, data) => {
|
|
788
788
|
return put$1(http, `/organizations/${params.organizationId}/app_definitions/${params.appDefinitionId}/details`, data);
|
|
789
789
|
};
|
|
790
|
-
const del$
|
|
791
|
-
return del$
|
|
790
|
+
const del$F = (http, params) => {
|
|
791
|
+
return del$M(http, `/organizations/${params.organizationId}/app_definitions/${params.appDefinitionId}/details`);
|
|
792
792
|
};
|
|
793
793
|
|
|
794
794
|
var AppDetails = /*#__PURE__*/Object.freeze({
|
|
795
795
|
__proto__: null,
|
|
796
|
-
del: del$
|
|
797
|
-
get: get$
|
|
798
|
-
upsert: upsert$
|
|
796
|
+
del: del$F,
|
|
797
|
+
get: get$Y,
|
|
798
|
+
upsert: upsert$8
|
|
799
799
|
});
|
|
800
800
|
|
|
801
|
-
const get$
|
|
802
|
-
return get$
|
|
801
|
+
const get$X = (http, params) => {
|
|
802
|
+
return get$19(http, `/organizations/${params.organizationId}/app_definitions/${params.appDefinitionId}/event_subscription`);
|
|
803
803
|
};
|
|
804
|
-
const upsert$
|
|
804
|
+
const upsert$7 = (http, params, data) => {
|
|
805
805
|
return put$1(http, `/organizations/${params.organizationId}/app_definitions/${params.appDefinitionId}/event_subscription`, data);
|
|
806
806
|
};
|
|
807
|
-
const del$
|
|
808
|
-
return del$
|
|
807
|
+
const del$E = (http, params) => {
|
|
808
|
+
return del$M(http, `/organizations/${params.organizationId}/app_definitions/${params.appDefinitionId}/event_subscription`);
|
|
809
809
|
};
|
|
810
810
|
|
|
811
811
|
var AppEventSubscription = /*#__PURE__*/Object.freeze({
|
|
812
812
|
__proto__: null,
|
|
813
|
-
del: del$
|
|
814
|
-
get: get$
|
|
815
|
-
upsert: upsert$
|
|
813
|
+
del: del$E,
|
|
814
|
+
get: get$X,
|
|
815
|
+
upsert: upsert$7
|
|
816
816
|
});
|
|
817
817
|
|
|
818
|
-
const getBaseUrl$
|
|
818
|
+
const getBaseUrl$r = (params) => `/spaces/${params.spaceId}/environments/${params.environmentId}/app_installations`;
|
|
819
819
|
const getBaseUrlForOrgInstallations = (params) => `/app_definitions/${params.appDefinitionId}/app_installations`;
|
|
820
|
-
const getAppInstallationUrl = (params) => getBaseUrl$
|
|
821
|
-
const get$
|
|
822
|
-
return get$
|
|
820
|
+
const getAppInstallationUrl = (params) => getBaseUrl$r(params) + `/${params.appDefinitionId}`;
|
|
821
|
+
const get$W = (http, params) => {
|
|
822
|
+
return get$19(http, getAppInstallationUrl(params), {
|
|
823
823
|
params: normalizeSelect(params.query),
|
|
824
824
|
});
|
|
825
825
|
};
|
|
826
|
-
const getMany$
|
|
827
|
-
return get$
|
|
826
|
+
const getMany$L = (http, params) => {
|
|
827
|
+
return get$19(http, getBaseUrl$r(params), {
|
|
828
828
|
params: normalizeSelect(params.query),
|
|
829
829
|
});
|
|
830
830
|
};
|
|
831
|
-
const upsert$
|
|
831
|
+
const upsert$6 = (http, params, rawData, headers) => {
|
|
832
832
|
const data = copy__default.default(rawData);
|
|
833
833
|
return put$1(http, getAppInstallationUrl(params), data, {
|
|
834
834
|
headers: {
|
|
@@ -839,11 +839,11 @@ const upsert$3 = (http, params, rawData, headers) => {
|
|
|
839
839
|
},
|
|
840
840
|
});
|
|
841
841
|
};
|
|
842
|
-
const del$
|
|
843
|
-
return del$
|
|
842
|
+
const del$D = (http, params) => {
|
|
843
|
+
return del$M(http, getAppInstallationUrl(params));
|
|
844
844
|
};
|
|
845
845
|
const getForOrganization$3 = (http, params) => {
|
|
846
|
-
return get$
|
|
846
|
+
return get$19(http, getBaseUrlForOrgInstallations(params), {
|
|
847
847
|
params: {
|
|
848
848
|
...normalizeSpaceId(normalizeSelect(params.query)),
|
|
849
849
|
'sys.organization.sys.id[in]': params.organizationId,
|
|
@@ -853,59 +853,59 @@ const getForOrganization$3 = (http, params) => {
|
|
|
853
853
|
|
|
854
854
|
var AppInstallation = /*#__PURE__*/Object.freeze({
|
|
855
855
|
__proto__: null,
|
|
856
|
-
del: del$
|
|
857
|
-
get: get$
|
|
856
|
+
del: del$D,
|
|
857
|
+
get: get$W,
|
|
858
858
|
getAppInstallationUrl: getAppInstallationUrl,
|
|
859
859
|
getForOrganization: getForOrganization$3,
|
|
860
|
-
getMany: getMany$
|
|
861
|
-
upsert: upsert$
|
|
860
|
+
getMany: getMany$L,
|
|
861
|
+
upsert: upsert$6
|
|
862
862
|
});
|
|
863
863
|
|
|
864
|
-
const get$
|
|
865
|
-
return get$
|
|
864
|
+
const get$V = (http, params) => {
|
|
865
|
+
return get$19(http, `/organizations/${params.organizationId}/app_definitions/${params.appDefinitionId}/keys/${params.fingerprint}`);
|
|
866
866
|
};
|
|
867
|
-
const getMany$
|
|
868
|
-
return get$
|
|
867
|
+
const getMany$K = (http, params) => {
|
|
868
|
+
return get$19(http, `/organizations/${params.organizationId}/app_definitions/${params.appDefinitionId}/keys`);
|
|
869
869
|
};
|
|
870
|
-
const create$
|
|
870
|
+
const create$C = (http, params, data) => {
|
|
871
871
|
return post$1(http, `/organizations/${params.organizationId}/app_definitions/${params.appDefinitionId}/keys`, data);
|
|
872
872
|
};
|
|
873
|
-
const del$
|
|
874
|
-
return del$
|
|
873
|
+
const del$C = (http, params) => {
|
|
874
|
+
return del$M(http, `/organizations/${params.organizationId}/app_definitions/${params.appDefinitionId}/keys/${params.fingerprint}`);
|
|
875
875
|
};
|
|
876
876
|
|
|
877
877
|
var AppKey = /*#__PURE__*/Object.freeze({
|
|
878
878
|
__proto__: null,
|
|
879
|
-
create: create$
|
|
880
|
-
del: del$
|
|
881
|
-
get: get$
|
|
882
|
-
getMany: getMany$
|
|
879
|
+
create: create$C,
|
|
880
|
+
del: del$C,
|
|
881
|
+
get: get$V,
|
|
882
|
+
getMany: getMany$K
|
|
883
883
|
});
|
|
884
884
|
|
|
885
|
-
const create$
|
|
885
|
+
const create$B = (http, params, data) => {
|
|
886
886
|
return post$1(http, `/spaces/${params.spaceId}/environments/${params.environmentId}/app_installations/${params.appDefinitionId}/signed_requests`, data);
|
|
887
887
|
};
|
|
888
888
|
|
|
889
889
|
var AppSignedRequest = /*#__PURE__*/Object.freeze({
|
|
890
890
|
__proto__: null,
|
|
891
|
-
create: create$
|
|
891
|
+
create: create$B
|
|
892
892
|
});
|
|
893
893
|
|
|
894
|
-
const get$
|
|
895
|
-
return get$
|
|
894
|
+
const get$U = (http, params) => {
|
|
895
|
+
return get$19(http, `/organizations/${params.organizationId}/app_definitions/${params.appDefinitionId}/signing_secret`);
|
|
896
896
|
};
|
|
897
|
-
const upsert$
|
|
897
|
+
const upsert$5 = (http, params, data) => {
|
|
898
898
|
return put$1(http, `/organizations/${params.organizationId}/app_definitions/${params.appDefinitionId}/signing_secret`, data);
|
|
899
899
|
};
|
|
900
|
-
const del$
|
|
901
|
-
return del$
|
|
900
|
+
const del$B = (http, params) => {
|
|
901
|
+
return del$M(http, `/organizations/${params.organizationId}/app_definitions/${params.appDefinitionId}/signing_secret`);
|
|
902
902
|
};
|
|
903
903
|
|
|
904
904
|
var AppSigningSecret = /*#__PURE__*/Object.freeze({
|
|
905
905
|
__proto__: null,
|
|
906
|
-
del: del$
|
|
907
|
-
get: get$
|
|
908
|
-
upsert: upsert$
|
|
906
|
+
del: del$B,
|
|
907
|
+
get: get$U,
|
|
908
|
+
upsert: upsert$5
|
|
909
909
|
});
|
|
910
910
|
|
|
911
911
|
/**
|
|
@@ -921,20 +921,20 @@ function getUploadHttpClient(http, options) {
|
|
|
921
921
|
return uploadHttp;
|
|
922
922
|
}
|
|
923
923
|
|
|
924
|
-
const getBaseUrl$
|
|
925
|
-
const getAppUploadUrl = (params) => `${getBaseUrl$
|
|
926
|
-
const get$
|
|
924
|
+
const getBaseUrl$q = (params) => `/organizations/${params.organizationId}/app_uploads`;
|
|
925
|
+
const getAppUploadUrl = (params) => `${getBaseUrl$q(params)}/${params.appUploadId}`;
|
|
926
|
+
const get$T = (http, params) => {
|
|
927
927
|
const httpUpload = getUploadHttpClient(http);
|
|
928
|
-
return get$
|
|
928
|
+
return get$19(httpUpload, getAppUploadUrl(params));
|
|
929
929
|
};
|
|
930
|
-
const del$
|
|
930
|
+
const del$A = (http, params) => {
|
|
931
931
|
const httpUpload = getUploadHttpClient(http);
|
|
932
|
-
return del$
|
|
932
|
+
return del$M(httpUpload, getAppUploadUrl(params));
|
|
933
933
|
};
|
|
934
|
-
const create$
|
|
934
|
+
const create$A = (http, params, payload) => {
|
|
935
935
|
const httpUpload = getUploadHttpClient(http);
|
|
936
936
|
const { file } = payload;
|
|
937
|
-
return post$1(httpUpload, getBaseUrl$
|
|
937
|
+
return post$1(httpUpload, getBaseUrl$q(params), file, {
|
|
938
938
|
headers: {
|
|
939
939
|
'Content-Type': 'application/octet-stream',
|
|
940
940
|
},
|
|
@@ -943,9 +943,9 @@ const create$v = (http, params, payload) => {
|
|
|
943
943
|
|
|
944
944
|
var AppUpload = /*#__PURE__*/Object.freeze({
|
|
945
945
|
__proto__: null,
|
|
946
|
-
create: create$
|
|
947
|
-
del: del$
|
|
948
|
-
get: get$
|
|
946
|
+
create: create$A,
|
|
947
|
+
del: del$A,
|
|
948
|
+
get: get$T
|
|
949
949
|
});
|
|
950
950
|
|
|
951
951
|
const getBaseUploadUrl = (params) => {
|
|
@@ -958,7 +958,7 @@ const getEntityUploadUrl = (params) => {
|
|
|
958
958
|
const path = getBaseUploadUrl(params);
|
|
959
959
|
return path + `/${params.uploadId}`;
|
|
960
960
|
};
|
|
961
|
-
const create$
|
|
961
|
+
const create$z = (http, params, data) => {
|
|
962
962
|
const httpUpload = getUploadHttpClient(http);
|
|
963
963
|
const { file } = data;
|
|
964
964
|
if (!file) {
|
|
@@ -971,37 +971,37 @@ const create$u = (http, params, data) => {
|
|
|
971
971
|
},
|
|
972
972
|
});
|
|
973
973
|
};
|
|
974
|
-
const del$
|
|
974
|
+
const del$z = (http, params) => {
|
|
975
975
|
const httpUpload = getUploadHttpClient(http);
|
|
976
976
|
const path = getEntityUploadUrl(params);
|
|
977
|
-
return del$
|
|
977
|
+
return del$M(httpUpload, path);
|
|
978
978
|
};
|
|
979
|
-
const get$
|
|
979
|
+
const get$S = (http, params) => {
|
|
980
980
|
const httpUpload = getUploadHttpClient(http);
|
|
981
981
|
const path = getEntityUploadUrl(params);
|
|
982
|
-
return get$
|
|
982
|
+
return get$19(httpUpload, path);
|
|
983
983
|
};
|
|
984
984
|
|
|
985
985
|
var Upload = /*#__PURE__*/Object.freeze({
|
|
986
986
|
__proto__: null,
|
|
987
|
-
create: create$
|
|
988
|
-
del: del$
|
|
989
|
-
get: get$
|
|
987
|
+
create: create$z,
|
|
988
|
+
del: del$z,
|
|
989
|
+
get: get$S
|
|
990
990
|
});
|
|
991
991
|
|
|
992
|
-
const get$
|
|
993
|
-
return get$
|
|
992
|
+
const get$R = (http, params, rawData, headers) => {
|
|
993
|
+
return get$19(http, `/spaces/${params.spaceId}/environments/${params.environmentId}/releases/${params.releaseId}/assets/${params.assetId}`, {
|
|
994
994
|
params: normalizeSelect(params.query),
|
|
995
995
|
headers: headers ? { ...headers } : undefined,
|
|
996
996
|
});
|
|
997
997
|
};
|
|
998
|
-
const getMany$
|
|
999
|
-
return get$
|
|
998
|
+
const getMany$J = (http, params, rawData, headers) => {
|
|
999
|
+
return get$19(http, `/spaces/${params.spaceId}/environments/${params.environmentId}/releases/${params.releaseId}/assets`, {
|
|
1000
1000
|
params: normalizeSelect(params.query),
|
|
1001
1001
|
headers: headers ? { ...headers } : undefined,
|
|
1002
1002
|
});
|
|
1003
1003
|
};
|
|
1004
|
-
const update$
|
|
1004
|
+
const update$w = (http, params, rawData, headers) => {
|
|
1005
1005
|
const data = copy__default.default(rawData);
|
|
1006
1006
|
delete data.sys;
|
|
1007
1007
|
return put$1(http, `/spaces/${params.spaceId}/environments/${params.environmentId}/releases/${params.releaseId}/assets/${params.assetId}`, data, {
|
|
@@ -1011,7 +1011,7 @@ const update$u = (http, params, rawData, headers) => {
|
|
|
1011
1011
|
},
|
|
1012
1012
|
});
|
|
1013
1013
|
};
|
|
1014
|
-
const create$
|
|
1014
|
+
const create$y = (http, params, rawData, headers) => {
|
|
1015
1015
|
const data = copy__default.default(rawData);
|
|
1016
1016
|
return post$1(http, `/spaces/${params.spaceId}/environments/${params.environmentId}/releases/${params.releaseId}/assets`, data, {
|
|
1017
1017
|
headers,
|
|
@@ -1028,7 +1028,7 @@ const createFromFiles$1 = async (http, params, data) => {
|
|
|
1028
1028
|
const { file } = data.fields;
|
|
1029
1029
|
return Promise.all(Object.keys(file).map(async (locale) => {
|
|
1030
1030
|
const { contentType, fileName } = file[locale];
|
|
1031
|
-
return create$
|
|
1031
|
+
return create$z(httpUpload, params, file[locale]).then((upload) => {
|
|
1032
1032
|
return {
|
|
1033
1033
|
[locale]: {
|
|
1034
1034
|
contentType,
|
|
@@ -1053,7 +1053,7 @@ const createFromFiles$1 = async (http, params, data) => {
|
|
|
1053
1053
|
file,
|
|
1054
1054
|
},
|
|
1055
1055
|
};
|
|
1056
|
-
return create$
|
|
1056
|
+
return create$y(http, params, asset, {});
|
|
1057
1057
|
})
|
|
1058
1058
|
.catch(contentfulSdkCore.errorHandler);
|
|
1059
1059
|
};
|
|
@@ -1063,7 +1063,7 @@ const createFromFiles$1 = async (http, params, data) => {
|
|
|
1063
1063
|
const ASSET_PROCESSING_CHECK_WAIT$1 = 3000;
|
|
1064
1064
|
const ASSET_PROCESSING_CHECK_RETRIES$1 = 10;
|
|
1065
1065
|
async function checkIfAssetHasUrl$1(http, params, { resolve, reject, locale, processingCheckWait = ASSET_PROCESSING_CHECK_WAIT$1, processingCheckRetries = ASSET_PROCESSING_CHECK_RETRIES$1, checkCount = 0, }) {
|
|
1066
|
-
return get$
|
|
1066
|
+
return get$R(http, params).then((asset) => {
|
|
1067
1067
|
if (asset.fields.file[locale].url) {
|
|
1068
1068
|
resolve(asset);
|
|
1069
1069
|
}
|
|
@@ -1125,43 +1125,43 @@ const processForAllLocales$1 = async (http, { asset, options = {}, ...params })
|
|
|
1125
1125
|
|
|
1126
1126
|
var ReleaseAsset = /*#__PURE__*/Object.freeze({
|
|
1127
1127
|
__proto__: null,
|
|
1128
|
-
create: create$
|
|
1128
|
+
create: create$y,
|
|
1129
1129
|
createFromFiles: createFromFiles$1,
|
|
1130
1130
|
createWithId: createWithId$d,
|
|
1131
|
-
get: get$
|
|
1132
|
-
getMany: getMany$
|
|
1131
|
+
get: get$R,
|
|
1132
|
+
getMany: getMany$J,
|
|
1133
1133
|
processForAllLocales: processForAllLocales$1,
|
|
1134
1134
|
processForLocale: processForLocale$1,
|
|
1135
|
-
update: update$
|
|
1135
|
+
update: update$w
|
|
1136
1136
|
});
|
|
1137
1137
|
|
|
1138
|
-
const get$
|
|
1138
|
+
const get$Q = (http, params, rawData, headers) => {
|
|
1139
1139
|
if (params.releaseId) {
|
|
1140
|
-
return get$
|
|
1140
|
+
return get$R(http, params);
|
|
1141
1141
|
}
|
|
1142
|
-
return get$
|
|
1142
|
+
return get$19(http, `/spaces/${params.spaceId}/environments/${params.environmentId}/assets/${params.assetId}`, {
|
|
1143
1143
|
params: normalizeSelect(params.query),
|
|
1144
1144
|
headers: headers ? { ...headers } : undefined,
|
|
1145
1145
|
});
|
|
1146
1146
|
};
|
|
1147
|
-
const getPublished$
|
|
1148
|
-
return get$
|
|
1147
|
+
const getPublished$2 = (http, params, rawData, headers) => {
|
|
1148
|
+
return get$19(http, `/spaces/${params.spaceId}/environments/${params.environmentId}/public/assets`, {
|
|
1149
1149
|
params: normalizeSelect(params.query),
|
|
1150
1150
|
headers: headers ? { ...headers } : undefined,
|
|
1151
1151
|
});
|
|
1152
1152
|
};
|
|
1153
|
-
const getMany$
|
|
1153
|
+
const getMany$I = (http, params, rawData, headers) => {
|
|
1154
1154
|
if (params.releaseId) {
|
|
1155
|
-
return getMany$
|
|
1155
|
+
return getMany$J(http, params);
|
|
1156
1156
|
}
|
|
1157
|
-
return get$
|
|
1157
|
+
return get$19(http, `/spaces/${params.spaceId}/environments/${params.environmentId}/assets`, {
|
|
1158
1158
|
params: normalizeSelect(params.query),
|
|
1159
1159
|
headers: headers ? { ...headers } : undefined,
|
|
1160
1160
|
});
|
|
1161
1161
|
};
|
|
1162
|
-
const update$
|
|
1162
|
+
const update$v = (http, params, rawData, headers) => {
|
|
1163
1163
|
if (params.releaseId) {
|
|
1164
|
-
return update$
|
|
1164
|
+
return update$w(http, params, rawData, headers ?? {});
|
|
1165
1165
|
}
|
|
1166
1166
|
const data = copy__default.default(rawData);
|
|
1167
1167
|
delete data.sys;
|
|
@@ -1172,10 +1172,10 @@ const update$t = (http, params, rawData, headers) => {
|
|
|
1172
1172
|
},
|
|
1173
1173
|
});
|
|
1174
1174
|
};
|
|
1175
|
-
const del$
|
|
1176
|
-
return del$
|
|
1175
|
+
const del$y = (http, params) => {
|
|
1176
|
+
return del$M(http, `/spaces/${params.spaceId}/environments/${params.environmentId}/assets/${params.assetId}`);
|
|
1177
1177
|
};
|
|
1178
|
-
const publish$
|
|
1178
|
+
const publish$9 = (http, params, rawData) => {
|
|
1179
1179
|
const payload = params.locales?.length ? { add: { fields: { '*': params.locales } } } : null;
|
|
1180
1180
|
return put$1(http, `/spaces/${params.spaceId}/environments/${params.environmentId}/assets/${params.assetId}/published`, payload, {
|
|
1181
1181
|
headers: {
|
|
@@ -1183,7 +1183,7 @@ const publish$4 = (http, params, rawData) => {
|
|
|
1183
1183
|
},
|
|
1184
1184
|
});
|
|
1185
1185
|
};
|
|
1186
|
-
const unpublish$
|
|
1186
|
+
const unpublish$9 = (http, params, rawData) => {
|
|
1187
1187
|
if (params.locales?.length) {
|
|
1188
1188
|
const payload = { remove: { fields: { '*': params.locales } } };
|
|
1189
1189
|
return put$1(http, `/spaces/${params.spaceId}/environments/${params.environmentId}/assets/${params.assetId}/published`, payload, {
|
|
@@ -1193,18 +1193,18 @@ const unpublish$4 = (http, params, rawData) => {
|
|
|
1193
1193
|
});
|
|
1194
1194
|
}
|
|
1195
1195
|
else {
|
|
1196
|
-
return del$
|
|
1196
|
+
return del$M(http, `/spaces/${params.spaceId}/environments/${params.environmentId}/assets/${params.assetId}/published`);
|
|
1197
1197
|
}
|
|
1198
1198
|
};
|
|
1199
1199
|
const archive$2 = (http, params) => {
|
|
1200
1200
|
return put$1(http, `/spaces/${params.spaceId}/environments/${params.environmentId}/assets/${params.assetId}/archived`);
|
|
1201
1201
|
};
|
|
1202
1202
|
const unarchive$3 = (http, params) => {
|
|
1203
|
-
return del$
|
|
1203
|
+
return del$M(http, `/spaces/${params.spaceId}/environments/${params.environmentId}/assets/${params.assetId}/archived`);
|
|
1204
1204
|
};
|
|
1205
|
-
const create$
|
|
1205
|
+
const create$x = (http, params, rawData) => {
|
|
1206
1206
|
if (params.releaseId) {
|
|
1207
|
-
return create$
|
|
1207
|
+
return create$y(http, params, rawData, {});
|
|
1208
1208
|
}
|
|
1209
1209
|
const data = copy__default.default(rawData);
|
|
1210
1210
|
return post$1(http, `/spaces/${params.spaceId}/environments/${params.environmentId}/assets`, data);
|
|
@@ -1224,7 +1224,7 @@ const createFromFiles = async (http, params, data) => {
|
|
|
1224
1224
|
const { file } = data.fields;
|
|
1225
1225
|
return Promise.all(Object.keys(file).map(async (locale) => {
|
|
1226
1226
|
const { contentType, fileName } = file[locale];
|
|
1227
|
-
return create$
|
|
1227
|
+
return create$z(httpUpload, params, file[locale]).then((upload) => {
|
|
1228
1228
|
return {
|
|
1229
1229
|
[locale]: {
|
|
1230
1230
|
contentType,
|
|
@@ -1249,7 +1249,7 @@ const createFromFiles = async (http, params, data) => {
|
|
|
1249
1249
|
file,
|
|
1250
1250
|
},
|
|
1251
1251
|
};
|
|
1252
|
-
return create$
|
|
1252
|
+
return create$x(http, params, asset);
|
|
1253
1253
|
})
|
|
1254
1254
|
.catch(contentfulSdkCore.errorHandler);
|
|
1255
1255
|
};
|
|
@@ -1259,7 +1259,7 @@ const createFromFiles = async (http, params, data) => {
|
|
|
1259
1259
|
const ASSET_PROCESSING_CHECK_WAIT = 3000;
|
|
1260
1260
|
const ASSET_PROCESSING_CHECK_RETRIES = 10;
|
|
1261
1261
|
async function checkIfAssetHasUrl(http, params, { resolve, reject, locale, processingCheckWait = ASSET_PROCESSING_CHECK_WAIT, processingCheckRetries = ASSET_PROCESSING_CHECK_RETRIES, checkCount = 0, }) {
|
|
1262
|
-
return get$
|
|
1262
|
+
return get$Q(http, params).then((asset) => {
|
|
1263
1263
|
if (asset.fields.file[locale].url) {
|
|
1264
1264
|
resolve(asset);
|
|
1265
1265
|
}
|
|
@@ -1336,19 +1336,19 @@ const processForAllLocales = async (http, { asset, options = {}, ...params }) =>
|
|
|
1336
1336
|
var Asset = /*#__PURE__*/Object.freeze({
|
|
1337
1337
|
__proto__: null,
|
|
1338
1338
|
archive: archive$2,
|
|
1339
|
-
create: create$
|
|
1339
|
+
create: create$x,
|
|
1340
1340
|
createFromFiles: createFromFiles,
|
|
1341
1341
|
createWithId: createWithId$c,
|
|
1342
|
-
del: del$
|
|
1343
|
-
get: get$
|
|
1344
|
-
getMany: getMany$
|
|
1345
|
-
getPublished: getPublished$
|
|
1342
|
+
del: del$y,
|
|
1343
|
+
get: get$Q,
|
|
1344
|
+
getMany: getMany$I,
|
|
1345
|
+
getPublished: getPublished$2,
|
|
1346
1346
|
processForAllLocales: processForAllLocales,
|
|
1347
1347
|
processForLocale: processForLocale,
|
|
1348
|
-
publish: publish$
|
|
1348
|
+
publish: publish$9,
|
|
1349
1349
|
unarchive: unarchive$3,
|
|
1350
|
-
unpublish: unpublish$
|
|
1351
|
-
update: update$
|
|
1350
|
+
unpublish: unpublish$9,
|
|
1351
|
+
update: update$v
|
|
1352
1352
|
});
|
|
1353
1353
|
|
|
1354
1354
|
const ASSET_KEY_MAX_LIFETIME = 48 * 60 * 60;
|
|
@@ -1370,7 +1370,7 @@ const validateTimestamp = (name, timestamp, options) => {
|
|
|
1370
1370
|
throw new ValidationError(name, `value (${timestamp}) cannot be in the past, current time was ${options.now}`);
|
|
1371
1371
|
}
|
|
1372
1372
|
};
|
|
1373
|
-
const create$
|
|
1373
|
+
const create$w = (http, params, data) => {
|
|
1374
1374
|
const expiresAt = data.expiresAt;
|
|
1375
1375
|
const now = Math.floor(Date.now() / 1000);
|
|
1376
1376
|
const currentMaxLifetime = now + ASSET_KEY_MAX_LIFETIME;
|
|
@@ -1382,35 +1382,35 @@ const create$r = (http, params, data) => {
|
|
|
1382
1382
|
var AssetKey = /*#__PURE__*/Object.freeze({
|
|
1383
1383
|
__proto__: null,
|
|
1384
1384
|
ValidationError: ValidationError,
|
|
1385
|
-
create: create$
|
|
1385
|
+
create: create$w
|
|
1386
1386
|
});
|
|
1387
1387
|
|
|
1388
|
-
const getBaseUrl$
|
|
1389
|
-
const getMany$
|
|
1390
|
-
return get$
|
|
1388
|
+
const getBaseUrl$p = (params) => `/organizations/${params.organizationId}/available_licenses`;
|
|
1389
|
+
const getMany$H = (http, params) => {
|
|
1390
|
+
return get$19(http, getBaseUrl$p(params), {
|
|
1391
1391
|
params: params.query,
|
|
1392
1392
|
});
|
|
1393
1393
|
};
|
|
1394
1394
|
|
|
1395
1395
|
var AvailableLicense = /*#__PURE__*/Object.freeze({
|
|
1396
1396
|
__proto__: null,
|
|
1397
|
-
getMany: getMany$
|
|
1397
|
+
getMany: getMany$H
|
|
1398
1398
|
});
|
|
1399
1399
|
|
|
1400
|
-
const get$
|
|
1401
|
-
return get$
|
|
1400
|
+
const get$P = (http, params) => {
|
|
1401
|
+
return get$19(http, `/spaces/${params.spaceId}/environments/${params.environmentId}/bulk_actions/actions/${params.bulkActionId}`);
|
|
1402
1402
|
};
|
|
1403
|
-
const publish$
|
|
1403
|
+
const publish$8 = (http, params, payload) => {
|
|
1404
1404
|
return post$1(http, `/spaces/${params.spaceId}/environments/${params.environmentId}/bulk_actions/publish`, payload);
|
|
1405
1405
|
};
|
|
1406
|
-
const unpublish$
|
|
1406
|
+
const unpublish$8 = (http, params, payload) => {
|
|
1407
1407
|
return post$1(http, `/spaces/${params.spaceId}/environments/${params.environmentId}/bulk_actions/unpublish`, payload);
|
|
1408
1408
|
};
|
|
1409
1409
|
const validate$2 = (http, params, payload) => {
|
|
1410
1410
|
return post$1(http, `/spaces/${params.spaceId}/environments/${params.environmentId}/bulk_actions/validate`, payload);
|
|
1411
1411
|
};
|
|
1412
1412
|
const getV2 = (http, params) => {
|
|
1413
|
-
return get$
|
|
1413
|
+
return get$19(http, `/spaces/${params.spaceId}/environments/${params.environmentId}/bulk_actions/${params.bulkActionId}`);
|
|
1414
1414
|
};
|
|
1415
1415
|
const publishV2 = (http, params, payload) => {
|
|
1416
1416
|
return post$1(http, `/spaces/${params.spaceId}/environments/${params.environmentId}/bulk_actions`, payload);
|
|
@@ -1424,11 +1424,11 @@ const validateV2 = (http, params, payload) => {
|
|
|
1424
1424
|
|
|
1425
1425
|
var BulkAction = /*#__PURE__*/Object.freeze({
|
|
1426
1426
|
__proto__: null,
|
|
1427
|
-
get: get$
|
|
1427
|
+
get: get$P,
|
|
1428
1428
|
getV2: getV2,
|
|
1429
|
-
publish: publish$
|
|
1429
|
+
publish: publish$8,
|
|
1430
1430
|
publishV2: publishV2,
|
|
1431
|
-
unpublish: unpublish$
|
|
1431
|
+
unpublish: unpublish$8,
|
|
1432
1432
|
unpublishV2: unpublishV2,
|
|
1433
1433
|
validate: validate$2,
|
|
1434
1434
|
validateV2: validateV2
|
|
@@ -1470,14 +1470,14 @@ const getEntityBaseUrl = (paramsOrg) => {
|
|
|
1470
1470
|
const versionPath = 'parentEntityVersion' in params ? `/versions/${params.parentEntityVersion}` : '';
|
|
1471
1471
|
return `${getSpaceEnvBaseUrl(params)}/${parentPlural}/${parentEntityId}${versionPath}/comments`;
|
|
1472
1472
|
};
|
|
1473
|
-
const get$
|
|
1473
|
+
const get$O = (http, params) => get$19(http, getEntityCommentUrl(params), {
|
|
1474
1474
|
headers: params.bodyFormat === 'rich-text'
|
|
1475
1475
|
? {
|
|
1476
1476
|
[BODY_FORMAT_HEADER]: params.bodyFormat,
|
|
1477
1477
|
}
|
|
1478
1478
|
: {},
|
|
1479
1479
|
});
|
|
1480
|
-
const getMany$
|
|
1480
|
+
const getMany$G = (http, params) => get$19(http, getEntityBaseUrl(params), {
|
|
1481
1481
|
params: normalizeSelect(params.query),
|
|
1482
1482
|
headers: params.bodyFormat === 'rich-text'
|
|
1483
1483
|
? {
|
|
@@ -1485,7 +1485,7 @@ const getMany$C = (http, params) => get$14(http, getEntityBaseUrl(params), {
|
|
|
1485
1485
|
}
|
|
1486
1486
|
: {},
|
|
1487
1487
|
});
|
|
1488
|
-
const create$
|
|
1488
|
+
const create$v = (http, params, rawData) => {
|
|
1489
1489
|
const data = copy__default.default(rawData);
|
|
1490
1490
|
return post$1(http, getEntityBaseUrl(params), data, {
|
|
1491
1491
|
headers: {
|
|
@@ -1497,7 +1497,7 @@ const create$q = (http, params, rawData) => {
|
|
|
1497
1497
|
},
|
|
1498
1498
|
});
|
|
1499
1499
|
};
|
|
1500
|
-
const update$
|
|
1500
|
+
const update$u = (http, params, rawData, headers) => {
|
|
1501
1501
|
const data = copy__default.default(rawData);
|
|
1502
1502
|
delete data.sys;
|
|
1503
1503
|
return put$1(http, getEntityCommentUrl(params), data, {
|
|
@@ -1508,8 +1508,8 @@ const update$s = (http, params, rawData, headers) => {
|
|
|
1508
1508
|
},
|
|
1509
1509
|
});
|
|
1510
1510
|
};
|
|
1511
|
-
const del$
|
|
1512
|
-
return del$
|
|
1511
|
+
const del$x = (http, { version, ...params }) => {
|
|
1512
|
+
return del$M(http, getEntityCommentUrl(params), {
|
|
1513
1513
|
headers: { [VERSION_HEADER]: version },
|
|
1514
1514
|
});
|
|
1515
1515
|
};
|
|
@@ -1517,35 +1517,80 @@ const del$s = (http, { version, ...params }) => {
|
|
|
1517
1517
|
/**
|
|
1518
1518
|
* @deprecated use `getMany` instead.
|
|
1519
1519
|
*/
|
|
1520
|
-
const getAll$1 = getMany$
|
|
1520
|
+
const getAll$1 = getMany$G;
|
|
1521
1521
|
|
|
1522
1522
|
var Comment = /*#__PURE__*/Object.freeze({
|
|
1523
1523
|
__proto__: null,
|
|
1524
|
-
create: create$
|
|
1525
|
-
del: del$
|
|
1526
|
-
get: get$
|
|
1524
|
+
create: create$v,
|
|
1525
|
+
del: del$x,
|
|
1526
|
+
get: get$O,
|
|
1527
1527
|
getAll: getAll$1,
|
|
1528
|
-
getMany: getMany$
|
|
1529
|
-
update: update$
|
|
1528
|
+
getMany: getMany$G,
|
|
1529
|
+
update: update$u
|
|
1530
1530
|
});
|
|
1531
1531
|
|
|
1532
|
-
const getBaseUrl$
|
|
1533
|
-
const getMany$
|
|
1534
|
-
return get$
|
|
1532
|
+
const getBaseUrl$o = (params) => `/spaces/${params.spaceId}/environments/${params.environmentId}/component_types`;
|
|
1533
|
+
const getMany$F = (http, params, headers) => {
|
|
1534
|
+
return get$19(http, getBaseUrl$o(params), {
|
|
1535
1535
|
params: params.query,
|
|
1536
1536
|
headers,
|
|
1537
1537
|
});
|
|
1538
1538
|
};
|
|
1539
|
+
const get$N = (http, params, headers) => {
|
|
1540
|
+
return get$19(http, getBaseUrl$o(params) + `/${params.componentTypeId}`, {
|
|
1541
|
+
headers,
|
|
1542
|
+
});
|
|
1543
|
+
};
|
|
1544
|
+
const create$u = (http, params, rawData, headers) => {
|
|
1545
|
+
const data = copy__default.default(rawData);
|
|
1546
|
+
return post$1(http, getBaseUrl$o(params), data, { headers });
|
|
1547
|
+
};
|
|
1548
|
+
const upsert$4 = (http, params, rawData, headers) => {
|
|
1549
|
+
const { sys, ...body } = copy__default.default(rawData);
|
|
1550
|
+
return put$1(http, getBaseUrl$o(params) + `/${params.componentTypeId}`, body, {
|
|
1551
|
+
headers: {
|
|
1552
|
+
...(sys.version !== undefined && {
|
|
1553
|
+
'X-Contentful-Version': sys.version,
|
|
1554
|
+
}),
|
|
1555
|
+
...headers,
|
|
1556
|
+
},
|
|
1557
|
+
});
|
|
1558
|
+
};
|
|
1559
|
+
const del$w = (http, params) => {
|
|
1560
|
+
return del$M(http, getBaseUrl$o(params) + `/${params.componentTypeId}`);
|
|
1561
|
+
};
|
|
1562
|
+
const publish$7 = (http, params, headers) => {
|
|
1563
|
+
return put$1(http, `${getBaseUrl$o(params)}/${params.componentTypeId}/published`, null, {
|
|
1564
|
+
headers: {
|
|
1565
|
+
'X-Contentful-Version': params.version,
|
|
1566
|
+
...headers,
|
|
1567
|
+
},
|
|
1568
|
+
});
|
|
1569
|
+
};
|
|
1570
|
+
const unpublish$7 = (http, params, headers) => {
|
|
1571
|
+
return del$M(http, `${getBaseUrl$o(params)}/${params.componentTypeId}/published`, {
|
|
1572
|
+
headers: {
|
|
1573
|
+
'X-Contentful-Version': params.version,
|
|
1574
|
+
...headers,
|
|
1575
|
+
},
|
|
1576
|
+
});
|
|
1577
|
+
};
|
|
1539
1578
|
|
|
1540
1579
|
var ComponentType = /*#__PURE__*/Object.freeze({
|
|
1541
1580
|
__proto__: null,
|
|
1542
|
-
|
|
1581
|
+
create: create$u,
|
|
1582
|
+
del: del$w,
|
|
1583
|
+
get: get$N,
|
|
1584
|
+
getMany: getMany$F,
|
|
1585
|
+
publish: publish$7,
|
|
1586
|
+
unpublish: unpublish$7,
|
|
1587
|
+
upsert: upsert$4
|
|
1543
1588
|
});
|
|
1544
1589
|
|
|
1545
1590
|
function basePath$1(organizationId) {
|
|
1546
1591
|
return `/organizations/${organizationId}/taxonomy/concepts`;
|
|
1547
1592
|
}
|
|
1548
|
-
const create$
|
|
1593
|
+
const create$t = (http, params, data) => {
|
|
1549
1594
|
return post$1(http, basePath$1(params.organizationId), data);
|
|
1550
1595
|
};
|
|
1551
1596
|
const createWithId$b = (http, params, data) => {
|
|
@@ -1560,7 +1605,7 @@ const patch$4 = (http, params, data, headers) => {
|
|
|
1560
1605
|
},
|
|
1561
1606
|
});
|
|
1562
1607
|
};
|
|
1563
|
-
const update$
|
|
1608
|
+
const update$t = (http, params, data, headers) => {
|
|
1564
1609
|
return put$1(http, `${basePath$1(params.organizationId)}/${params.conceptId}`, data, {
|
|
1565
1610
|
headers: {
|
|
1566
1611
|
'X-Contentful-Version': params.version,
|
|
@@ -1568,28 +1613,28 @@ const update$r = (http, params, data, headers) => {
|
|
|
1568
1613
|
},
|
|
1569
1614
|
});
|
|
1570
1615
|
};
|
|
1571
|
-
const get$
|
|
1572
|
-
const del$
|
|
1616
|
+
const get$M = (http, params) => get$19(http, `${basePath$1(params.organizationId)}/${params.conceptId}`);
|
|
1617
|
+
const del$v = (http, params, headers) => del$M(http, `${basePath$1(params.organizationId)}/${params.conceptId}`, {
|
|
1573
1618
|
headers: {
|
|
1574
1619
|
'X-Contentful-Version': params.version ?? 0,
|
|
1575
1620
|
...headers,
|
|
1576
1621
|
},
|
|
1577
1622
|
});
|
|
1578
|
-
const getMany$
|
|
1623
|
+
const getMany$E = (http, params) => {
|
|
1579
1624
|
const { url, queryParams } = cursorBasedCollection('', params);
|
|
1580
|
-
return get$
|
|
1625
|
+
return get$19(http, url, {
|
|
1581
1626
|
params: queryParams,
|
|
1582
1627
|
});
|
|
1583
1628
|
};
|
|
1584
1629
|
const getDescendants = (http, params) => {
|
|
1585
1630
|
const { url, queryParams } = cursorBasedCollection(`/${params.conceptId}/descendants`, params);
|
|
1586
|
-
return get$
|
|
1631
|
+
return get$19(http, url, { params: queryParams });
|
|
1587
1632
|
};
|
|
1588
1633
|
const getAncestors = (http, params) => {
|
|
1589
1634
|
const { url, queryParams } = cursorBasedCollection(`/${params.conceptId}/ancestors`, params);
|
|
1590
|
-
return get$
|
|
1635
|
+
return get$19(http, url, { params: queryParams });
|
|
1591
1636
|
};
|
|
1592
|
-
const getTotal$1 = (http, params) => get$
|
|
1637
|
+
const getTotal$1 = (http, params) => get$19(http, `${basePath$1(params.organizationId)}/total`);
|
|
1593
1638
|
function cursorBasedCollection(path, params) {
|
|
1594
1639
|
return params.query?.pageUrl
|
|
1595
1640
|
? { url: params.query?.pageUrl }
|
|
@@ -1601,36 +1646,36 @@ function cursorBasedCollection(path, params) {
|
|
|
1601
1646
|
|
|
1602
1647
|
var Concept = /*#__PURE__*/Object.freeze({
|
|
1603
1648
|
__proto__: null,
|
|
1604
|
-
create: create$
|
|
1649
|
+
create: create$t,
|
|
1605
1650
|
createWithId: createWithId$b,
|
|
1606
|
-
del: del$
|
|
1607
|
-
get: get$
|
|
1651
|
+
del: del$v,
|
|
1652
|
+
get: get$M,
|
|
1608
1653
|
getAncestors: getAncestors,
|
|
1609
1654
|
getDescendants: getDescendants,
|
|
1610
|
-
getMany: getMany$
|
|
1655
|
+
getMany: getMany$E,
|
|
1611
1656
|
getTotal: getTotal$1,
|
|
1612
1657
|
patch: patch$4,
|
|
1613
|
-
update: update$
|
|
1658
|
+
update: update$t
|
|
1614
1659
|
});
|
|
1615
1660
|
|
|
1616
1661
|
function basePath(orgId) {
|
|
1617
1662
|
return `/organizations/${orgId}/taxonomy/concept-schemes`;
|
|
1618
1663
|
}
|
|
1619
|
-
const get$
|
|
1620
|
-
const del$
|
|
1664
|
+
const get$L = (http, params) => get$19(http, `${basePath(params.organizationId)}/${params.conceptSchemeId}`);
|
|
1665
|
+
const del$u = (http, params, headers) => del$M(http, `${basePath(params.organizationId)}/${params.conceptSchemeId}`, {
|
|
1621
1666
|
headers: {
|
|
1622
1667
|
'X-Contentful-Version': params.version,
|
|
1623
1668
|
...headers,
|
|
1624
1669
|
},
|
|
1625
1670
|
});
|
|
1626
|
-
const getMany$
|
|
1671
|
+
const getMany$D = (http, params) => {
|
|
1627
1672
|
const url = params.query?.pageUrl ?? basePath(params.organizationId);
|
|
1628
|
-
return get$
|
|
1673
|
+
return get$19(http, url, {
|
|
1629
1674
|
params: params.query?.pageUrl ? undefined : params.query,
|
|
1630
1675
|
});
|
|
1631
1676
|
};
|
|
1632
|
-
const getTotal = (http, params) => get$
|
|
1633
|
-
const create$
|
|
1677
|
+
const getTotal = (http, params) => get$19(http, `${basePath(params.organizationId)}/total`);
|
|
1678
|
+
const create$s = (http, params, data) => {
|
|
1634
1679
|
return post$1(http, basePath(params.organizationId), data);
|
|
1635
1680
|
};
|
|
1636
1681
|
const createWithId$a = (http, params, data) => {
|
|
@@ -1645,7 +1690,7 @@ const patch$3 = (http, params, data, headers) => {
|
|
|
1645
1690
|
},
|
|
1646
1691
|
});
|
|
1647
1692
|
};
|
|
1648
|
-
const update$
|
|
1693
|
+
const update$s = (http, params, data, headers) => {
|
|
1649
1694
|
return put$1(http, `${basePath(params.organizationId)}/${params.conceptSchemeId}`, data, {
|
|
1650
1695
|
headers: {
|
|
1651
1696
|
'X-Contentful-Version': params.version,
|
|
@@ -1656,39 +1701,39 @@ const update$q = (http, params, data, headers) => {
|
|
|
1656
1701
|
|
|
1657
1702
|
var ConceptScheme = /*#__PURE__*/Object.freeze({
|
|
1658
1703
|
__proto__: null,
|
|
1659
|
-
create: create$
|
|
1704
|
+
create: create$s,
|
|
1660
1705
|
createWithId: createWithId$a,
|
|
1661
|
-
del: del$
|
|
1662
|
-
get: get$
|
|
1663
|
-
getMany: getMany$
|
|
1706
|
+
del: del$u,
|
|
1707
|
+
get: get$L,
|
|
1708
|
+
getMany: getMany$D,
|
|
1664
1709
|
getTotal: getTotal,
|
|
1665
1710
|
patch: patch$3,
|
|
1666
|
-
update: update$
|
|
1711
|
+
update: update$s
|
|
1667
1712
|
});
|
|
1668
1713
|
|
|
1669
|
-
const getBaseUrl$
|
|
1670
|
-
const getContentTypeUrl$1 = (params) => getBaseUrl$
|
|
1671
|
-
const get$
|
|
1672
|
-
return get$
|
|
1714
|
+
const getBaseUrl$n = (params) => `/spaces/${params.spaceId}/environments/${params.environmentId}/content_types`;
|
|
1715
|
+
const getContentTypeUrl$1 = (params) => getBaseUrl$n(params) + `/${params.contentTypeId}`;
|
|
1716
|
+
const get$K = (http, params, headers) => {
|
|
1717
|
+
return get$19(http, getContentTypeUrl$1(params), {
|
|
1673
1718
|
params: normalizeSelect(params.query),
|
|
1674
1719
|
headers,
|
|
1675
1720
|
});
|
|
1676
1721
|
};
|
|
1677
|
-
const getMany$
|
|
1678
|
-
return get$
|
|
1722
|
+
const getMany$C = (http, params, headers) => {
|
|
1723
|
+
return get$19(http, getBaseUrl$n(params), {
|
|
1679
1724
|
params: params.query,
|
|
1680
1725
|
headers,
|
|
1681
1726
|
});
|
|
1682
1727
|
};
|
|
1683
|
-
const create$
|
|
1728
|
+
const create$r = (http, params, rawData, headers) => {
|
|
1684
1729
|
const data = copy__default.default(rawData);
|
|
1685
|
-
return post$1(http, getBaseUrl$
|
|
1730
|
+
return post$1(http, getBaseUrl$n(params), data, { headers });
|
|
1686
1731
|
};
|
|
1687
1732
|
const createWithId$9 = (http, params, rawData, headers) => {
|
|
1688
1733
|
const data = copy__default.default(rawData);
|
|
1689
1734
|
return put$1(http, getContentTypeUrl$1(params), data, { headers });
|
|
1690
1735
|
};
|
|
1691
|
-
const update$
|
|
1736
|
+
const update$r = (http, params, rawData, headers) => {
|
|
1692
1737
|
const data = copy__default.default(rawData);
|
|
1693
1738
|
delete data.sys;
|
|
1694
1739
|
return put$1(http, getContentTypeUrl$1(params), data, {
|
|
@@ -1698,10 +1743,10 @@ const update$p = (http, params, rawData, headers) => {
|
|
|
1698
1743
|
},
|
|
1699
1744
|
});
|
|
1700
1745
|
};
|
|
1701
|
-
const del$
|
|
1702
|
-
return del$
|
|
1746
|
+
const del$t = (http, params, headers) => {
|
|
1747
|
+
return del$M(http, getContentTypeUrl$1(params), { headers });
|
|
1703
1748
|
};
|
|
1704
|
-
const publish$
|
|
1749
|
+
const publish$6 = (http, params, rawData, headers) => {
|
|
1705
1750
|
return put$1(http, getContentTypeUrl$1(params) + '/published', null, {
|
|
1706
1751
|
headers: {
|
|
1707
1752
|
'X-Contentful-Version': rawData.sys.version,
|
|
@@ -1709,33 +1754,103 @@ const publish$2 = (http, params, rawData, headers) => {
|
|
|
1709
1754
|
},
|
|
1710
1755
|
});
|
|
1711
1756
|
};
|
|
1712
|
-
const unpublish$
|
|
1713
|
-
return del$
|
|
1757
|
+
const unpublish$6 = (http, params, headers) => {
|
|
1758
|
+
return del$M(http, getContentTypeUrl$1(params) + '/published', { headers });
|
|
1714
1759
|
};
|
|
1715
1760
|
|
|
1716
1761
|
var ContentType = /*#__PURE__*/Object.freeze({
|
|
1717
1762
|
__proto__: null,
|
|
1718
|
-
create: create$
|
|
1763
|
+
create: create$r,
|
|
1719
1764
|
createWithId: createWithId$9,
|
|
1720
|
-
del: del$
|
|
1721
|
-
get: get$
|
|
1722
|
-
getMany: getMany$
|
|
1723
|
-
publish: publish$
|
|
1724
|
-
unpublish: unpublish$
|
|
1725
|
-
update: update$
|
|
1765
|
+
del: del$t,
|
|
1766
|
+
get: get$K,
|
|
1767
|
+
getMany: getMany$C,
|
|
1768
|
+
publish: publish$6,
|
|
1769
|
+
unpublish: unpublish$6,
|
|
1770
|
+
update: update$r
|
|
1726
1771
|
});
|
|
1727
1772
|
|
|
1728
|
-
const getBaseUrl$
|
|
1729
|
-
const
|
|
1730
|
-
|
|
1773
|
+
const getBaseUrl$m = (params) => `/spaces/${params.spaceId}/environments/${params.environmentId}/data_assemblies`;
|
|
1774
|
+
const getPublicUrl = (params) => `/spaces/${params.spaceId}/environments/${params.environmentId}/public/data_assemblies`;
|
|
1775
|
+
const getMany$B = (http, params, headers) => {
|
|
1776
|
+
return get$19(http, getBaseUrl$m(params), {
|
|
1777
|
+
params: params.query,
|
|
1778
|
+
headers,
|
|
1779
|
+
});
|
|
1780
|
+
};
|
|
1781
|
+
const get$J = (http, params, headers) => {
|
|
1782
|
+
return get$19(http, getBaseUrl$m(params) + `/${params.dataAssemblyId}`, {
|
|
1783
|
+
headers,
|
|
1784
|
+
});
|
|
1731
1785
|
};
|
|
1732
|
-
const
|
|
1733
|
-
|
|
1786
|
+
const create$q = (http, params, rawData, headers) => {
|
|
1787
|
+
const data = copy__default.default(rawData);
|
|
1788
|
+
return post$1(http, getBaseUrl$m(params), data, { headers });
|
|
1734
1789
|
};
|
|
1735
|
-
const update$
|
|
1790
|
+
const update$q = (http, params, rawData, headers) => {
|
|
1791
|
+
const data = copy__default.default(rawData);
|
|
1792
|
+
return put$1(http, getBaseUrl$m(params) + `/${params.dataAssemblyId}`, data, {
|
|
1793
|
+
headers: {
|
|
1794
|
+
'X-Contentful-Version': rawData.sys.version ?? 0,
|
|
1795
|
+
...headers,
|
|
1796
|
+
},
|
|
1797
|
+
});
|
|
1798
|
+
};
|
|
1799
|
+
const del$s = (http, params) => {
|
|
1800
|
+
return del$M(http, getBaseUrl$m(params) + `/${params.dataAssemblyId}`);
|
|
1801
|
+
};
|
|
1802
|
+
const publish$5 = (http, params, headers) => {
|
|
1803
|
+
return put$1(http, `${getBaseUrl$m(params)}/${params.dataAssemblyId}/published`, null, {
|
|
1804
|
+
headers: {
|
|
1805
|
+
'X-Contentful-Version': params.version,
|
|
1806
|
+
...headers,
|
|
1807
|
+
},
|
|
1808
|
+
});
|
|
1809
|
+
};
|
|
1810
|
+
const getPublished$1 = (http, params, headers) => {
|
|
1811
|
+
return get$19(http, getPublicUrl(params) + `/${params.dataAssemblyId}`, {
|
|
1812
|
+
headers,
|
|
1813
|
+
});
|
|
1814
|
+
};
|
|
1815
|
+
const getManyPublished = (http, params, headers) => {
|
|
1816
|
+
return get$19(http, getPublicUrl(params), {
|
|
1817
|
+
params: params.query,
|
|
1818
|
+
headers,
|
|
1819
|
+
});
|
|
1820
|
+
};
|
|
1821
|
+
const unpublish$5 = (http, params, headers) => {
|
|
1822
|
+
return del$M(http, `${getBaseUrl$m(params)}/${params.dataAssemblyId}/published`, {
|
|
1823
|
+
headers: {
|
|
1824
|
+
'X-Contentful-Version': params.version,
|
|
1825
|
+
...headers,
|
|
1826
|
+
},
|
|
1827
|
+
});
|
|
1828
|
+
};
|
|
1829
|
+
|
|
1830
|
+
var DataAssembly = /*#__PURE__*/Object.freeze({
|
|
1831
|
+
__proto__: null,
|
|
1832
|
+
create: create$q,
|
|
1833
|
+
del: del$s,
|
|
1834
|
+
get: get$J,
|
|
1835
|
+
getMany: getMany$B,
|
|
1836
|
+
getManyPublished: getManyPublished,
|
|
1837
|
+
getPublished: getPublished$1,
|
|
1838
|
+
publish: publish$5,
|
|
1839
|
+
unpublish: unpublish$5,
|
|
1840
|
+
update: update$q
|
|
1841
|
+
});
|
|
1842
|
+
|
|
1843
|
+
const getBaseUrl$l = (params) => `/spaces/${params.spaceId}/environments/${params.environmentId}/content_types/${params.contentTypeId}/editor_interface`;
|
|
1844
|
+
const get$I = (http, params) => {
|
|
1845
|
+
return get$19(http, getBaseUrl$l(params));
|
|
1846
|
+
};
|
|
1847
|
+
const getMany$A = (http, params) => {
|
|
1848
|
+
return get$19(http, `/spaces/${params.spaceId}/environments/${params.environmentId}/editor_interfaces`);
|
|
1849
|
+
};
|
|
1850
|
+
const update$p = (http, params, rawData, headers) => {
|
|
1736
1851
|
const data = copy__default.default(rawData);
|
|
1737
1852
|
delete data.sys;
|
|
1738
|
-
return put$1(http, getBaseUrl$
|
|
1853
|
+
return put$1(http, getBaseUrl$l(params), data, {
|
|
1739
1854
|
headers: {
|
|
1740
1855
|
'X-Contentful-Version': rawData.sys.version ?? 0,
|
|
1741
1856
|
...headers,
|
|
@@ -1745,36 +1860,36 @@ const update$o = (http, params, rawData, headers) => {
|
|
|
1745
1860
|
|
|
1746
1861
|
var EditorInterface = /*#__PURE__*/Object.freeze({
|
|
1747
1862
|
__proto__: null,
|
|
1748
|
-
get: get$
|
|
1749
|
-
getMany: getMany$
|
|
1750
|
-
update: update$
|
|
1863
|
+
get: get$I,
|
|
1864
|
+
getMany: getMany$A,
|
|
1865
|
+
update: update$p
|
|
1751
1866
|
});
|
|
1752
1867
|
|
|
1753
|
-
const getBaseUrl$
|
|
1754
|
-
const getMany$
|
|
1755
|
-
return get$
|
|
1868
|
+
const getBaseUrl$k = (params) => `/spaces/${params.spaceId}/eligible_licenses`;
|
|
1869
|
+
const getMany$z = (http, params) => {
|
|
1870
|
+
return get$19(http, getBaseUrl$k(params), {
|
|
1756
1871
|
params: params.query,
|
|
1757
1872
|
});
|
|
1758
1873
|
};
|
|
1759
1874
|
|
|
1760
1875
|
var EligibleLicense = /*#__PURE__*/Object.freeze({
|
|
1761
1876
|
__proto__: null,
|
|
1762
|
-
getMany: getMany$
|
|
1877
|
+
getMany: getMany$z
|
|
1763
1878
|
});
|
|
1764
1879
|
|
|
1765
|
-
const get$
|
|
1766
|
-
return get$
|
|
1880
|
+
const get$H = (http, params, rawData, headers) => {
|
|
1881
|
+
return get$19(http, `/spaces/${params.spaceId}/environments/${params.environmentId}/releases/${params.releaseId}/entries/${params.entryId}`, {
|
|
1767
1882
|
params: normalizeSelect(params.query),
|
|
1768
1883
|
headers: { ...headers },
|
|
1769
1884
|
});
|
|
1770
1885
|
};
|
|
1771
|
-
const getMany$
|
|
1772
|
-
return get$
|
|
1886
|
+
const getMany$y = (http, params, rawData, headers) => {
|
|
1887
|
+
return get$19(http, `/spaces/${params.spaceId}/environments/${params.environmentId}/releases/${params.releaseId}/entries`, {
|
|
1773
1888
|
params: normalizeSelect(params.query),
|
|
1774
1889
|
headers: { ...headers },
|
|
1775
1890
|
});
|
|
1776
1891
|
};
|
|
1777
|
-
const update$
|
|
1892
|
+
const update$o = (http, params, rawData, headers) => {
|
|
1778
1893
|
const data = copy__default.default(rawData);
|
|
1779
1894
|
delete data.sys;
|
|
1780
1895
|
return put$1(http, `/spaces/${params.spaceId}/environments/${params.environmentId}/releases/${params.releaseId}/entries/${params.entryId}`, data, {
|
|
@@ -1793,7 +1908,7 @@ const patch$2 = (http, params, data, headers) => {
|
|
|
1793
1908
|
},
|
|
1794
1909
|
});
|
|
1795
1910
|
};
|
|
1796
|
-
const create$
|
|
1911
|
+
const create$p = (http, params, rawData, headers) => {
|
|
1797
1912
|
const data = copy__default.default(rawData);
|
|
1798
1913
|
return post$1(http, `/spaces/${params.spaceId}/environments/${params.environmentId}/releases/${params.releaseId}/entries`, data, {
|
|
1799
1914
|
headers: {
|
|
@@ -1814,34 +1929,34 @@ const createWithId$8 = (http, params, rawData, headers) => {
|
|
|
1814
1929
|
|
|
1815
1930
|
var ReleaseEntry = /*#__PURE__*/Object.freeze({
|
|
1816
1931
|
__proto__: null,
|
|
1817
|
-
create: create$
|
|
1932
|
+
create: create$p,
|
|
1818
1933
|
createWithId: createWithId$8,
|
|
1819
|
-
get: get$
|
|
1820
|
-
getMany: getMany$
|
|
1934
|
+
get: get$H,
|
|
1935
|
+
getMany: getMany$y,
|
|
1821
1936
|
patch: patch$2,
|
|
1822
|
-
update: update$
|
|
1937
|
+
update: update$o
|
|
1823
1938
|
});
|
|
1824
1939
|
|
|
1825
|
-
const get$
|
|
1940
|
+
const get$G = (http, params, rawData, headers) => {
|
|
1826
1941
|
if (params.releaseId) {
|
|
1827
|
-
return get$
|
|
1942
|
+
return get$H(http, params);
|
|
1828
1943
|
}
|
|
1829
|
-
return get$
|
|
1944
|
+
return get$19(http, `/spaces/${params.spaceId}/environments/${params.environmentId}/entries/${params.entryId}`, {
|
|
1830
1945
|
params: normalizeSelect(params.query),
|
|
1831
1946
|
headers: { ...headers },
|
|
1832
1947
|
});
|
|
1833
1948
|
};
|
|
1834
1949
|
const getPublished = (http, params, rawData, headers) => {
|
|
1835
|
-
return get$
|
|
1950
|
+
return get$19(http, `/spaces/${params.spaceId}/environments/${params.environmentId}/public/entries`, {
|
|
1836
1951
|
params: normalizeSelect(params.query),
|
|
1837
1952
|
headers: { ...headers },
|
|
1838
1953
|
});
|
|
1839
1954
|
};
|
|
1840
|
-
const getMany$
|
|
1955
|
+
const getMany$x = (http, params, rawData, headers) => {
|
|
1841
1956
|
if (params.releaseId) {
|
|
1842
|
-
return getMany$
|
|
1957
|
+
return getMany$y(http, params);
|
|
1843
1958
|
}
|
|
1844
|
-
return get$
|
|
1959
|
+
return get$19(http, `/spaces/${params.spaceId}/environments/${params.environmentId}/entries`, {
|
|
1845
1960
|
params: normalizeSelect(params.query),
|
|
1846
1961
|
headers: { ...headers },
|
|
1847
1962
|
});
|
|
@@ -1858,9 +1973,9 @@ const patch$1 = (http, params, data, headers) => {
|
|
|
1858
1973
|
},
|
|
1859
1974
|
});
|
|
1860
1975
|
};
|
|
1861
|
-
const update$
|
|
1976
|
+
const update$n = (http, params, rawData, headers) => {
|
|
1862
1977
|
if (params.releaseId) {
|
|
1863
|
-
return update$
|
|
1978
|
+
return update$o(http, params, rawData, headers ?? {});
|
|
1864
1979
|
}
|
|
1865
1980
|
const data = copy__default.default(rawData);
|
|
1866
1981
|
delete data.sys;
|
|
@@ -1871,10 +1986,10 @@ const update$m = (http, params, rawData, headers) => {
|
|
|
1871
1986
|
},
|
|
1872
1987
|
});
|
|
1873
1988
|
};
|
|
1874
|
-
const del$
|
|
1875
|
-
return del$
|
|
1989
|
+
const del$r = (http, params) => {
|
|
1990
|
+
return del$M(http, `/spaces/${params.spaceId}/environments/${params.environmentId}/entries/${params.entryId}`);
|
|
1876
1991
|
};
|
|
1877
|
-
const publish$
|
|
1992
|
+
const publish$4 = (http, params, rawData) => {
|
|
1878
1993
|
const payload = params.locales?.length ? { add: { fields: { '*': params.locales } } } : null;
|
|
1879
1994
|
return put$1(http, `/spaces/${params.spaceId}/environments/${params.environmentId}/entries/${params.entryId}/published`, payload, {
|
|
1880
1995
|
headers: {
|
|
@@ -1882,7 +1997,7 @@ const publish$1 = (http, params, rawData) => {
|
|
|
1882
1997
|
},
|
|
1883
1998
|
});
|
|
1884
1999
|
};
|
|
1885
|
-
const unpublish$
|
|
2000
|
+
const unpublish$4 = (http, params, rawData) => {
|
|
1886
2001
|
if (params.locales?.length) {
|
|
1887
2002
|
const payload = { remove: { fields: { '*': params.locales } } };
|
|
1888
2003
|
return put$1(http, `/spaces/${params.spaceId}/environments/${params.environmentId}/entries/${params.entryId}/published`, payload, {
|
|
@@ -1892,18 +2007,18 @@ const unpublish$1 = (http, params, rawData) => {
|
|
|
1892
2007
|
});
|
|
1893
2008
|
}
|
|
1894
2009
|
else {
|
|
1895
|
-
return del$
|
|
2010
|
+
return del$M(http, `/spaces/${params.spaceId}/environments/${params.environmentId}/entries/${params.entryId}/published`);
|
|
1896
2011
|
}
|
|
1897
2012
|
};
|
|
1898
2013
|
const archive$1 = (http, params) => {
|
|
1899
2014
|
return put$1(http, `/spaces/${params.spaceId}/environments/${params.environmentId}/entries/${params.entryId}/archived`);
|
|
1900
2015
|
};
|
|
1901
2016
|
const unarchive$2 = (http, params) => {
|
|
1902
|
-
return del$
|
|
2017
|
+
return del$M(http, `/spaces/${params.spaceId}/environments/${params.environmentId}/entries/${params.entryId}/archived`);
|
|
1903
2018
|
};
|
|
1904
|
-
const create$
|
|
2019
|
+
const create$o = (http, params, rawData) => {
|
|
1905
2020
|
if (params.releaseId) {
|
|
1906
|
-
return create$
|
|
2021
|
+
return create$p(http, params, rawData, {});
|
|
1907
2022
|
}
|
|
1908
2023
|
const data = copy__default.default(rawData);
|
|
1909
2024
|
return post$1(http, `/spaces/${params.spaceId}/environments/${params.environmentId}/entries`, data, {
|
|
@@ -1926,35 +2041,35 @@ const createWithId$7 = (http, params, rawData) => {
|
|
|
1926
2041
|
const references = (http, params) => {
|
|
1927
2042
|
const { spaceId, environmentId, entryId, include } = params;
|
|
1928
2043
|
const level = include || 2;
|
|
1929
|
-
return get$
|
|
2044
|
+
return get$19(http, `/spaces/${spaceId}/environments/${environmentId}/entries/${entryId}/references?include=${level}`);
|
|
1930
2045
|
};
|
|
1931
2046
|
|
|
1932
2047
|
var Entry = /*#__PURE__*/Object.freeze({
|
|
1933
2048
|
__proto__: null,
|
|
1934
2049
|
archive: archive$1,
|
|
1935
|
-
create: create$
|
|
2050
|
+
create: create$o,
|
|
1936
2051
|
createWithId: createWithId$7,
|
|
1937
|
-
del: del$
|
|
1938
|
-
get: get$
|
|
1939
|
-
getMany: getMany$
|
|
2052
|
+
del: del$r,
|
|
2053
|
+
get: get$G,
|
|
2054
|
+
getMany: getMany$x,
|
|
1940
2055
|
getPublished: getPublished,
|
|
1941
2056
|
patch: patch$1,
|
|
1942
|
-
publish: publish$
|
|
2057
|
+
publish: publish$4,
|
|
1943
2058
|
references: references,
|
|
1944
2059
|
unarchive: unarchive$2,
|
|
1945
|
-
unpublish: unpublish$
|
|
1946
|
-
update: update$
|
|
2060
|
+
unpublish: unpublish$4,
|
|
2061
|
+
update: update$n
|
|
1947
2062
|
});
|
|
1948
2063
|
|
|
1949
|
-
const get$
|
|
1950
|
-
return get$
|
|
2064
|
+
const get$F = (http, params) => {
|
|
2065
|
+
return get$19(http, `/spaces/${params.spaceId}/environments/${params.environmentId}`);
|
|
1951
2066
|
};
|
|
1952
|
-
const getMany$
|
|
1953
|
-
return get$
|
|
2067
|
+
const getMany$w = (http, params) => {
|
|
2068
|
+
return get$19(http, `/spaces/${params.spaceId}/environments`, {
|
|
1954
2069
|
params: params.query,
|
|
1955
2070
|
});
|
|
1956
2071
|
};
|
|
1957
|
-
const update$
|
|
2072
|
+
const update$m = (http, params, rawData, headers) => {
|
|
1958
2073
|
const data = copy__default.default(rawData);
|
|
1959
2074
|
delete data.sys;
|
|
1960
2075
|
return put$1(http, `/spaces/${params.spaceId}/environments/${params.environmentId}`, data, {
|
|
@@ -1964,10 +2079,10 @@ const update$l = (http, params, rawData, headers) => {
|
|
|
1964
2079
|
},
|
|
1965
2080
|
});
|
|
1966
2081
|
};
|
|
1967
|
-
const del$
|
|
1968
|
-
return del$
|
|
2082
|
+
const del$q = (http, params) => {
|
|
2083
|
+
return del$M(http, `/spaces/${params.spaceId}/environments/${params.environmentId}`);
|
|
1969
2084
|
};
|
|
1970
|
-
const create$
|
|
2085
|
+
const create$n = (http, params, rawData, headers) => {
|
|
1971
2086
|
const data = copy__default.default(rawData);
|
|
1972
2087
|
return post$1(http, `/spaces/${params.spaceId}/environments`, data, {
|
|
1973
2088
|
headers,
|
|
@@ -1989,27 +2104,27 @@ const createWithId$6 = (http, params, rawData, headers) => {
|
|
|
1989
2104
|
|
|
1990
2105
|
var Environment = /*#__PURE__*/Object.freeze({
|
|
1991
2106
|
__proto__: null,
|
|
1992
|
-
create: create$
|
|
2107
|
+
create: create$n,
|
|
1993
2108
|
createWithId: createWithId$6,
|
|
1994
|
-
del: del$
|
|
1995
|
-
get: get$
|
|
1996
|
-
getMany: getMany$
|
|
1997
|
-
update: update$
|
|
2109
|
+
del: del$q,
|
|
2110
|
+
get: get$F,
|
|
2111
|
+
getMany: getMany$w,
|
|
2112
|
+
update: update$m
|
|
1998
2113
|
});
|
|
1999
2114
|
|
|
2000
2115
|
/**
|
|
2001
2116
|
* Urls
|
|
2002
2117
|
*/
|
|
2003
|
-
const getBaseUrl$
|
|
2004
|
-
const getEnvironmentAliasUrl = (params) => getBaseUrl$
|
|
2118
|
+
const getBaseUrl$j = (params) => `/spaces/${params.spaceId}/environment_aliases`;
|
|
2119
|
+
const getEnvironmentAliasUrl = (params) => getBaseUrl$j(params) + `/${params.environmentAliasId}`;
|
|
2005
2120
|
/**
|
|
2006
2121
|
* Endpoints
|
|
2007
2122
|
*/
|
|
2008
|
-
const get$
|
|
2009
|
-
return get$
|
|
2123
|
+
const get$E = (http, params) => {
|
|
2124
|
+
return get$19(http, getEnvironmentAliasUrl(params));
|
|
2010
2125
|
};
|
|
2011
|
-
const getMany$
|
|
2012
|
-
return get$
|
|
2126
|
+
const getMany$v = (http, params) => {
|
|
2127
|
+
return get$19(http, getBaseUrl$j(params), {
|
|
2013
2128
|
params: params.query,
|
|
2014
2129
|
});
|
|
2015
2130
|
};
|
|
@@ -2019,7 +2134,7 @@ const createWithId$5 = (http, params, rawData, headers) => {
|
|
|
2019
2134
|
headers: headers,
|
|
2020
2135
|
});
|
|
2021
2136
|
};
|
|
2022
|
-
const update$
|
|
2137
|
+
const update$l = (http, params, rawData, headers) => {
|
|
2023
2138
|
const data = copy__default.default(rawData);
|
|
2024
2139
|
delete data.sys;
|
|
2025
2140
|
return put$1(http, getEnvironmentAliasUrl(params), data, {
|
|
@@ -2029,32 +2144,32 @@ const update$k = (http, params, rawData, headers) => {
|
|
|
2029
2144
|
},
|
|
2030
2145
|
});
|
|
2031
2146
|
};
|
|
2032
|
-
const del$
|
|
2033
|
-
return del$
|
|
2147
|
+
const del$p = (http, params) => {
|
|
2148
|
+
return del$M(http, getEnvironmentAliasUrl(params));
|
|
2034
2149
|
};
|
|
2035
2150
|
|
|
2036
2151
|
var EnvironmentAlias = /*#__PURE__*/Object.freeze({
|
|
2037
2152
|
__proto__: null,
|
|
2038
2153
|
createWithId: createWithId$5,
|
|
2039
|
-
del: del$
|
|
2040
|
-
get: get$
|
|
2041
|
-
getMany: getMany$
|
|
2042
|
-
update: update$
|
|
2154
|
+
del: del$p,
|
|
2155
|
+
get: get$E,
|
|
2156
|
+
getMany: getMany$v,
|
|
2157
|
+
update: update$l
|
|
2043
2158
|
});
|
|
2044
2159
|
|
|
2045
2160
|
const apiPath$1 = (organizationId, ...pathSegments) => `/organizations/${organizationId}/environment_templates/` + pathSegments.join('/');
|
|
2046
|
-
const get$
|
|
2047
|
-
? get$
|
|
2161
|
+
const get$D = (http, { organizationId, environmentTemplateId, version, query = {} }, headers) => version
|
|
2162
|
+
? get$19(http, apiPath$1(organizationId, environmentTemplateId, 'versions', version), {
|
|
2048
2163
|
params: query,
|
|
2049
2164
|
headers,
|
|
2050
2165
|
})
|
|
2051
|
-
: get$
|
|
2166
|
+
: get$19(http, apiPath$1(organizationId, environmentTemplateId), {
|
|
2052
2167
|
params: query,
|
|
2053
2168
|
headers,
|
|
2054
2169
|
});
|
|
2055
|
-
const getMany$
|
|
2056
|
-
const create$
|
|
2057
|
-
const update$
|
|
2170
|
+
const getMany$u = (http, { organizationId, query = {} }, headers) => get$19(http, apiPath$1(organizationId), { params: query, headers });
|
|
2171
|
+
const create$m = (http, { organizationId }, payload, headers) => post$1(http, apiPath$1(organizationId), payload, { headers });
|
|
2172
|
+
const update$k = (http, { organizationId, environmentTemplateId }, payload, headers) => {
|
|
2058
2173
|
const data = copy__default.default(payload);
|
|
2059
2174
|
delete data.sys;
|
|
2060
2175
|
return put$1(http, apiPath$1(organizationId, environmentTemplateId), data, {
|
|
@@ -2067,8 +2182,8 @@ const update$j = (http, { organizationId, environmentTemplateId }, payload, head
|
|
|
2067
2182
|
const versionUpdate = (http, { organizationId, version, environmentTemplateId }, payload, headers) => patch$5(http, apiPath$1(organizationId, environmentTemplateId, 'versions', version), payload, {
|
|
2068
2183
|
headers,
|
|
2069
2184
|
});
|
|
2070
|
-
const del$
|
|
2071
|
-
const versions = (http, { organizationId, environmentTemplateId, query = {} }, headers) => get$
|
|
2185
|
+
const del$o = (http, { organizationId, environmentTemplateId }, headers) => del$M(http, apiPath$1(organizationId, environmentTemplateId), { headers });
|
|
2186
|
+
const versions = (http, { organizationId, environmentTemplateId, query = {} }, headers) => get$19(http, apiPath$1(organizationId, environmentTemplateId, 'versions'), {
|
|
2072
2187
|
params: query,
|
|
2073
2188
|
headers,
|
|
2074
2189
|
});
|
|
@@ -2076,24 +2191,24 @@ const validate$1 = (http, { spaceId, environmentId, environmentTemplateId, versi
|
|
|
2076
2191
|
? `/spaces/${spaceId}/environments/${environmentId}/template_installations/${environmentTemplateId}/versions/${version}/validated`
|
|
2077
2192
|
: `/spaces/${spaceId}/environments/${environmentId}/template_installations/${environmentTemplateId}/validated`, payload, { headers });
|
|
2078
2193
|
const install = (http, { spaceId, environmentId, environmentTemplateId }, payload, headers) => post$1(http, `/spaces/${spaceId}/environments/${environmentId}/template_installations/${environmentTemplateId}/versions`, payload, { headers });
|
|
2079
|
-
const disconnect = (http, { spaceId, environmentId, environmentTemplateId }, headers) => del$
|
|
2194
|
+
const disconnect = (http, { spaceId, environmentId, environmentTemplateId }, headers) => del$M(http, `/spaces/${spaceId}/environments/${environmentId}/template_installations/${environmentTemplateId}`, { headers });
|
|
2080
2195
|
|
|
2081
2196
|
var EnvironmentTemplate = /*#__PURE__*/Object.freeze({
|
|
2082
2197
|
__proto__: null,
|
|
2083
|
-
create: create$
|
|
2084
|
-
del: del$
|
|
2198
|
+
create: create$m,
|
|
2199
|
+
del: del$o,
|
|
2085
2200
|
disconnect: disconnect,
|
|
2086
|
-
get: get$
|
|
2087
|
-
getMany: getMany$
|
|
2201
|
+
get: get$D,
|
|
2202
|
+
getMany: getMany$u,
|
|
2088
2203
|
install: install,
|
|
2089
|
-
update: update$
|
|
2204
|
+
update: update$k,
|
|
2090
2205
|
validate: validate$1,
|
|
2091
2206
|
versionUpdate: versionUpdate,
|
|
2092
2207
|
versions: versions
|
|
2093
2208
|
});
|
|
2094
2209
|
|
|
2095
2210
|
const apiPath = (organizationId, ...pathSegments) => `/organizations/${organizationId}/environment_templates/` + pathSegments.join('/');
|
|
2096
|
-
const getMany$
|
|
2211
|
+
const getMany$t = (http, { organizationId, environmentTemplateId, spaceId, environmentId, ...otherProps }, headers) => get$19(http, apiPath(organizationId, environmentTemplateId, 'template_installations'), {
|
|
2097
2212
|
params: {
|
|
2098
2213
|
...otherProps,
|
|
2099
2214
|
...(environmentId && { 'environment.sys.id': environmentId }),
|
|
@@ -2101,7 +2216,7 @@ const getMany$q = (http, { organizationId, environmentTemplateId, spaceId, envir
|
|
|
2101
2216
|
},
|
|
2102
2217
|
headers,
|
|
2103
2218
|
});
|
|
2104
|
-
const getForEnvironment$1 = (http, { spaceId, environmentId, environmentTemplateId, installationId, ...paginationProps }, headers) => get$
|
|
2219
|
+
const getForEnvironment$1 = (http, { spaceId, environmentId, environmentTemplateId, installationId, ...paginationProps }, headers) => get$19(http, `/spaces/${spaceId}/environments/${environmentId}/template_installations/${environmentTemplateId}`, {
|
|
2105
2220
|
params: {
|
|
2106
2221
|
...(installationId && { 'sys.id': installationId }),
|
|
2107
2222
|
...paginationProps,
|
|
@@ -2112,29 +2227,29 @@ const getForEnvironment$1 = (http, { spaceId, environmentId, environmentTemplate
|
|
|
2112
2227
|
var EnvironmentTemplateInstallation = /*#__PURE__*/Object.freeze({
|
|
2113
2228
|
__proto__: null,
|
|
2114
2229
|
getForEnvironment: getForEnvironment$1,
|
|
2115
|
-
getMany: getMany$
|
|
2230
|
+
getMany: getMany$t
|
|
2116
2231
|
});
|
|
2117
2232
|
|
|
2118
|
-
const getBaseUrl$
|
|
2119
|
-
const getExtensionUrl = (params) => getBaseUrl$
|
|
2120
|
-
const get$
|
|
2121
|
-
return get$
|
|
2233
|
+
const getBaseUrl$i = (params) => `/spaces/${params.spaceId}/environments/${params.environmentId}/extensions`;
|
|
2234
|
+
const getExtensionUrl = (params) => getBaseUrl$i(params) + `/${params.extensionId}`;
|
|
2235
|
+
const get$C = (http, params) => {
|
|
2236
|
+
return get$19(http, getExtensionUrl(params), {
|
|
2122
2237
|
params: normalizeSelect(params.query),
|
|
2123
2238
|
});
|
|
2124
2239
|
};
|
|
2125
|
-
const getMany$
|
|
2126
|
-
return get$
|
|
2240
|
+
const getMany$s = (http, params) => {
|
|
2241
|
+
return get$19(http, getBaseUrl$i(params), {
|
|
2127
2242
|
params: normalizeSelect(params.query),
|
|
2128
2243
|
});
|
|
2129
2244
|
};
|
|
2130
|
-
const create$
|
|
2131
|
-
return post$1(http, getBaseUrl$
|
|
2245
|
+
const create$l = (http, params, rawData, headers) => {
|
|
2246
|
+
return post$1(http, getBaseUrl$i(params), rawData, { headers });
|
|
2132
2247
|
};
|
|
2133
2248
|
const createWithId$4 = (http, params, rawData, headers) => {
|
|
2134
2249
|
const data = copy__default.default(rawData);
|
|
2135
2250
|
return put$1(http, getExtensionUrl(params), data, { headers });
|
|
2136
2251
|
};
|
|
2137
|
-
const update$
|
|
2252
|
+
const update$j = async (http, params, rawData, headers) => {
|
|
2138
2253
|
const data = copy__default.default(rawData);
|
|
2139
2254
|
delete data.sys;
|
|
2140
2255
|
return put$1(http, getExtensionUrl(params), data, {
|
|
@@ -2144,18 +2259,74 @@ const update$i = async (http, params, rawData, headers) => {
|
|
|
2144
2259
|
},
|
|
2145
2260
|
});
|
|
2146
2261
|
};
|
|
2147
|
-
const del$
|
|
2148
|
-
return del$
|
|
2262
|
+
const del$n = (http, params) => {
|
|
2263
|
+
return del$M(http, getExtensionUrl(params));
|
|
2149
2264
|
};
|
|
2150
2265
|
|
|
2151
2266
|
var Extension = /*#__PURE__*/Object.freeze({
|
|
2152
2267
|
__proto__: null,
|
|
2153
|
-
create: create$
|
|
2268
|
+
create: create$l,
|
|
2154
2269
|
createWithId: createWithId$4,
|
|
2155
|
-
del: del$
|
|
2156
|
-
get: get$
|
|
2270
|
+
del: del$n,
|
|
2271
|
+
get: get$C,
|
|
2157
2272
|
getExtensionUrl: getExtensionUrl,
|
|
2158
|
-
getMany: getMany$
|
|
2273
|
+
getMany: getMany$s,
|
|
2274
|
+
update: update$j
|
|
2275
|
+
});
|
|
2276
|
+
|
|
2277
|
+
const getBaseUrl$h = (params) => `/spaces/${params.spaceId}/environments/${params.environmentId}/fragments`;
|
|
2278
|
+
const getMany$r = (http, params, headers) => {
|
|
2279
|
+
return get$19(http, getBaseUrl$h(params), {
|
|
2280
|
+
params: params.query,
|
|
2281
|
+
headers,
|
|
2282
|
+
});
|
|
2283
|
+
};
|
|
2284
|
+
const get$B = (http, params, headers) => {
|
|
2285
|
+
return get$19(http, getBaseUrl$h(params) + `/${params.fragmentId}`, { headers });
|
|
2286
|
+
};
|
|
2287
|
+
const create$k = (http, params, rawData, headers) => {
|
|
2288
|
+
const data = copy__default.default(rawData);
|
|
2289
|
+
return post$1(http, getBaseUrl$h(params), data, { headers });
|
|
2290
|
+
};
|
|
2291
|
+
const update$i = (http, params, rawData, headers) => {
|
|
2292
|
+
const { sys, ...body } = copy__default.default(rawData);
|
|
2293
|
+
return put$1(http, getBaseUrl$h(params) + `/${params.fragmentId}`, body, {
|
|
2294
|
+
headers: {
|
|
2295
|
+
...(sys?.version !== undefined && {
|
|
2296
|
+
'X-Contentful-Version': sys.version,
|
|
2297
|
+
}),
|
|
2298
|
+
...headers,
|
|
2299
|
+
},
|
|
2300
|
+
});
|
|
2301
|
+
};
|
|
2302
|
+
const del$m = (http, params) => {
|
|
2303
|
+
return del$M(http, getBaseUrl$h(params) + `/${params.fragmentId}`);
|
|
2304
|
+
};
|
|
2305
|
+
const publish$3 = (http, params, headers) => {
|
|
2306
|
+
return put$1(http, getBaseUrl$h(params) + `/${params.fragmentId}/published`, null, {
|
|
2307
|
+
headers: {
|
|
2308
|
+
'X-Contentful-Version': params.version,
|
|
2309
|
+
...headers,
|
|
2310
|
+
},
|
|
2311
|
+
});
|
|
2312
|
+
};
|
|
2313
|
+
const unpublish$3 = (http, params, headers) => {
|
|
2314
|
+
return del$M(http, getBaseUrl$h(params) + `/${params.fragmentId}/published`, {
|
|
2315
|
+
headers: {
|
|
2316
|
+
'X-Contentful-Version': params.version,
|
|
2317
|
+
...headers,
|
|
2318
|
+
},
|
|
2319
|
+
});
|
|
2320
|
+
};
|
|
2321
|
+
|
|
2322
|
+
var Fragment = /*#__PURE__*/Object.freeze({
|
|
2323
|
+
__proto__: null,
|
|
2324
|
+
create: create$k,
|
|
2325
|
+
del: del$m,
|
|
2326
|
+
get: get$B,
|
|
2327
|
+
getMany: getMany$r,
|
|
2328
|
+
publish: publish$3,
|
|
2329
|
+
unpublish: unpublish$3,
|
|
2159
2330
|
update: update$i
|
|
2160
2331
|
});
|
|
2161
2332
|
|
|
@@ -2165,22 +2336,22 @@ const getFunctionUrl = (params) => `${getManyUrl(params)}/${params.functionId}`;
|
|
|
2165
2336
|
const getFunctionsEnvURL = (params) => {
|
|
2166
2337
|
return `/spaces/${params.spaceId}/environments/${params.environmentId}/app_installations/${params.appInstallationId}/functions`;
|
|
2167
2338
|
};
|
|
2168
|
-
const get$
|
|
2169
|
-
return get$
|
|
2339
|
+
const get$A = (http, params) => {
|
|
2340
|
+
return get$19(http, getFunctionUrl(params));
|
|
2170
2341
|
};
|
|
2171
|
-
const getMany$
|
|
2172
|
-
return get$
|
|
2342
|
+
const getMany$q = (http, params) => {
|
|
2343
|
+
return get$19(http, getManyUrl(params), { params: params.query });
|
|
2173
2344
|
};
|
|
2174
2345
|
const getManyForEnvironment$1 = (http, params) => {
|
|
2175
|
-
return get$
|
|
2346
|
+
return get$19(http, getFunctionsEnvURL(params), {
|
|
2176
2347
|
params: params.query,
|
|
2177
2348
|
});
|
|
2178
2349
|
};
|
|
2179
2350
|
|
|
2180
2351
|
var Function = /*#__PURE__*/Object.freeze({
|
|
2181
2352
|
__proto__: null,
|
|
2182
|
-
get: get$
|
|
2183
|
-
getMany: getMany$
|
|
2353
|
+
get: get$A,
|
|
2354
|
+
getMany: getMany$q,
|
|
2184
2355
|
getManyForEnvironment: getManyForEnvironment$1
|
|
2185
2356
|
});
|
|
2186
2357
|
|
|
@@ -2189,15 +2360,15 @@ const FunctionLogAlphaHeaders = {
|
|
|
2189
2360
|
};
|
|
2190
2361
|
const baseURL = (params) => `/spaces/${params.spaceId}/environments/${params.environmentId}/app_installations/${params.appInstallationId}/functions/${params.functionId}/logs`;
|
|
2191
2362
|
const getURL = (params) => `/spaces/${params.spaceId}/environments/${params.environmentId}/app_installations/${params.appInstallationId}/functions/${params.functionId}/logs/${params.logId}`;
|
|
2192
|
-
const get$
|
|
2193
|
-
return get$
|
|
2363
|
+
const get$z = (http, params) => {
|
|
2364
|
+
return get$19(http, getURL(params), {
|
|
2194
2365
|
headers: {
|
|
2195
2366
|
...FunctionLogAlphaHeaders,
|
|
2196
2367
|
},
|
|
2197
2368
|
});
|
|
2198
2369
|
};
|
|
2199
|
-
const getMany$
|
|
2200
|
-
return get$
|
|
2370
|
+
const getMany$p = (http, params) => {
|
|
2371
|
+
return get$19(http, baseURL(params), {
|
|
2201
2372
|
params: params.query,
|
|
2202
2373
|
headers: {
|
|
2203
2374
|
...FunctionLogAlphaHeaders,
|
|
@@ -2207,12 +2378,12 @@ const getMany$n = (http, params) => {
|
|
|
2207
2378
|
|
|
2208
2379
|
var FunctionLog = /*#__PURE__*/Object.freeze({
|
|
2209
2380
|
__proto__: null,
|
|
2210
|
-
get: get$
|
|
2211
|
-
getMany: getMany$
|
|
2381
|
+
get: get$z,
|
|
2382
|
+
getMany: getMany$p
|
|
2212
2383
|
});
|
|
2213
2384
|
|
|
2214
|
-
const get$
|
|
2215
|
-
return get$
|
|
2385
|
+
const get$y = (http, { url, config }) => {
|
|
2386
|
+
return get$19(http, url, config);
|
|
2216
2387
|
};
|
|
2217
2388
|
const post = (http, { url, config }, payload) => {
|
|
2218
2389
|
return post$1(http, url, payload, config);
|
|
@@ -2223,8 +2394,8 @@ const put = (http, { url, config }, payload) => {
|
|
|
2223
2394
|
const patch = (http, { url, config }, payload) => {
|
|
2224
2395
|
return patch$5(http, url, payload, config);
|
|
2225
2396
|
};
|
|
2226
|
-
const del$
|
|
2227
|
-
return del$
|
|
2397
|
+
const del$l = (http, { url, config }) => {
|
|
2398
|
+
return del$M(http, url, config);
|
|
2228
2399
|
};
|
|
2229
2400
|
const request = (http$1, { url, config }) => {
|
|
2230
2401
|
return http(http$1, url, config);
|
|
@@ -2232,23 +2403,23 @@ const request = (http$1, { url, config }) => {
|
|
|
2232
2403
|
|
|
2233
2404
|
var Http = /*#__PURE__*/Object.freeze({
|
|
2234
2405
|
__proto__: null,
|
|
2235
|
-
del: del$
|
|
2236
|
-
get: get$
|
|
2406
|
+
del: del$l,
|
|
2407
|
+
get: get$y,
|
|
2237
2408
|
patch: patch,
|
|
2238
2409
|
post: post,
|
|
2239
2410
|
put: put,
|
|
2240
2411
|
request: request
|
|
2241
2412
|
});
|
|
2242
2413
|
|
|
2243
|
-
const get$
|
|
2244
|
-
return get$
|
|
2414
|
+
const get$x = (http, params) => {
|
|
2415
|
+
return get$19(http, `/spaces/${params.spaceId}/environments/${params.environmentId}/locales/${params.localeId}`);
|
|
2245
2416
|
};
|
|
2246
|
-
const getMany$
|
|
2247
|
-
return get$
|
|
2417
|
+
const getMany$o = (http, params) => {
|
|
2418
|
+
return get$19(http, `/spaces/${params.spaceId}/environments/${params.environmentId}/locales`, {
|
|
2248
2419
|
params: normalizeSelect(params.query),
|
|
2249
2420
|
});
|
|
2250
2421
|
};
|
|
2251
|
-
const create$
|
|
2422
|
+
const create$j = (http, params, data, headers) => {
|
|
2252
2423
|
return post$1(http, `/spaces/${params.spaceId}/environments/${params.environmentId}/locales`, data, {
|
|
2253
2424
|
headers,
|
|
2254
2425
|
});
|
|
@@ -2264,26 +2435,26 @@ const update$h = (http, params, rawData, headers) => {
|
|
|
2264
2435
|
},
|
|
2265
2436
|
});
|
|
2266
2437
|
};
|
|
2267
|
-
const del$
|
|
2268
|
-
return del$
|
|
2438
|
+
const del$k = (http, params) => {
|
|
2439
|
+
return del$M(http, `/spaces/${params.spaceId}/environments/${params.environmentId}/locales/${params.localeId}`);
|
|
2269
2440
|
};
|
|
2270
2441
|
|
|
2271
2442
|
var Locale = /*#__PURE__*/Object.freeze({
|
|
2272
2443
|
__proto__: null,
|
|
2273
|
-
create: create$
|
|
2274
|
-
del: del$
|
|
2275
|
-
get: get$
|
|
2276
|
-
getMany: getMany$
|
|
2444
|
+
create: create$j,
|
|
2445
|
+
del: del$k,
|
|
2446
|
+
get: get$x,
|
|
2447
|
+
getMany: getMany$o,
|
|
2277
2448
|
update: update$h
|
|
2278
2449
|
});
|
|
2279
2450
|
|
|
2280
|
-
const getMany$
|
|
2281
|
-
return get$
|
|
2451
|
+
const getMany$n = (http, params) => {
|
|
2452
|
+
return get$19(http, `/organizations`, {
|
|
2282
2453
|
params: params?.query,
|
|
2283
2454
|
});
|
|
2284
2455
|
};
|
|
2285
|
-
const get$
|
|
2286
|
-
return getMany$
|
|
2456
|
+
const get$w = (http, params) => {
|
|
2457
|
+
return getMany$n(http, { query: { limit: 100 } }).then((data) => {
|
|
2287
2458
|
const org = data.items.find((org) => org.sys.id === params.organizationId);
|
|
2288
2459
|
if (!org) {
|
|
2289
2460
|
const error = new Error(`No organization was found with the ID ${params.organizationId} instead got ${JSON.stringify(data)}`);
|
|
@@ -2301,8 +2472,8 @@ const get$u = (http, params) => {
|
|
|
2301
2472
|
|
|
2302
2473
|
var Organization = /*#__PURE__*/Object.freeze({
|
|
2303
2474
|
__proto__: null,
|
|
2304
|
-
get: get$
|
|
2305
|
-
getMany: getMany$
|
|
2475
|
+
get: get$w,
|
|
2476
|
+
getMany: getMany$n
|
|
2306
2477
|
});
|
|
2307
2478
|
|
|
2308
2479
|
const OrganizationUserManagementAlphaHeaders = {
|
|
@@ -2311,7 +2482,7 @@ const OrganizationUserManagementAlphaHeaders = {
|
|
|
2311
2482
|
const InvitationAlphaHeaders = {
|
|
2312
2483
|
'x-contentful-enable-alpha-feature': 'pending-org-membership',
|
|
2313
2484
|
};
|
|
2314
|
-
const create$
|
|
2485
|
+
const create$i = (http, params, data, headers) => {
|
|
2315
2486
|
return post$1(http, `/organizations/${params.organizationId}/invitations`, data, {
|
|
2316
2487
|
headers: {
|
|
2317
2488
|
...InvitationAlphaHeaders,
|
|
@@ -2319,8 +2490,8 @@ const create$g = (http, params, data, headers) => {
|
|
|
2319
2490
|
},
|
|
2320
2491
|
});
|
|
2321
2492
|
};
|
|
2322
|
-
const get$
|
|
2323
|
-
return get$
|
|
2493
|
+
const get$v = (http, params, headers) => {
|
|
2494
|
+
return get$19(http, `/organizations/${params.organizationId}/invitations/${params.invitationId}`, {
|
|
2324
2495
|
headers: {
|
|
2325
2496
|
...OrganizationUserManagementAlphaHeaders,
|
|
2326
2497
|
...headers,
|
|
@@ -2330,17 +2501,17 @@ const get$t = (http, params, headers) => {
|
|
|
2330
2501
|
|
|
2331
2502
|
var OrganizationInvitation = /*#__PURE__*/Object.freeze({
|
|
2332
2503
|
__proto__: null,
|
|
2333
|
-
create: create$
|
|
2334
|
-
get: get$
|
|
2504
|
+
create: create$i,
|
|
2505
|
+
get: get$v
|
|
2335
2506
|
});
|
|
2336
2507
|
|
|
2337
|
-
const getBaseUrl$
|
|
2338
|
-
const getEntityUrl$5 = (params) => `${getBaseUrl$
|
|
2339
|
-
const get$
|
|
2340
|
-
return get$
|
|
2508
|
+
const getBaseUrl$g = (params) => `/organizations/${params.organizationId}/organization_memberships`;
|
|
2509
|
+
const getEntityUrl$5 = (params) => `${getBaseUrl$g(params)}/${params.organizationMembershipId}`;
|
|
2510
|
+
const get$u = (http, params) => {
|
|
2511
|
+
return get$19(http, getEntityUrl$5(params));
|
|
2341
2512
|
};
|
|
2342
|
-
const getMany$
|
|
2343
|
-
return get$
|
|
2513
|
+
const getMany$m = (http, params) => {
|
|
2514
|
+
return get$19(http, getBaseUrl$g(params), {
|
|
2344
2515
|
params: params.query,
|
|
2345
2516
|
});
|
|
2346
2517
|
};
|
|
@@ -2355,15 +2526,15 @@ const update$g = (http, params, rawData, headers) => {
|
|
|
2355
2526
|
},
|
|
2356
2527
|
});
|
|
2357
2528
|
};
|
|
2358
|
-
const del$
|
|
2359
|
-
return del$
|
|
2529
|
+
const del$j = (http, params) => {
|
|
2530
|
+
return del$M(http, getEntityUrl$5(params));
|
|
2360
2531
|
};
|
|
2361
2532
|
|
|
2362
2533
|
var OrganizationMembership = /*#__PURE__*/Object.freeze({
|
|
2363
2534
|
__proto__: null,
|
|
2364
|
-
del: del$
|
|
2365
|
-
get: get$
|
|
2366
|
-
getMany: getMany$
|
|
2535
|
+
del: del$j,
|
|
2536
|
+
get: get$u,
|
|
2537
|
+
getMany: getMany$m,
|
|
2367
2538
|
update: update$g
|
|
2368
2539
|
});
|
|
2369
2540
|
|
|
@@ -2389,8 +2560,8 @@ var OrganizationMembership = /*#__PURE__*/Object.freeze({
|
|
|
2389
2560
|
* .catch(console.error)
|
|
2390
2561
|
* ```
|
|
2391
2562
|
*/
|
|
2392
|
-
const get$
|
|
2393
|
-
return get$
|
|
2563
|
+
const get$t = (http, params) => {
|
|
2564
|
+
return get$19(http, `/users/${params.userId}/oauth_applications/${params.oauthApplicationId}`);
|
|
2394
2565
|
};
|
|
2395
2566
|
/**
|
|
2396
2567
|
* Retrieves a list of OAuth applications associated with the current user.
|
|
@@ -2415,7 +2586,7 @@ const get$r = (http, params) => {
|
|
|
2415
2586
|
* ```
|
|
2416
2587
|
*/
|
|
2417
2588
|
const getManyForUser = (http, params) => {
|
|
2418
|
-
return get$
|
|
2589
|
+
return get$19(http, `/users/${params.userId}/oauth_applications`, {
|
|
2419
2590
|
params: params.query,
|
|
2420
2591
|
});
|
|
2421
2592
|
};
|
|
@@ -2444,7 +2615,7 @@ const getManyForUser = (http, params) => {
|
|
|
2444
2615
|
* .catch(console.error)
|
|
2445
2616
|
* ```
|
|
2446
2617
|
*/
|
|
2447
|
-
const create$
|
|
2618
|
+
const create$h = (http, params, rawData, headers) => {
|
|
2448
2619
|
return post$1(http, `/users/${params.userId}/oauth_applications`, rawData, {
|
|
2449
2620
|
headers,
|
|
2450
2621
|
});
|
|
@@ -2501,15 +2672,15 @@ const update$f = (http, params, rawData, headers) => {
|
|
|
2501
2672
|
* .catch(console.error)
|
|
2502
2673
|
* ```
|
|
2503
2674
|
*/
|
|
2504
|
-
const del$
|
|
2505
|
-
return del$
|
|
2675
|
+
const del$i = (http, params) => {
|
|
2676
|
+
return del$M(http, `/users/${params.userId}/oauth_applications/${params.oauthApplicationId}`);
|
|
2506
2677
|
};
|
|
2507
2678
|
|
|
2508
2679
|
var OAuthApplication = /*#__PURE__*/Object.freeze({
|
|
2509
2680
|
__proto__: null,
|
|
2510
|
-
create: create$
|
|
2511
|
-
del: del$
|
|
2512
|
-
get: get$
|
|
2681
|
+
create: create$h,
|
|
2682
|
+
del: del$i,
|
|
2683
|
+
get: get$t,
|
|
2513
2684
|
getManyForUser: getManyForUser,
|
|
2514
2685
|
update: update$f
|
|
2515
2686
|
});
|
|
@@ -2517,21 +2688,21 @@ var OAuthApplication = /*#__PURE__*/Object.freeze({
|
|
|
2517
2688
|
/**
|
|
2518
2689
|
* @deprecated use `access-token.get` instead `personal-access-token.get`
|
|
2519
2690
|
*/
|
|
2520
|
-
const get$
|
|
2521
|
-
return get$
|
|
2691
|
+
const get$s = (http, params) => {
|
|
2692
|
+
return get$19(http, `/users/me/access_tokens/${params.tokenId}`);
|
|
2522
2693
|
};
|
|
2523
2694
|
/**
|
|
2524
2695
|
* @deprecated use `access-token.getMany` instead `personal-access-token.getMany`
|
|
2525
2696
|
*/
|
|
2526
|
-
const getMany$
|
|
2527
|
-
return get$
|
|
2697
|
+
const getMany$l = (http, params) => {
|
|
2698
|
+
return get$19(http, '/users/me/access_tokens', {
|
|
2528
2699
|
params: params.query,
|
|
2529
2700
|
});
|
|
2530
2701
|
};
|
|
2531
2702
|
/**
|
|
2532
2703
|
* @deprecated use `access-token.createPersonalAccessToken` instead. `personal-access-token.create`
|
|
2533
2704
|
*/
|
|
2534
|
-
const create$
|
|
2705
|
+
const create$g = (http, _params, rawData, headers) => {
|
|
2535
2706
|
return post$1(http, '/users/me/access_tokens', rawData, {
|
|
2536
2707
|
headers,
|
|
2537
2708
|
});
|
|
@@ -2545,29 +2716,29 @@ const revoke = (http, params) => {
|
|
|
2545
2716
|
|
|
2546
2717
|
var PersonalAccessToken = /*#__PURE__*/Object.freeze({
|
|
2547
2718
|
__proto__: null,
|
|
2548
|
-
create: create$
|
|
2549
|
-
get: get$
|
|
2550
|
-
getMany: getMany$
|
|
2719
|
+
create: create$g,
|
|
2720
|
+
get: get$s,
|
|
2721
|
+
getMany: getMany$l,
|
|
2551
2722
|
revoke: revoke
|
|
2552
2723
|
});
|
|
2553
2724
|
|
|
2554
|
-
const get$
|
|
2555
|
-
return get$
|
|
2725
|
+
const get$r = (http, params) => {
|
|
2726
|
+
return get$19(http, `/spaces/${params.spaceId}/preview_api_keys/${params.previewApiKeyId}`);
|
|
2556
2727
|
};
|
|
2557
|
-
const getMany$
|
|
2558
|
-
return get$
|
|
2728
|
+
const getMany$k = (http, params) => {
|
|
2729
|
+
return get$19(http, `/spaces/${params.spaceId}/preview_api_keys`, {
|
|
2559
2730
|
params: params.query,
|
|
2560
2731
|
});
|
|
2561
2732
|
};
|
|
2562
2733
|
|
|
2563
2734
|
var PreviewApiKey = /*#__PURE__*/Object.freeze({
|
|
2564
2735
|
__proto__: null,
|
|
2565
|
-
get: get$
|
|
2566
|
-
getMany: getMany$
|
|
2736
|
+
get: get$r,
|
|
2737
|
+
getMany: getMany$k
|
|
2567
2738
|
});
|
|
2568
2739
|
|
|
2569
|
-
const get$
|
|
2570
|
-
return get$
|
|
2740
|
+
const get$q = (http, params) => {
|
|
2741
|
+
return get$19(http, `/spaces/${params.spaceId}/environments/${params.environmentId}/releases/${params.releaseId}`);
|
|
2571
2742
|
};
|
|
2572
2743
|
const query = (http, params) => {
|
|
2573
2744
|
// Set the schema version in the query if provided in params or query options
|
|
@@ -2575,11 +2746,11 @@ const query = (http, params) => {
|
|
|
2575
2746
|
if (releaseSchemaVersion !== undefined) {
|
|
2576
2747
|
params.query = { ...params.query, 'sys.schemaVersion': releaseSchemaVersion };
|
|
2577
2748
|
}
|
|
2578
|
-
return get$
|
|
2749
|
+
return get$19(http, `/spaces/${params.spaceId}/environments/${params.environmentId}/releases`, {
|
|
2579
2750
|
params: params.query,
|
|
2580
2751
|
});
|
|
2581
2752
|
};
|
|
2582
|
-
const create$
|
|
2753
|
+
const create$f = (http, params, payload) => {
|
|
2583
2754
|
const releaseSchemaVersion = payload.sys?.schemaVersion ?? params.releaseSchemaVersion;
|
|
2584
2755
|
if (releaseSchemaVersion === 'Release.v2') {
|
|
2585
2756
|
payload.sys = { ...payload.sys, type: 'Release', schemaVersion: 'Release.v2' };
|
|
@@ -2598,10 +2769,10 @@ const update$e = (http, params, payload, headers) => {
|
|
|
2598
2769
|
},
|
|
2599
2770
|
});
|
|
2600
2771
|
};
|
|
2601
|
-
const del$
|
|
2602
|
-
return del$
|
|
2772
|
+
const del$h = (http, params) => {
|
|
2773
|
+
return del$M(http, `/spaces/${params.spaceId}/environments/${params.environmentId}/releases/${params.releaseId}`);
|
|
2603
2774
|
};
|
|
2604
|
-
const publish = (http, params, headers) => {
|
|
2775
|
+
const publish$2 = (http, params, headers) => {
|
|
2605
2776
|
return put$1(http, `/spaces/${params.spaceId}/environments/${params.environmentId}/releases/${params.releaseId}/published`, null, {
|
|
2606
2777
|
headers: {
|
|
2607
2778
|
'X-Contentful-Version': params.version,
|
|
@@ -2609,8 +2780,8 @@ const publish = (http, params, headers) => {
|
|
|
2609
2780
|
},
|
|
2610
2781
|
});
|
|
2611
2782
|
};
|
|
2612
|
-
const unpublish = (http, params, headers) => {
|
|
2613
|
-
return del$
|
|
2783
|
+
const unpublish$2 = (http, params, headers) => {
|
|
2784
|
+
return del$M(http, `/spaces/${params.spaceId}/environments/${params.environmentId}/releases/${params.releaseId}/published`, {
|
|
2614
2785
|
headers: {
|
|
2615
2786
|
'X-Contentful-Version': params.version,
|
|
2616
2787
|
...headers,
|
|
@@ -2628,7 +2799,7 @@ const archive = (http, params) => {
|
|
|
2628
2799
|
});
|
|
2629
2800
|
};
|
|
2630
2801
|
const unarchive$1 = (http, params) => {
|
|
2631
|
-
return del$
|
|
2802
|
+
return del$M(http, `/spaces/${params.spaceId}/environments/${params.environmentId}/releases/${params.releaseId}/archived`, {
|
|
2632
2803
|
headers: {
|
|
2633
2804
|
'X-Contentful-Version': params.version,
|
|
2634
2805
|
},
|
|
@@ -2638,27 +2809,27 @@ const unarchive$1 = (http, params) => {
|
|
|
2638
2809
|
var Release = /*#__PURE__*/Object.freeze({
|
|
2639
2810
|
__proto__: null,
|
|
2640
2811
|
archive: archive,
|
|
2641
|
-
create: create$
|
|
2642
|
-
del: del$
|
|
2643
|
-
get: get$
|
|
2644
|
-
publish: publish,
|
|
2812
|
+
create: create$f,
|
|
2813
|
+
del: del$h,
|
|
2814
|
+
get: get$q,
|
|
2815
|
+
publish: publish$2,
|
|
2645
2816
|
query: query,
|
|
2646
2817
|
unarchive: unarchive$1,
|
|
2647
|
-
unpublish: unpublish,
|
|
2818
|
+
unpublish: unpublish$2,
|
|
2648
2819
|
update: update$e,
|
|
2649
2820
|
validate: validate
|
|
2650
2821
|
});
|
|
2651
2822
|
|
|
2652
|
-
const get$
|
|
2653
|
-
return get$
|
|
2823
|
+
const get$p = (http, params) => {
|
|
2824
|
+
return get$19(http, `/spaces/${params.spaceId}/environments/${params.environmentId}/releases/${params.releaseId}/actions/${params.actionId}`);
|
|
2654
2825
|
};
|
|
2655
|
-
const getMany$
|
|
2656
|
-
return get$
|
|
2826
|
+
const getMany$j = (http, params) => {
|
|
2827
|
+
return get$19(http, `/spaces/${params.spaceId}/environments/${params.environmentId}/release_actions`, {
|
|
2657
2828
|
params: params.query,
|
|
2658
2829
|
});
|
|
2659
2830
|
};
|
|
2660
2831
|
const queryForRelease = (http, params) => {
|
|
2661
|
-
return get$
|
|
2832
|
+
return get$19(http, `/spaces/${params.spaceId}/environments/${params.environmentId}/release_actions`, {
|
|
2662
2833
|
params: {
|
|
2663
2834
|
'sys.release.sys.id[in]': params.releaseId,
|
|
2664
2835
|
...params.query,
|
|
@@ -2668,82 +2839,82 @@ const queryForRelease = (http, params) => {
|
|
|
2668
2839
|
|
|
2669
2840
|
var ReleaseAction = /*#__PURE__*/Object.freeze({
|
|
2670
2841
|
__proto__: null,
|
|
2671
|
-
get: get$
|
|
2672
|
-
getMany: getMany$
|
|
2842
|
+
get: get$p,
|
|
2843
|
+
getMany: getMany$j,
|
|
2673
2844
|
queryForRelease: queryForRelease
|
|
2674
2845
|
});
|
|
2675
2846
|
|
|
2676
|
-
const getBaseUrl$
|
|
2677
|
-
const getMany$
|
|
2847
|
+
const getBaseUrl$f = (params) => `/spaces/${params.spaceId}/environments/${params.environmentId}/resource_types/${params.resourceTypeId}/resources`;
|
|
2848
|
+
const getMany$i = (http, params) => get$19(http, getBaseUrl$f(params), {
|
|
2678
2849
|
params: params.query,
|
|
2679
2850
|
});
|
|
2680
2851
|
|
|
2681
2852
|
var Resource = /*#__PURE__*/Object.freeze({
|
|
2682
2853
|
__proto__: null,
|
|
2683
|
-
getMany: getMany$
|
|
2854
|
+
getMany: getMany$i
|
|
2684
2855
|
});
|
|
2685
2856
|
|
|
2686
|
-
const getBaseUrl$
|
|
2687
|
-
const get$
|
|
2688
|
-
return get$
|
|
2857
|
+
const getBaseUrl$e = (params) => `/organizations/${params.organizationId}/app_definitions/${params.appDefinitionId}/resource_provider`;
|
|
2858
|
+
const get$o = (http, params) => {
|
|
2859
|
+
return get$19(http, getBaseUrl$e(params));
|
|
2689
2860
|
};
|
|
2690
|
-
const upsert$
|
|
2691
|
-
return put$1(http, getBaseUrl$
|
|
2861
|
+
const upsert$3 = (http, params, rawData, headers) => {
|
|
2862
|
+
return put$1(http, getBaseUrl$e(params), rawData, { headers });
|
|
2692
2863
|
};
|
|
2693
|
-
const del$
|
|
2694
|
-
return del$
|
|
2864
|
+
const del$g = (http, params) => {
|
|
2865
|
+
return del$M(http, getBaseUrl$e(params));
|
|
2695
2866
|
};
|
|
2696
2867
|
|
|
2697
2868
|
var ResourceProvider = /*#__PURE__*/Object.freeze({
|
|
2698
2869
|
__proto__: null,
|
|
2699
|
-
del: del$
|
|
2700
|
-
get: get$
|
|
2701
|
-
upsert: upsert$
|
|
2870
|
+
del: del$g,
|
|
2871
|
+
get: get$o,
|
|
2872
|
+
upsert: upsert$3
|
|
2702
2873
|
});
|
|
2703
2874
|
|
|
2704
|
-
const getBaseUrl$
|
|
2705
|
-
const getEntityUrl$4 = (params) => `${getBaseUrl$
|
|
2875
|
+
const getBaseUrl$d = (params) => `/organizations/${params.organizationId}/app_definitions/${params.appDefinitionId}/resource_provider/resource_types`;
|
|
2876
|
+
const getEntityUrl$4 = (params) => `${getBaseUrl$d(params)}/${params.resourceTypeId}`;
|
|
2706
2877
|
const getSpaceEnvUrl = (params) => `/spaces/${params.spaceId}/environments/${params.environmentId}/resource_types`;
|
|
2707
|
-
const get$
|
|
2708
|
-
return get$
|
|
2878
|
+
const get$n = (http, params) => {
|
|
2879
|
+
return get$19(http, getEntityUrl$4(params));
|
|
2709
2880
|
};
|
|
2710
|
-
const upsert = (http, params, rawData, headers) => {
|
|
2881
|
+
const upsert$2 = (http, params, rawData, headers) => {
|
|
2711
2882
|
const data = copy__default.default(rawData);
|
|
2712
2883
|
return put$1(http, getEntityUrl$4(params), data, { headers });
|
|
2713
2884
|
};
|
|
2714
|
-
const del$
|
|
2715
|
-
return del$
|
|
2885
|
+
const del$f = (http, params) => {
|
|
2886
|
+
return del$M(http, getEntityUrl$4(params));
|
|
2716
2887
|
};
|
|
2717
|
-
const getMany$
|
|
2718
|
-
return get$
|
|
2888
|
+
const getMany$h = (http, params) => {
|
|
2889
|
+
return get$19(http, getBaseUrl$d(params));
|
|
2719
2890
|
};
|
|
2720
2891
|
const getForEnvironment = (http, params) => {
|
|
2721
|
-
return get$
|
|
2892
|
+
return get$19(http, getSpaceEnvUrl(params));
|
|
2722
2893
|
};
|
|
2723
2894
|
|
|
2724
2895
|
var ResourceType = /*#__PURE__*/Object.freeze({
|
|
2725
2896
|
__proto__: null,
|
|
2726
|
-
del: del$
|
|
2727
|
-
get: get$
|
|
2897
|
+
del: del$f,
|
|
2898
|
+
get: get$n,
|
|
2728
2899
|
getForEnvironment: getForEnvironment,
|
|
2729
|
-
getMany: getMany$
|
|
2730
|
-
upsert: upsert
|
|
2900
|
+
getMany: getMany$h,
|
|
2901
|
+
upsert: upsert$2
|
|
2731
2902
|
});
|
|
2732
2903
|
|
|
2733
|
-
const get$
|
|
2734
|
-
return get$
|
|
2904
|
+
const get$m = (http, params) => {
|
|
2905
|
+
return get$19(http, `/spaces/${params.spaceId}/roles/${params.roleId}`);
|
|
2735
2906
|
};
|
|
2736
|
-
const getMany$
|
|
2737
|
-
return get$
|
|
2907
|
+
const getMany$g = (http, params) => {
|
|
2908
|
+
return get$19(http, `/spaces/${params.spaceId}/roles`, {
|
|
2738
2909
|
params: normalizeSelect(params.query),
|
|
2739
2910
|
});
|
|
2740
2911
|
};
|
|
2741
2912
|
const getManyForOrganization$6 = (http, params) => {
|
|
2742
|
-
return get$
|
|
2913
|
+
return get$19(http, `/organizations/${params.organizationId}/roles`, {
|
|
2743
2914
|
params: normalizeSelect(params.query),
|
|
2744
2915
|
});
|
|
2745
2916
|
};
|
|
2746
|
-
const create$
|
|
2917
|
+
const create$e = (http, params, data, headers) => {
|
|
2747
2918
|
return post$1(http, `/spaces/${params.spaceId}/roles`, data, {
|
|
2748
2919
|
headers,
|
|
2749
2920
|
});
|
|
@@ -2763,38 +2934,38 @@ const update$d = (http, params, rawData, headers) => {
|
|
|
2763
2934
|
},
|
|
2764
2935
|
});
|
|
2765
2936
|
};
|
|
2766
|
-
const del$
|
|
2767
|
-
return del$
|
|
2937
|
+
const del$e = (http, params) => {
|
|
2938
|
+
return del$M(http, `/spaces/${params.spaceId}/roles/${params.roleId}`);
|
|
2768
2939
|
};
|
|
2769
2940
|
|
|
2770
2941
|
var Role = /*#__PURE__*/Object.freeze({
|
|
2771
2942
|
__proto__: null,
|
|
2772
|
-
create: create$
|
|
2943
|
+
create: create$e,
|
|
2773
2944
|
createWithId: createWithId$3,
|
|
2774
|
-
del: del$
|
|
2775
|
-
get: get$
|
|
2776
|
-
getMany: getMany$
|
|
2945
|
+
del: del$e,
|
|
2946
|
+
get: get$m,
|
|
2947
|
+
getMany: getMany$g,
|
|
2777
2948
|
getManyForOrganization: getManyForOrganization$6,
|
|
2778
2949
|
update: update$d
|
|
2779
2950
|
});
|
|
2780
2951
|
|
|
2781
|
-
const get$
|
|
2782
|
-
return get$
|
|
2952
|
+
const get$l = (http, params) => {
|
|
2953
|
+
return get$19(http, `/spaces/${params.spaceId}/scheduled_actions/${params.scheduledActionId}`, {
|
|
2783
2954
|
params: {
|
|
2784
2955
|
'environment.sys.id': params.environmentId,
|
|
2785
2956
|
},
|
|
2786
2957
|
});
|
|
2787
2958
|
};
|
|
2788
|
-
const getMany$
|
|
2789
|
-
return get$
|
|
2959
|
+
const getMany$f = (http, params) => {
|
|
2960
|
+
return get$19(http, `/spaces/${params.spaceId}/scheduled_actions`, {
|
|
2790
2961
|
params: normalizeSelect(params.query),
|
|
2791
2962
|
});
|
|
2792
2963
|
};
|
|
2793
|
-
const create$
|
|
2964
|
+
const create$d = (http, params, data) => {
|
|
2794
2965
|
return post$1(http, `/spaces/${params.spaceId}/scheduled_actions`, data);
|
|
2795
2966
|
};
|
|
2796
|
-
const del$
|
|
2797
|
-
return del$
|
|
2967
|
+
const del$d = (http, params) => {
|
|
2968
|
+
return del$M(http, `/spaces/${params.spaceId}/scheduled_actions/${params.scheduledActionId}`, {
|
|
2798
2969
|
params: {
|
|
2799
2970
|
'environment.sys.id': params.environmentId,
|
|
2800
2971
|
},
|
|
@@ -2813,102 +2984,102 @@ const update$c = (http, params, data) => {
|
|
|
2813
2984
|
|
|
2814
2985
|
var ScheduledAction = /*#__PURE__*/Object.freeze({
|
|
2815
2986
|
__proto__: null,
|
|
2816
|
-
create: create$
|
|
2817
|
-
del: del$
|
|
2818
|
-
get: get$
|
|
2819
|
-
getMany: getMany$
|
|
2987
|
+
create: create$d,
|
|
2988
|
+
del: del$d,
|
|
2989
|
+
get: get$l,
|
|
2990
|
+
getMany: getMany$f,
|
|
2820
2991
|
update: update$c
|
|
2821
2992
|
});
|
|
2822
2993
|
|
|
2823
|
-
const get$
|
|
2824
|
-
return get$
|
|
2994
|
+
const get$k = (http, params) => {
|
|
2995
|
+
return get$19(http, `/organizations/${params.organizationId}/semantic/search-index/${params.indexId}`);
|
|
2825
2996
|
};
|
|
2826
|
-
const getMany$
|
|
2827
|
-
return get$
|
|
2997
|
+
const getMany$e = (http, params) => {
|
|
2998
|
+
return get$19(http, `/organizations/${params.organizationId}/semantic/search-index`, { params: params.status ? { status: params.status } : undefined });
|
|
2828
2999
|
};
|
|
2829
3000
|
const getManyForEnvironment = (http, params) => {
|
|
2830
|
-
return get$
|
|
3001
|
+
return get$19(http, `/spaces/${params.spaceId}/environments/${params.environmentId}/semantic/search-index`, { params: params.status ? { status: params.status } : undefined });
|
|
2831
3002
|
};
|
|
2832
|
-
const create$
|
|
3003
|
+
const create$c = (http, params, data) => {
|
|
2833
3004
|
return post$1(http, `/organizations/${params.organizationId}/semantic/search-index`, data);
|
|
2834
3005
|
};
|
|
2835
|
-
const del$
|
|
2836
|
-
return del$
|
|
3006
|
+
const del$c = (http, params) => {
|
|
3007
|
+
return del$M(http, `/organizations/${params.organizationId}/semantic/search-index/${params.indexId}`);
|
|
2837
3008
|
};
|
|
2838
3009
|
|
|
2839
3010
|
var ContentSemanticsIndex = /*#__PURE__*/Object.freeze({
|
|
2840
3011
|
__proto__: null,
|
|
2841
|
-
create: create$
|
|
2842
|
-
del: del$
|
|
2843
|
-
get: get$
|
|
2844
|
-
getMany: getMany$
|
|
3012
|
+
create: create$c,
|
|
3013
|
+
del: del$c,
|
|
3014
|
+
get: get$k,
|
|
3015
|
+
getMany: getMany$e,
|
|
2845
3016
|
getManyForEnvironment: getManyForEnvironment
|
|
2846
3017
|
});
|
|
2847
3018
|
|
|
2848
|
-
const get$
|
|
3019
|
+
const get$j = (http, params, data, headers) => {
|
|
2849
3020
|
return post$1(http, `/spaces/${params.spaceId}/environments/${params.environmentId}/semantic/duplicates`, data, { headers });
|
|
2850
3021
|
};
|
|
2851
3022
|
|
|
2852
3023
|
var SemanticDuplicates = /*#__PURE__*/Object.freeze({
|
|
2853
3024
|
__proto__: null,
|
|
2854
|
-
get: get$
|
|
3025
|
+
get: get$j
|
|
2855
3026
|
});
|
|
2856
3027
|
|
|
2857
|
-
const get$
|
|
3028
|
+
const get$i = (http, params, data, headers) => {
|
|
2858
3029
|
return post$1(http, `/spaces/${params.spaceId}/environments/${params.environmentId}/semantic/recommendations`, data, { headers });
|
|
2859
3030
|
};
|
|
2860
3031
|
|
|
2861
3032
|
var SemanticRecommendations = /*#__PURE__*/Object.freeze({
|
|
2862
3033
|
__proto__: null,
|
|
2863
|
-
get: get$
|
|
3034
|
+
get: get$i
|
|
2864
3035
|
});
|
|
2865
3036
|
|
|
2866
|
-
const get$
|
|
3037
|
+
const get$h = (http, params, data, headers) => {
|
|
2867
3038
|
return post$1(http, `/spaces/${params.spaceId}/environments/${params.environmentId}/semantic/reference-suggestions`, data, { headers });
|
|
2868
3039
|
};
|
|
2869
3040
|
|
|
2870
3041
|
var SemanticReferenceSuggestions = /*#__PURE__*/Object.freeze({
|
|
2871
3042
|
__proto__: null,
|
|
2872
|
-
get: get$
|
|
3043
|
+
get: get$h
|
|
2873
3044
|
});
|
|
2874
3045
|
|
|
2875
|
-
const get$
|
|
3046
|
+
const get$g = (http, params, data, headers) => {
|
|
2876
3047
|
return post$1(http, `/spaces/${params.spaceId}/environments/${params.environmentId}/semantic/search`, data, { headers });
|
|
2877
3048
|
};
|
|
2878
3049
|
|
|
2879
3050
|
var SemanticSearch = /*#__PURE__*/Object.freeze({
|
|
2880
3051
|
__proto__: null,
|
|
2881
|
-
get: get$
|
|
3052
|
+
get: get$g
|
|
2882
3053
|
});
|
|
2883
3054
|
|
|
2884
|
-
const get$
|
|
2885
|
-
return get$
|
|
3055
|
+
const get$f = (http, params) => {
|
|
3056
|
+
return get$19(http, `/organizations/${params.organizationId}/semantic/settings`);
|
|
2886
3057
|
};
|
|
2887
3058
|
|
|
2888
3059
|
var SemanticSettings = /*#__PURE__*/Object.freeze({
|
|
2889
3060
|
__proto__: null,
|
|
2890
|
-
get: get$
|
|
3061
|
+
get: get$f
|
|
2891
3062
|
});
|
|
2892
3063
|
|
|
2893
3064
|
const getBaseEntryUrl = (params) => `/spaces/${params.spaceId}/environments/${params.environmentId}/entries/${params.entryId}/snapshots`;
|
|
2894
3065
|
const getEntryUrl = (params) => getBaseEntryUrl(params) + `/${params.snapshotId}`;
|
|
2895
3066
|
const getManyForEntry = (http, params) => {
|
|
2896
|
-
return get$
|
|
3067
|
+
return get$19(http, getBaseEntryUrl(params), {
|
|
2897
3068
|
params: normalizeSelect(params.query),
|
|
2898
3069
|
});
|
|
2899
3070
|
};
|
|
2900
3071
|
const getForEntry = (http, params) => {
|
|
2901
|
-
return get$
|
|
3072
|
+
return get$19(http, getEntryUrl(params));
|
|
2902
3073
|
};
|
|
2903
3074
|
const getBaseContentTypeUrl = (params) => `/spaces/${params.spaceId}/environments/${params.environmentId}/content_types/${params.contentTypeId}/snapshots`;
|
|
2904
3075
|
const getContentTypeUrl = (params) => getBaseContentTypeUrl(params) + `/${params.snapshotId}`;
|
|
2905
3076
|
const getManyForContentType = (http, params) => {
|
|
2906
|
-
return get$
|
|
3077
|
+
return get$19(http, getBaseContentTypeUrl(params), {
|
|
2907
3078
|
params: normalizeSelect(params.query),
|
|
2908
3079
|
});
|
|
2909
3080
|
};
|
|
2910
3081
|
const getForContentType = (http, params) => {
|
|
2911
|
-
return get$
|
|
3082
|
+
return get$19(http, getContentTypeUrl(params));
|
|
2912
3083
|
};
|
|
2913
3084
|
|
|
2914
3085
|
var Snapshot = /*#__PURE__*/Object.freeze({
|
|
@@ -2919,19 +3090,19 @@ var Snapshot = /*#__PURE__*/Object.freeze({
|
|
|
2919
3090
|
getManyForEntry: getManyForEntry
|
|
2920
3091
|
});
|
|
2921
3092
|
|
|
2922
|
-
const get$
|
|
3093
|
+
const get$e = (http, params) => get$19(http, `/spaces/${params.spaceId}`, {
|
|
2923
3094
|
params: params.include ? { include: params.include } : undefined,
|
|
2924
3095
|
});
|
|
2925
|
-
const getMany$
|
|
3096
|
+
const getMany$d = (http, params) => get$19(http, `/spaces`, {
|
|
2926
3097
|
params: { ...params.query, ...(params.include ? { include: params.include } : {}) },
|
|
2927
3098
|
headers: params.organizationId
|
|
2928
3099
|
? { 'X-Contentful-Organization': params.organizationId }
|
|
2929
3100
|
: undefined,
|
|
2930
3101
|
});
|
|
2931
|
-
const getManyForOrganization$5 = (http, params) => get$
|
|
3102
|
+
const getManyForOrganization$5 = (http, params) => get$19(http, `/organizations/${params.organizationId}/spaces`, {
|
|
2932
3103
|
params: params.query,
|
|
2933
3104
|
});
|
|
2934
|
-
const create$
|
|
3105
|
+
const create$b = (http, params, payload, headers) => {
|
|
2935
3106
|
return post$1(http, `/spaces`, payload, {
|
|
2936
3107
|
headers: params.organizationId
|
|
2937
3108
|
? { ...headers, 'X-Contentful-Organization': params.organizationId }
|
|
@@ -2953,21 +3124,21 @@ const unarchive = (http, params, data, headers) => {
|
|
|
2953
3124
|
headers,
|
|
2954
3125
|
});
|
|
2955
3126
|
};
|
|
2956
|
-
const del$
|
|
3127
|
+
const del$b = (http, params) => del$M(http, `/spaces/${params.spaceId}`);
|
|
2957
3128
|
|
|
2958
3129
|
var Space = /*#__PURE__*/Object.freeze({
|
|
2959
3130
|
__proto__: null,
|
|
2960
|
-
create: create$
|
|
2961
|
-
del: del$
|
|
2962
|
-
get: get$
|
|
2963
|
-
getMany: getMany$
|
|
3131
|
+
create: create$b,
|
|
3132
|
+
del: del$b,
|
|
3133
|
+
get: get$e,
|
|
3134
|
+
getMany: getMany$d,
|
|
2964
3135
|
getManyForOrganization: getManyForOrganization$5,
|
|
2965
3136
|
unarchive: unarchive,
|
|
2966
3137
|
update: update$b
|
|
2967
3138
|
});
|
|
2968
3139
|
|
|
2969
|
-
const getMany$
|
|
2970
|
-
return get$
|
|
3140
|
+
const getMany$c = (http, params) => {
|
|
3141
|
+
return get$19(http, `/spaces/${params.spaceId}/space_add_ons`, {
|
|
2971
3142
|
params: normalizeSelect(params.query),
|
|
2972
3143
|
});
|
|
2973
3144
|
};
|
|
@@ -2979,47 +3150,47 @@ const updateAllocations = (http, params, data, headers) => {
|
|
|
2979
3150
|
|
|
2980
3151
|
var SpaceAddOn = /*#__PURE__*/Object.freeze({
|
|
2981
3152
|
__proto__: null,
|
|
2982
|
-
getMany: getMany$
|
|
3153
|
+
getMany: getMany$c,
|
|
2983
3154
|
updateAllocations: updateAllocations
|
|
2984
3155
|
});
|
|
2985
3156
|
|
|
2986
|
-
const get$
|
|
2987
|
-
const getMany$
|
|
3157
|
+
const get$d = (http, params) => get$19(http, `/spaces/${params.spaceId}/space_members/${params.spaceMemberId}`);
|
|
3158
|
+
const getMany$b = (http, params) => get$19(http, `/spaces/${params.spaceId}/space_members`, {
|
|
2988
3159
|
params: params.query,
|
|
2989
3160
|
});
|
|
2990
3161
|
|
|
2991
3162
|
var SpaceMember = /*#__PURE__*/Object.freeze({
|
|
2992
3163
|
__proto__: null,
|
|
2993
|
-
get: get$
|
|
2994
|
-
getMany: getMany$
|
|
3164
|
+
get: get$d,
|
|
3165
|
+
getMany: getMany$b
|
|
2995
3166
|
});
|
|
2996
3167
|
|
|
2997
3168
|
function spaceMembershipDeprecationWarning() {
|
|
2998
3169
|
console.warn('The user attribute in the space membership root is deprecated. The attribute has been moved inside the sys object (i.e. sys.user)');
|
|
2999
3170
|
}
|
|
3000
|
-
const getBaseUrl$
|
|
3001
|
-
const getEntityUrl$3 = (params) => `${getBaseUrl$
|
|
3002
|
-
const get$
|
|
3171
|
+
const getBaseUrl$c = (params) => `/spaces/${params.spaceId}/space_memberships`;
|
|
3172
|
+
const getEntityUrl$3 = (params) => `${getBaseUrl$c(params)}/${params.spaceMembershipId}`;
|
|
3173
|
+
const get$c = (http, params) => {
|
|
3003
3174
|
spaceMembershipDeprecationWarning();
|
|
3004
|
-
return get$
|
|
3175
|
+
return get$19(http, getEntityUrl$3(params));
|
|
3005
3176
|
};
|
|
3006
|
-
const getMany$
|
|
3177
|
+
const getMany$a = (http, params) => {
|
|
3007
3178
|
spaceMembershipDeprecationWarning();
|
|
3008
|
-
return get$
|
|
3179
|
+
return get$19(http, getBaseUrl$c(params), {
|
|
3009
3180
|
params: params.query,
|
|
3010
3181
|
});
|
|
3011
3182
|
};
|
|
3012
3183
|
const getForOrganization$2 = (http, params) => {
|
|
3013
|
-
return get$
|
|
3184
|
+
return get$19(http, `/organizations/${params.organizationId}/space_memberships/${params.spaceMembershipId}`);
|
|
3014
3185
|
};
|
|
3015
3186
|
const getManyForOrganization$4 = (http, params) => {
|
|
3016
|
-
return get$
|
|
3187
|
+
return get$19(http, `/organizations/${params.organizationId}/space_memberships`, {
|
|
3017
3188
|
params: params.query,
|
|
3018
3189
|
});
|
|
3019
3190
|
};
|
|
3020
|
-
const create$
|
|
3191
|
+
const create$a = (http, params, data, headers) => {
|
|
3021
3192
|
spaceMembershipDeprecationWarning();
|
|
3022
|
-
return post$1(http, getBaseUrl$
|
|
3193
|
+
return post$1(http, getBaseUrl$c(params), data, {
|
|
3023
3194
|
headers,
|
|
3024
3195
|
});
|
|
3025
3196
|
};
|
|
@@ -3039,26 +3210,26 @@ const update$a = (http, params, rawData, headers) => {
|
|
|
3039
3210
|
},
|
|
3040
3211
|
});
|
|
3041
3212
|
};
|
|
3042
|
-
const del$
|
|
3043
|
-
return del$
|
|
3213
|
+
const del$a = (http, params) => {
|
|
3214
|
+
return del$M(http, getEntityUrl$3(params));
|
|
3044
3215
|
};
|
|
3045
3216
|
|
|
3046
3217
|
var SpaceMembership = /*#__PURE__*/Object.freeze({
|
|
3047
3218
|
__proto__: null,
|
|
3048
|
-
create: create$
|
|
3219
|
+
create: create$a,
|
|
3049
3220
|
createWithId: createWithId$2,
|
|
3050
|
-
del: del$
|
|
3051
|
-
get: get$
|
|
3221
|
+
del: del$a,
|
|
3222
|
+
get: get$c,
|
|
3052
3223
|
getForOrganization: getForOrganization$2,
|
|
3053
|
-
getMany: getMany$
|
|
3224
|
+
getMany: getMany$a,
|
|
3054
3225
|
getManyForOrganization: getManyForOrganization$4,
|
|
3055
3226
|
update: update$a
|
|
3056
3227
|
});
|
|
3057
3228
|
|
|
3058
|
-
const getBaseUrl$
|
|
3059
|
-
const getTagUrl = (params) => getBaseUrl$
|
|
3060
|
-
const get$
|
|
3061
|
-
const getMany$
|
|
3229
|
+
const getBaseUrl$b = (params) => `/spaces/${params.spaceId}/environments/${params.environmentId}/tags`;
|
|
3230
|
+
const getTagUrl = (params) => getBaseUrl$b(params) + `/${params.tagId}`;
|
|
3231
|
+
const get$b = (http, params) => get$19(http, getTagUrl(params));
|
|
3232
|
+
const getMany$9 = (http, params) => get$19(http, getBaseUrl$b(params), {
|
|
3062
3233
|
params: params.query,
|
|
3063
3234
|
});
|
|
3064
3235
|
const createWithId$1 = (http, params, rawData) => {
|
|
@@ -3077,32 +3248,32 @@ const update$9 = (http, params, rawData, headers) => {
|
|
|
3077
3248
|
},
|
|
3078
3249
|
});
|
|
3079
3250
|
};
|
|
3080
|
-
const del$
|
|
3081
|
-
return del$
|
|
3251
|
+
const del$9 = (http, { version, ...params }) => {
|
|
3252
|
+
return del$M(http, getTagUrl(params), { headers: { 'X-Contentful-Version': version } });
|
|
3082
3253
|
};
|
|
3083
3254
|
|
|
3084
3255
|
var Tag = /*#__PURE__*/Object.freeze({
|
|
3085
3256
|
__proto__: null,
|
|
3086
3257
|
createWithId: createWithId$1,
|
|
3087
|
-
del: del$
|
|
3088
|
-
get: get$
|
|
3089
|
-
getMany: getMany$
|
|
3258
|
+
del: del$9,
|
|
3259
|
+
get: get$b,
|
|
3260
|
+
getMany: getMany$9,
|
|
3090
3261
|
update: update$9
|
|
3091
3262
|
});
|
|
3092
3263
|
|
|
3093
|
-
const getBaseUrl$
|
|
3094
|
-
const getTaskUrl = (params) => `${getBaseUrl$
|
|
3095
|
-
const get$
|
|
3096
|
-
const getMany$
|
|
3264
|
+
const getBaseUrl$a = (params) => `/spaces/${params.spaceId}/environments/${params.environmentId}/entries/${params.entryId}/tasks`;
|
|
3265
|
+
const getTaskUrl = (params) => `${getBaseUrl$a(params)}/${params.taskId}`;
|
|
3266
|
+
const get$a = (http, params) => get$19(http, getTaskUrl(params));
|
|
3267
|
+
const getMany$8 = (http, params) => get$19(http, getBaseUrl$a(params), {
|
|
3097
3268
|
params: normalizeSelect(params.query),
|
|
3098
3269
|
});
|
|
3099
3270
|
/**
|
|
3100
3271
|
* @deprecated use `getMany` instead. `getAll` may never be removed for app compatibility reasons.
|
|
3101
3272
|
*/
|
|
3102
|
-
const getAll = getMany$
|
|
3103
|
-
const create$
|
|
3273
|
+
const getAll = getMany$8;
|
|
3274
|
+
const create$9 = (http, params, rawData) => {
|
|
3104
3275
|
const data = copy__default.default(rawData);
|
|
3105
|
-
return post$1(http, getBaseUrl$
|
|
3276
|
+
return post$1(http, getBaseUrl$a(params), data);
|
|
3106
3277
|
};
|
|
3107
3278
|
const update$8 = (http, params, rawData, headers) => {
|
|
3108
3279
|
const data = copy__default.default(rawData);
|
|
@@ -3114,33 +3285,33 @@ const update$8 = (http, params, rawData, headers) => {
|
|
|
3114
3285
|
},
|
|
3115
3286
|
});
|
|
3116
3287
|
};
|
|
3117
|
-
const del$
|
|
3118
|
-
return del$
|
|
3288
|
+
const del$8 = (http, { version, ...params }) => {
|
|
3289
|
+
return del$M(http, getTaskUrl(params), { headers: { 'X-Contentful-Version': version } });
|
|
3119
3290
|
};
|
|
3120
3291
|
|
|
3121
3292
|
var Task = /*#__PURE__*/Object.freeze({
|
|
3122
3293
|
__proto__: null,
|
|
3123
|
-
create: create$
|
|
3124
|
-
del: del$
|
|
3125
|
-
get: get$
|
|
3294
|
+
create: create$9,
|
|
3295
|
+
del: del$8,
|
|
3296
|
+
get: get$a,
|
|
3126
3297
|
getAll: getAll,
|
|
3127
|
-
getMany: getMany$
|
|
3298
|
+
getMany: getMany$8,
|
|
3128
3299
|
update: update$8
|
|
3129
3300
|
});
|
|
3130
3301
|
|
|
3131
|
-
const getBaseUrl$
|
|
3132
|
-
const getEntityUrl$2 = (params) => `${getBaseUrl$
|
|
3133
|
-
const get$
|
|
3134
|
-
const getMany$
|
|
3302
|
+
const getBaseUrl$9 = (params) => `/organizations/${params.organizationId}/teams`;
|
|
3303
|
+
const getEntityUrl$2 = (params) => `${getBaseUrl$9(params)}/${params.teamId}`;
|
|
3304
|
+
const get$9 = (http, params) => get$19(http, getEntityUrl$2(params));
|
|
3305
|
+
const getMany$7 = (http, params) => get$19(http, getBaseUrl$9(params), {
|
|
3135
3306
|
params: normalizeSelect(params.query),
|
|
3136
3307
|
});
|
|
3137
3308
|
const getManyForSpace$2 = (http, params) => {
|
|
3138
|
-
return get$
|
|
3309
|
+
return get$19(http, `/spaces/${params.spaceId}/teams`, {
|
|
3139
3310
|
params: normalizeSelect(params.query),
|
|
3140
3311
|
});
|
|
3141
3312
|
};
|
|
3142
|
-
const create$
|
|
3143
|
-
return post$1(http, getBaseUrl$
|
|
3313
|
+
const create$8 = (http, params, rawData, headers) => {
|
|
3314
|
+
return post$1(http, getBaseUrl$9(params), rawData, { headers });
|
|
3144
3315
|
};
|
|
3145
3316
|
const update$7 = (http, params, rawData, headers) => {
|
|
3146
3317
|
const data = copy__default.default(rawData);
|
|
@@ -3152,31 +3323,31 @@ const update$7 = (http, params, rawData, headers) => {
|
|
|
3152
3323
|
},
|
|
3153
3324
|
});
|
|
3154
3325
|
};
|
|
3155
|
-
const del$
|
|
3326
|
+
const del$7 = (http, params) => del$M(http, getEntityUrl$2(params));
|
|
3156
3327
|
|
|
3157
3328
|
var Team = /*#__PURE__*/Object.freeze({
|
|
3158
3329
|
__proto__: null,
|
|
3159
|
-
create: create$
|
|
3160
|
-
del: del$
|
|
3161
|
-
get: get$
|
|
3162
|
-
getMany: getMany$
|
|
3330
|
+
create: create$8,
|
|
3331
|
+
del: del$7,
|
|
3332
|
+
get: get$9,
|
|
3333
|
+
getMany: getMany$7,
|
|
3163
3334
|
getManyForSpace: getManyForSpace$2,
|
|
3164
3335
|
update: update$7
|
|
3165
3336
|
});
|
|
3166
3337
|
|
|
3167
|
-
const getBaseUrl$
|
|
3338
|
+
const getBaseUrl$8 = (params) => `/organizations/${params.organizationId}/teams/${params.teamId}/team_memberships`;
|
|
3168
3339
|
const getEntityUrl$1 = (params) => `/organizations/${params.organizationId}/teams/${params.teamId}/team_memberships/${params.teamMembershipId}`;
|
|
3169
|
-
const get$
|
|
3170
|
-
const getManyForOrganization$3 = (http, params) => get$
|
|
3340
|
+
const get$8 = (http, params) => get$19(http, getEntityUrl$1(params));
|
|
3341
|
+
const getManyForOrganization$3 = (http, params) => get$19(http, `/organizations/${params.organizationId}/team_memberships`, {
|
|
3171
3342
|
params: normalizeSelect(params.query),
|
|
3172
3343
|
});
|
|
3173
3344
|
const getManyForTeam = (http, params) => {
|
|
3174
|
-
return get$
|
|
3345
|
+
return get$19(http, getBaseUrl$8(params), {
|
|
3175
3346
|
params: normalizeSelect(params.query),
|
|
3176
3347
|
});
|
|
3177
3348
|
};
|
|
3178
|
-
const create$
|
|
3179
|
-
return post$1(http, getBaseUrl$
|
|
3349
|
+
const create$7 = (http, params, rawData, headers) => {
|
|
3350
|
+
return post$1(http, getBaseUrl$8(params), rawData, { headers });
|
|
3180
3351
|
};
|
|
3181
3352
|
const update$6 = (http, params, rawData, headers) => {
|
|
3182
3353
|
const data = copy__default.default(rawData);
|
|
@@ -3188,38 +3359,38 @@ const update$6 = (http, params, rawData, headers) => {
|
|
|
3188
3359
|
},
|
|
3189
3360
|
});
|
|
3190
3361
|
};
|
|
3191
|
-
const del$
|
|
3362
|
+
const del$6 = (http, params) => del$M(http, getEntityUrl$1(params));
|
|
3192
3363
|
|
|
3193
3364
|
var TeamMembership = /*#__PURE__*/Object.freeze({
|
|
3194
3365
|
__proto__: null,
|
|
3195
|
-
create: create$
|
|
3196
|
-
del: del$
|
|
3197
|
-
get: get$
|
|
3366
|
+
create: create$7,
|
|
3367
|
+
del: del$6,
|
|
3368
|
+
get: get$8,
|
|
3198
3369
|
getManyForOrganization: getManyForOrganization$3,
|
|
3199
3370
|
getManyForTeam: getManyForTeam,
|
|
3200
3371
|
update: update$6
|
|
3201
3372
|
});
|
|
3202
3373
|
|
|
3203
|
-
const getBaseUrl$
|
|
3204
|
-
const getEntityUrl = (params) => `${getBaseUrl$
|
|
3205
|
-
const get$
|
|
3206
|
-
const getMany$
|
|
3374
|
+
const getBaseUrl$7 = (params) => `/spaces/${params.spaceId}/team_space_memberships`;
|
|
3375
|
+
const getEntityUrl = (params) => `${getBaseUrl$7(params)}/${params.teamSpaceMembershipId}`;
|
|
3376
|
+
const get$7 = (http, params) => get$19(http, getEntityUrl(params));
|
|
3377
|
+
const getMany$6 = (http, params) => get$19(http, getBaseUrl$7(params), {
|
|
3207
3378
|
params: params.query,
|
|
3208
3379
|
});
|
|
3209
3380
|
const getForOrganization$1 = (http, params) => {
|
|
3210
|
-
return get$
|
|
3381
|
+
return get$19(http, `/organizations/${params.organizationId}/team_space_memberships/${params.teamSpaceMembershipId}`);
|
|
3211
3382
|
};
|
|
3212
3383
|
const getManyForOrganization$2 = (http, params) => {
|
|
3213
3384
|
const query = params.query || {};
|
|
3214
3385
|
if (params.teamId) {
|
|
3215
3386
|
query['sys.team.sys.id'] = params.teamId;
|
|
3216
3387
|
}
|
|
3217
|
-
return get$
|
|
3388
|
+
return get$19(http, `/organizations/${params.organizationId}/team_space_memberships`, {
|
|
3218
3389
|
params: params.query,
|
|
3219
3390
|
});
|
|
3220
3391
|
};
|
|
3221
|
-
const create$
|
|
3222
|
-
return post$1(http, getBaseUrl$
|
|
3392
|
+
const create$6 = (http, params, rawData, headers) => {
|
|
3393
|
+
return post$1(http, getBaseUrl$7(params), rawData, {
|
|
3223
3394
|
headers: {
|
|
3224
3395
|
'x-contentful-team': params.teamId,
|
|
3225
3396
|
...headers,
|
|
@@ -3237,24 +3408,80 @@ const update$5 = (http, params, rawData, headers) => {
|
|
|
3237
3408
|
},
|
|
3238
3409
|
});
|
|
3239
3410
|
};
|
|
3240
|
-
const del$
|
|
3241
|
-
return del$
|
|
3411
|
+
const del$5 = (http, params) => {
|
|
3412
|
+
return del$M(http, getEntityUrl(params));
|
|
3242
3413
|
};
|
|
3243
3414
|
|
|
3244
3415
|
var TeamSpaceMembership = /*#__PURE__*/Object.freeze({
|
|
3245
3416
|
__proto__: null,
|
|
3246
|
-
create: create$
|
|
3247
|
-
del: del$
|
|
3248
|
-
get: get$
|
|
3417
|
+
create: create$6,
|
|
3418
|
+
del: del$5,
|
|
3419
|
+
get: get$7,
|
|
3249
3420
|
getForOrganization: getForOrganization$1,
|
|
3250
|
-
getMany: getMany$
|
|
3421
|
+
getMany: getMany$6,
|
|
3251
3422
|
getManyForOrganization: getManyForOrganization$2,
|
|
3252
3423
|
update: update$5
|
|
3253
3424
|
});
|
|
3254
3425
|
|
|
3426
|
+
const getBaseUrl$6 = (params) => `/spaces/${params.spaceId}/environments/${params.environmentId}/templates`;
|
|
3427
|
+
const getMany$5 = (http, params, headers) => {
|
|
3428
|
+
return get$19(http, getBaseUrl$6(params), {
|
|
3429
|
+
params: params.query,
|
|
3430
|
+
headers,
|
|
3431
|
+
});
|
|
3432
|
+
};
|
|
3433
|
+
const get$6 = (http, params, headers) => {
|
|
3434
|
+
return get$19(http, getBaseUrl$6(params) + `/${params.templateId}`, { headers });
|
|
3435
|
+
};
|
|
3436
|
+
const create$5 = (http, params, rawData, headers) => {
|
|
3437
|
+
const data = copy__default.default(rawData);
|
|
3438
|
+
return post$1(http, getBaseUrl$6(params), data, { headers });
|
|
3439
|
+
};
|
|
3440
|
+
const upsert$1 = (http, params, rawData, headers) => {
|
|
3441
|
+
const { sys, ...body } = copy__default.default(rawData);
|
|
3442
|
+
return put$1(http, getBaseUrl$6(params) + `/${params.templateId}`, body, {
|
|
3443
|
+
headers: {
|
|
3444
|
+
...(sys.version !== undefined && {
|
|
3445
|
+
'X-Contentful-Version': sys.version,
|
|
3446
|
+
}),
|
|
3447
|
+
...headers,
|
|
3448
|
+
},
|
|
3449
|
+
});
|
|
3450
|
+
};
|
|
3451
|
+
const del$4 = (http, params) => {
|
|
3452
|
+
return del$M(http, getBaseUrl$6(params) + `/${params.templateId}`);
|
|
3453
|
+
};
|
|
3454
|
+
const publish$1 = (http, params, headers) => {
|
|
3455
|
+
return put$1(http, getBaseUrl$6(params) + `/${params.templateId}/published`, null, {
|
|
3456
|
+
headers: {
|
|
3457
|
+
'X-Contentful-Version': params.version,
|
|
3458
|
+
...headers,
|
|
3459
|
+
},
|
|
3460
|
+
});
|
|
3461
|
+
};
|
|
3462
|
+
const unpublish$1 = (http, params, headers) => {
|
|
3463
|
+
return del$M(http, getBaseUrl$6(params) + `/${params.templateId}/published`, {
|
|
3464
|
+
headers: {
|
|
3465
|
+
'X-Contentful-Version': params.version,
|
|
3466
|
+
...headers,
|
|
3467
|
+
},
|
|
3468
|
+
});
|
|
3469
|
+
};
|
|
3470
|
+
|
|
3471
|
+
var Template = /*#__PURE__*/Object.freeze({
|
|
3472
|
+
__proto__: null,
|
|
3473
|
+
create: create$5,
|
|
3474
|
+
del: del$4,
|
|
3475
|
+
get: get$6,
|
|
3476
|
+
getMany: getMany$5,
|
|
3477
|
+
publish: publish$1,
|
|
3478
|
+
unpublish: unpublish$1,
|
|
3479
|
+
upsert: upsert$1
|
|
3480
|
+
});
|
|
3481
|
+
|
|
3255
3482
|
const getUrl$1 = (params) => `/spaces/${params.spaceId}/environments/${params.environmentId}/ui_config`;
|
|
3256
|
-
const get$
|
|
3257
|
-
return get$
|
|
3483
|
+
const get$5 = (http, params) => {
|
|
3484
|
+
return get$19(http, getUrl$1(params));
|
|
3258
3485
|
};
|
|
3259
3486
|
const update$4 = (http, params, rawData) => {
|
|
3260
3487
|
const data = copy__default.default(rawData);
|
|
@@ -3268,10 +3495,68 @@ const update$4 = (http, params, rawData) => {
|
|
|
3268
3495
|
|
|
3269
3496
|
var UIConfig = /*#__PURE__*/Object.freeze({
|
|
3270
3497
|
__proto__: null,
|
|
3271
|
-
get: get$
|
|
3498
|
+
get: get$5,
|
|
3272
3499
|
update: update$4
|
|
3273
3500
|
});
|
|
3274
3501
|
|
|
3502
|
+
const getBaseUrl$5 = (params) => `/spaces/${params.spaceId}/environments/${params.environmentId}/experiences`;
|
|
3503
|
+
const getMany$4 = (http, params, headers) => {
|
|
3504
|
+
return get$19(http, getBaseUrl$5(params), {
|
|
3505
|
+
params: params.query,
|
|
3506
|
+
headers,
|
|
3507
|
+
});
|
|
3508
|
+
};
|
|
3509
|
+
const get$4 = (http, params, headers) => {
|
|
3510
|
+
return get$19(http, getBaseUrl$5(params) + `/${params.experienceId}`, {
|
|
3511
|
+
headers,
|
|
3512
|
+
});
|
|
3513
|
+
};
|
|
3514
|
+
const create$4 = (http, params, rawData, headers) => {
|
|
3515
|
+
const data = copy__default.default(rawData);
|
|
3516
|
+
return post$1(http, getBaseUrl$5(params), data, { headers });
|
|
3517
|
+
};
|
|
3518
|
+
const upsert = (http, params, rawData, headers) => {
|
|
3519
|
+
const { sys, ...body } = copy__default.default(rawData);
|
|
3520
|
+
return put$1(http, getBaseUrl$5(params) + `/${params.experienceId}`, body, {
|
|
3521
|
+
headers: {
|
|
3522
|
+
...(sys.version !== undefined && {
|
|
3523
|
+
'X-Contentful-Version': sys.version,
|
|
3524
|
+
}),
|
|
3525
|
+
...headers,
|
|
3526
|
+
},
|
|
3527
|
+
});
|
|
3528
|
+
};
|
|
3529
|
+
const del$3 = (http, params) => {
|
|
3530
|
+
return del$M(http, getBaseUrl$5(params) + `/${params.experienceId}`);
|
|
3531
|
+
};
|
|
3532
|
+
const publish = (http, params, payload, headers) => {
|
|
3533
|
+
return put$1(http, getBaseUrl$5(params) + `/${params.experienceId}/published`, payload ?? null, {
|
|
3534
|
+
headers: {
|
|
3535
|
+
'X-Contentful-Version': params.version,
|
|
3536
|
+
...headers,
|
|
3537
|
+
},
|
|
3538
|
+
});
|
|
3539
|
+
};
|
|
3540
|
+
const unpublish = (http, params, headers) => {
|
|
3541
|
+
return del$M(http, getBaseUrl$5(params) + `/${params.experienceId}/published`, {
|
|
3542
|
+
headers: {
|
|
3543
|
+
'X-Contentful-Version': params.version,
|
|
3544
|
+
...headers,
|
|
3545
|
+
},
|
|
3546
|
+
});
|
|
3547
|
+
};
|
|
3548
|
+
|
|
3549
|
+
var Experience = /*#__PURE__*/Object.freeze({
|
|
3550
|
+
__proto__: null,
|
|
3551
|
+
create: create$4,
|
|
3552
|
+
del: del$3,
|
|
3553
|
+
get: get$4,
|
|
3554
|
+
getMany: getMany$4,
|
|
3555
|
+
publish: publish,
|
|
3556
|
+
unpublish: unpublish,
|
|
3557
|
+
upsert: upsert
|
|
3558
|
+
});
|
|
3559
|
+
|
|
3275
3560
|
const getBaseUrl$4 = (params) => {
|
|
3276
3561
|
return `/spaces/${params.spaceId}/environments/${params.environmentId ?? 'master'}/upload_credentials`;
|
|
3277
3562
|
};
|
|
@@ -3287,12 +3572,12 @@ var UploadCredential = /*#__PURE__*/Object.freeze({
|
|
|
3287
3572
|
});
|
|
3288
3573
|
|
|
3289
3574
|
const getManyForSpace$1 = (http, params) => {
|
|
3290
|
-
return get$
|
|
3575
|
+
return get$19(http, `/organizations/${params.organizationId}/space_periodic_usages`, {
|
|
3291
3576
|
params: params.query,
|
|
3292
3577
|
});
|
|
3293
3578
|
};
|
|
3294
3579
|
const getManyForOrganization$1 = (http, params) => {
|
|
3295
|
-
return get$
|
|
3580
|
+
return get$19(http, `/organizations/${params.organizationId}/organization_periodic_usages`, {
|
|
3296
3581
|
params: params.query,
|
|
3297
3582
|
});
|
|
3298
3583
|
};
|
|
@@ -3304,19 +3589,19 @@ var Usage = /*#__PURE__*/Object.freeze({
|
|
|
3304
3589
|
});
|
|
3305
3590
|
|
|
3306
3591
|
const getForSpace = (http, params) => {
|
|
3307
|
-
return get$
|
|
3592
|
+
return get$19(http, `/spaces/${params.spaceId}/users/${params.userId}`);
|
|
3308
3593
|
};
|
|
3309
|
-
const getCurrent = (http, params) => get$
|
|
3594
|
+
const getCurrent = (http, params) => get$19(http, `/users/me`, { params: params?.query });
|
|
3310
3595
|
const getManyForSpace = (http, params) => {
|
|
3311
|
-
return get$
|
|
3596
|
+
return get$19(http, `/spaces/${params.spaceId}/users`, {
|
|
3312
3597
|
params: params.query,
|
|
3313
3598
|
});
|
|
3314
3599
|
};
|
|
3315
3600
|
const getForOrganization = (http, params) => {
|
|
3316
|
-
return get$
|
|
3601
|
+
return get$19(http, `/organizations/${params.organizationId}/users/${params.userId}`);
|
|
3317
3602
|
};
|
|
3318
3603
|
const getManyForOrganization = (http, params) => {
|
|
3319
|
-
return get$
|
|
3604
|
+
return get$19(http, `/organizations/${params.organizationId}/users`, {
|
|
3320
3605
|
params: params.query,
|
|
3321
3606
|
});
|
|
3322
3607
|
};
|
|
@@ -3332,7 +3617,7 @@ var User = /*#__PURE__*/Object.freeze({
|
|
|
3332
3617
|
|
|
3333
3618
|
const getUrl = (params) => `/spaces/${params.spaceId}/environments/${params.environmentId}/ui_config/me`;
|
|
3334
3619
|
const get$3 = (http, params) => {
|
|
3335
|
-
return get$
|
|
3620
|
+
return get$19(http, getUrl(params));
|
|
3336
3621
|
};
|
|
3337
3622
|
const update$3 = (http, params, rawData) => {
|
|
3338
3623
|
const data = copy__default.default(rawData);
|
|
@@ -3360,32 +3645,32 @@ const getWebhookSettingsUrl = (params) => `/spaces/${params.spaceId}/webhook_set
|
|
|
3360
3645
|
const getWebhookSigningSecretUrl = (params) => `${getWebhookSettingsUrl(params)}/signing_secret`;
|
|
3361
3646
|
const getWebhookRetryPolicyUrl = (params) => `${getWebhookSettingsUrl(params)}/retry_policy`;
|
|
3362
3647
|
const get$2 = (http, params) => {
|
|
3363
|
-
return get$
|
|
3648
|
+
return get$19(http, getWebhookUrl(params));
|
|
3364
3649
|
};
|
|
3365
3650
|
const getManyCallDetails = (http, params) => {
|
|
3366
|
-
return get$
|
|
3651
|
+
return get$19(http, getWebhookCallUrl(params), {
|
|
3367
3652
|
params: normalizeSelect(params.query),
|
|
3368
3653
|
});
|
|
3369
3654
|
};
|
|
3370
3655
|
const getCallDetails = (http, params) => {
|
|
3371
|
-
return get$
|
|
3656
|
+
return get$19(http, getWebhookCallDetailsUrl(params));
|
|
3372
3657
|
};
|
|
3373
3658
|
const getHealthStatus = (http, params) => {
|
|
3374
|
-
return get$
|
|
3659
|
+
return get$19(http, getWebhookHealthUrl(params));
|
|
3375
3660
|
};
|
|
3376
3661
|
const getMany$3 = (http, params) => {
|
|
3377
|
-
return get$
|
|
3662
|
+
return get$19(http, getBaseUrl$3(params), {
|
|
3378
3663
|
params: normalizeSelect(params.query),
|
|
3379
3664
|
});
|
|
3380
3665
|
};
|
|
3381
3666
|
const getSigningSecret = (http, params) => {
|
|
3382
|
-
return get$
|
|
3667
|
+
return get$19(http, getWebhookSigningSecretUrl(params));
|
|
3383
3668
|
};
|
|
3384
3669
|
/**
|
|
3385
3670
|
* @deprecated The EAP for this feature has ended. This method will be removed in the next major version.
|
|
3386
3671
|
*/
|
|
3387
3672
|
const getRetryPolicy = (http, params) => {
|
|
3388
|
-
return get$
|
|
3673
|
+
return get$19(http, getWebhookRetryPolicyUrl(params));
|
|
3389
3674
|
};
|
|
3390
3675
|
const create$2 = (http, params, rawData, headers) => {
|
|
3391
3676
|
const data = copy__default.default(rawData);
|
|
@@ -3417,16 +3702,16 @@ const upsertRetryPolicy = async (http, params, rawData) => {
|
|
|
3417
3702
|
return put$1(http, getWebhookRetryPolicyUrl(params), data);
|
|
3418
3703
|
};
|
|
3419
3704
|
const del$2 = (http, params) => {
|
|
3420
|
-
return del$
|
|
3705
|
+
return del$M(http, getWebhookUrl(params));
|
|
3421
3706
|
};
|
|
3422
3707
|
const deleteSigningSecret = async (http, params) => {
|
|
3423
|
-
return del$
|
|
3708
|
+
return del$M(http, getWebhookSigningSecretUrl(params));
|
|
3424
3709
|
};
|
|
3425
3710
|
/**
|
|
3426
3711
|
* @deprecated The EAP for this feature has ended. This method will be removed in the next major version.
|
|
3427
3712
|
*/
|
|
3428
3713
|
const deleteRetryPolicy = async (http, params) => {
|
|
3429
|
-
return del$
|
|
3714
|
+
return del$M(http, getWebhookRetryPolicyUrl(params));
|
|
3430
3715
|
};
|
|
3431
3716
|
|
|
3432
3717
|
var Webhook = /*#__PURE__*/Object.freeze({
|
|
@@ -3451,11 +3736,11 @@ var Webhook = /*#__PURE__*/Object.freeze({
|
|
|
3451
3736
|
const getBaseUrl$2 = (params) => `/spaces/${params.spaceId}/environments/${params.environmentId}/workflows`;
|
|
3452
3737
|
const getWorkflowUrl = (params) => `${getBaseUrl$2(params)}/${params.workflowId}`;
|
|
3453
3738
|
const completeWorkflowUrl = (params) => `${getWorkflowUrl(params)}/complete`;
|
|
3454
|
-
const getMany$2 = (http, params, headers) => get$
|
|
3739
|
+
const getMany$2 = (http, params, headers) => get$19(http, getBaseUrl$2(params), {
|
|
3455
3740
|
headers,
|
|
3456
3741
|
params: params.query,
|
|
3457
3742
|
});
|
|
3458
|
-
const get$1 = (http, params, headers) => get$
|
|
3743
|
+
const get$1 = (http, params, headers) => get$19(http, getWorkflowUrl(params), {
|
|
3459
3744
|
headers,
|
|
3460
3745
|
});
|
|
3461
3746
|
const create$1 = (http, params, rawData, headers) => {
|
|
@@ -3475,7 +3760,7 @@ const update$1 = (http, params, rawData, headers) => {
|
|
|
3475
3760
|
});
|
|
3476
3761
|
};
|
|
3477
3762
|
const del$1 = (http, { version, ...params }, headers) => {
|
|
3478
|
-
return del$
|
|
3763
|
+
return del$M(http, getWorkflowUrl(params), {
|
|
3479
3764
|
headers: { 'X-Contentful-Version': version, ...headers },
|
|
3480
3765
|
});
|
|
3481
3766
|
};
|
|
@@ -3497,10 +3782,10 @@ var Workflow = /*#__PURE__*/Object.freeze({
|
|
|
3497
3782
|
|
|
3498
3783
|
const getBaseUrl$1 = (params) => `/spaces/${params.spaceId}/environments/${params.environmentId}/workflow_definitions`;
|
|
3499
3784
|
const getWorkflowDefinitionUrl = (params) => `${getBaseUrl$1(params)}/${params.workflowDefinitionId}`;
|
|
3500
|
-
const get = (http, params, headers) => get$
|
|
3785
|
+
const get = (http, params, headers) => get$19(http, getWorkflowDefinitionUrl(params), {
|
|
3501
3786
|
headers,
|
|
3502
3787
|
});
|
|
3503
|
-
const getMany$1 = (http, params, headers) => get$
|
|
3788
|
+
const getMany$1 = (http, params, headers) => get$19(http, getBaseUrl$1(params), {
|
|
3504
3789
|
headers,
|
|
3505
3790
|
params: params.query,
|
|
3506
3791
|
});
|
|
@@ -3521,7 +3806,7 @@ const update = (http, params, rawData, headers) => {
|
|
|
3521
3806
|
});
|
|
3522
3807
|
};
|
|
3523
3808
|
const del = (http, { version, ...params }, headers) => {
|
|
3524
|
-
return del$
|
|
3809
|
+
return del$M(http, getWorkflowDefinitionUrl(params), {
|
|
3525
3810
|
headers: { 'X-Contentful-Version': version, ...headers },
|
|
3526
3811
|
});
|
|
3527
3812
|
};
|
|
@@ -3536,7 +3821,7 @@ var WorkflowDefinition = /*#__PURE__*/Object.freeze({
|
|
|
3536
3821
|
});
|
|
3537
3822
|
|
|
3538
3823
|
const getBaseUrl = (params) => `/spaces/${params.spaceId}/environments/${params.environmentId}/workflows_changelog`;
|
|
3539
|
-
const getMany = (http, params, headers) => get$
|
|
3824
|
+
const getMany = (http, params, headers) => get$19(http, getBaseUrl(params), {
|
|
3540
3825
|
headers,
|
|
3541
3826
|
params: params.query,
|
|
3542
3827
|
});
|
|
@@ -3575,6 +3860,7 @@ var endpoints = {
|
|
|
3575
3860
|
Concept,
|
|
3576
3861
|
ConceptScheme,
|
|
3577
3862
|
ContentType,
|
|
3863
|
+
DataAssembly,
|
|
3578
3864
|
EditorInterface,
|
|
3579
3865
|
EligibleLicense,
|
|
3580
3866
|
Entry,
|
|
@@ -3583,6 +3869,7 @@ var endpoints = {
|
|
|
3583
3869
|
EnvironmentTemplate,
|
|
3584
3870
|
EnvironmentTemplateInstallation,
|
|
3585
3871
|
Extension,
|
|
3872
|
+
Fragment,
|
|
3586
3873
|
Function,
|
|
3587
3874
|
FunctionLog,
|
|
3588
3875
|
Http,
|
|
@@ -3619,9 +3906,11 @@ var endpoints = {
|
|
|
3619
3906
|
Team,
|
|
3620
3907
|
TeamMembership,
|
|
3621
3908
|
TeamSpaceMembership,
|
|
3909
|
+
Template,
|
|
3622
3910
|
UIConfig,
|
|
3623
3911
|
Upload,
|
|
3624
3912
|
UploadCredential,
|
|
3913
|
+
Experience,
|
|
3625
3914
|
Usage,
|
|
3626
3915
|
User,
|
|
3627
3916
|
UserUIConfig,
|
|
@@ -14087,6 +14376,12 @@ const createPlainClient = (makeRequest, defaults) => {
|
|
|
14087
14376
|
},
|
|
14088
14377
|
componentType: {
|
|
14089
14378
|
getMany: wrap(wrapParams, 'ComponentType', 'getMany'),
|
|
14379
|
+
get: wrap(wrapParams, 'ComponentType', 'get'),
|
|
14380
|
+
create: wrap(wrapParams, 'ComponentType', 'create'),
|
|
14381
|
+
upsert: wrap(wrapParams, 'ComponentType', 'upsert'),
|
|
14382
|
+
delete: wrap(wrapParams, 'ComponentType', 'delete'),
|
|
14383
|
+
publish: wrap(wrapParams, 'ComponentType', 'publish'),
|
|
14384
|
+
unpublish: wrap(wrapParams, 'ComponentType', 'unpublish'),
|
|
14090
14385
|
},
|
|
14091
14386
|
contentType: {
|
|
14092
14387
|
get: wrap(wrapParams, 'ContentType', 'get'),
|
|
@@ -14100,6 +14395,17 @@ const createPlainClient = (makeRequest, defaults) => {
|
|
|
14100
14395
|
createWithId: wrap(wrapParams, 'ContentType', 'createWithId'),
|
|
14101
14396
|
omitAndDeleteField: (params, contentType, fieldId) => omitAndDeleteField(makeRequest, { ...{ ...defaults, ...params }, fieldId }, contentType),
|
|
14102
14397
|
},
|
|
14398
|
+
dataAssembly: {
|
|
14399
|
+
getMany: wrap(wrapParams, 'DataAssembly', 'getMany'),
|
|
14400
|
+
getManyPublished: wrap(wrapParams, 'DataAssembly', 'getManyPublished'),
|
|
14401
|
+
getPublished: wrap(wrapParams, 'DataAssembly', 'getPublished'),
|
|
14402
|
+
get: wrap(wrapParams, 'DataAssembly', 'get'),
|
|
14403
|
+
create: wrap(wrapParams, 'DataAssembly', 'create'),
|
|
14404
|
+
update: wrap(wrapParams, 'DataAssembly', 'update'),
|
|
14405
|
+
delete: wrap(wrapParams, 'DataAssembly', 'delete'),
|
|
14406
|
+
publish: wrap(wrapParams, 'DataAssembly', 'publish'),
|
|
14407
|
+
unpublish: wrap(wrapParams, 'DataAssembly', 'unpublish'),
|
|
14408
|
+
},
|
|
14103
14409
|
user: {
|
|
14104
14410
|
getManyForSpace: wrap(wrapParams, 'User', 'getManyForSpace'),
|
|
14105
14411
|
getForSpace: wrap(wrapParams, 'User', 'getForSpace'),
|
|
@@ -14447,6 +14753,24 @@ const createPlainClient = (makeRequest, defaults) => {
|
|
|
14447
14753
|
update: wrap(wrapParams, 'TeamSpaceMembership', 'update'),
|
|
14448
14754
|
delete: wrap(wrapParams, 'TeamSpaceMembership', 'delete'),
|
|
14449
14755
|
},
|
|
14756
|
+
fragment: {
|
|
14757
|
+
getMany: wrap(wrapParams, 'Fragment', 'getMany'),
|
|
14758
|
+
get: wrap(wrapParams, 'Fragment', 'get'),
|
|
14759
|
+
create: wrap(wrapParams, 'Fragment', 'create'),
|
|
14760
|
+
update: wrap(wrapParams, 'Fragment', 'update'),
|
|
14761
|
+
delete: wrap(wrapParams, 'Fragment', 'delete'),
|
|
14762
|
+
publish: wrap(wrapParams, 'Fragment', 'publish'),
|
|
14763
|
+
unpublish: wrap(wrapParams, 'Fragment', 'unpublish'),
|
|
14764
|
+
},
|
|
14765
|
+
template: {
|
|
14766
|
+
getMany: wrap(wrapParams, 'Template', 'getMany'),
|
|
14767
|
+
get: wrap(wrapParams, 'Template', 'get'),
|
|
14768
|
+
create: wrap(wrapParams, 'Template', 'create'),
|
|
14769
|
+
upsert: wrap(wrapParams, 'Template', 'upsert'),
|
|
14770
|
+
delete: wrap(wrapParams, 'Template', 'delete'),
|
|
14771
|
+
publish: wrap(wrapParams, 'Template', 'publish'),
|
|
14772
|
+
unpublish: wrap(wrapParams, 'Template', 'unpublish'),
|
|
14773
|
+
},
|
|
14450
14774
|
uiConfig: {
|
|
14451
14775
|
get: wrap(wrapParams, 'UIConfig', 'get'),
|
|
14452
14776
|
update: wrap(wrapParams, 'UIConfig', 'update'),
|
|
@@ -14455,6 +14779,15 @@ const createPlainClient = (makeRequest, defaults) => {
|
|
|
14455
14779
|
get: wrap(wrapParams, 'UserUIConfig', 'get'),
|
|
14456
14780
|
update: wrap(wrapParams, 'UserUIConfig', 'update'),
|
|
14457
14781
|
},
|
|
14782
|
+
experience: {
|
|
14783
|
+
getMany: wrap(wrapParams, 'Experience', 'getMany'),
|
|
14784
|
+
get: wrap(wrapParams, 'Experience', 'get'),
|
|
14785
|
+
create: wrap(wrapParams, 'Experience', 'create'),
|
|
14786
|
+
upsert: wrap(wrapParams, 'Experience', 'upsert'),
|
|
14787
|
+
delete: wrap(wrapParams, 'Experience', 'delete'),
|
|
14788
|
+
publish: wrap(wrapParams, 'Experience', 'publish'),
|
|
14789
|
+
unpublish: wrap(wrapParams, 'Experience', 'unpublish'),
|
|
14790
|
+
},
|
|
14458
14791
|
workflowDefinition: {
|
|
14459
14792
|
get: wrap(wrapParams, 'WorkflowDefinition', 'get'),
|
|
14460
14793
|
getMany: wrap(wrapParams, 'WorkflowDefinition', 'getMany'),
|