@remkoj/optimizely-cms-api 6.0.0-pre12 → 6.0.0-pre14
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 +6 -2
- package/dist/api-client.js +2 -2
- package/dist/client/client/client.gen.js +26 -1
- package/dist/client/client/index.d.ts +1 -1
- package/dist/client/client/types.gen.d.ts +2 -9
- package/dist/client/client.gen.js +2 -4
- package/dist/client/core/params.gen.d.ts +10 -0
- package/dist/client/core/params.gen.js +17 -5
- package/dist/client/core/serverSentEvents.gen.js +2 -0
- package/dist/client/index.d.ts +4 -4
- package/dist/client/index.js +97 -17
- package/dist/client/sdk.gen.d.ts +188 -1
- package/dist/client/sdk.gen.js +482 -144
- package/dist/client/transformers.gen.d.ts +27 -1
- package/dist/client/transformers.gen.js +229 -29
- package/dist/client/types.gen.d.ts +1753 -29
- package/dist/client-config.js +1 -1
- package/dist/instance.client/client/client.gen.js +26 -1
- package/dist/instance.client/client/index.d.ts +1 -1
- package/dist/instance.client/client/types.gen.d.ts +2 -9
- package/dist/instance.client/client.gen.js +2 -4
- package/dist/instance.client/core/params.gen.d.ts +10 -0
- package/dist/instance.client/core/params.gen.js +17 -5
- package/dist/instance.client/core/serverSentEvents.gen.js +2 -0
- package/dist/instance.client/index.d.ts +4 -4
- package/dist/instance.client/index.js +86 -18
- package/dist/instance.client/sdk.gen.js +273 -405
- package/dist/instance.client/transformers.gen.d.ts +1 -15
- package/dist/instance.client/transformers.gen.js +26 -198
- package/dist/instance.client/types.gen.d.ts +48 -64
- package/dist/version.json +2 -2
- package/package.json +7 -7
|
@@ -9,56 +9,48 @@ const transformers_gen_1 = require("./transformers.gen");
|
|
|
9
9
|
*
|
|
10
10
|
* Lists all changeset using the provided options.
|
|
11
11
|
*/
|
|
12
|
-
const changesetsList = (options) => {
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
});
|
|
18
|
-
};
|
|
12
|
+
const changesetsList = (options) => (options?.client ?? client_gen_1.client).get({
|
|
13
|
+
responseTransformer: transformers_gen_1.changesetsListResponseTransformer,
|
|
14
|
+
url: '/changesets',
|
|
15
|
+
...options
|
|
16
|
+
});
|
|
19
17
|
exports.changesetsList = changesetsList;
|
|
20
18
|
/**
|
|
21
19
|
* Create changeset
|
|
22
20
|
*
|
|
23
21
|
* Creates a new changeset.
|
|
24
22
|
*/
|
|
25
|
-
const changesetsCreate = (options) => {
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
});
|
|
35
|
-
};
|
|
23
|
+
const changesetsCreate = (options) => (options.client ?? client_gen_1.client).post({
|
|
24
|
+
responseTransformer: transformers_gen_1.changesetsCreateResponseTransformer,
|
|
25
|
+
url: '/changesets',
|
|
26
|
+
...options,
|
|
27
|
+
headers: {
|
|
28
|
+
'Content-Type': 'application/json',
|
|
29
|
+
...options.headers
|
|
30
|
+
}
|
|
31
|
+
});
|
|
36
32
|
exports.changesetsCreate = changesetsCreate;
|
|
37
33
|
/**
|
|
38
34
|
* Delete changeset
|
|
39
35
|
*
|
|
40
36
|
* Deletes the changeset with the provided key. If a changeset with the provided key does not exist an error is returned.
|
|
41
37
|
*/
|
|
42
|
-
const changesetsDelete = (options) => {
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
});
|
|
48
|
-
};
|
|
38
|
+
const changesetsDelete = (options) => (options.client ?? client_gen_1.client).delete({
|
|
39
|
+
responseTransformer: transformers_gen_1.changesetsDeleteResponseTransformer,
|
|
40
|
+
url: '/changesets/{key}',
|
|
41
|
+
...options
|
|
42
|
+
});
|
|
49
43
|
exports.changesetsDelete = changesetsDelete;
|
|
50
44
|
/**
|
|
51
45
|
* Get changeset
|
|
52
46
|
*
|
|
53
47
|
* Gets the changeset with the provided key.
|
|
54
48
|
*/
|
|
55
|
-
const changesetsGet = (options) => {
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
});
|
|
61
|
-
};
|
|
49
|
+
const changesetsGet = (options) => (options.client ?? client_gen_1.client).get({
|
|
50
|
+
responseTransformer: transformers_gen_1.changesetsGetResponseTransformer,
|
|
51
|
+
url: '/changesets/{key}',
|
|
52
|
+
...options
|
|
53
|
+
});
|
|
62
54
|
exports.changesetsGet = changesetsGet;
|
|
63
55
|
/**
|
|
64
56
|
* Create or replace changeset
|
|
@@ -66,43 +58,29 @@ exports.changesetsGet = changesetsGet;
|
|
|
66
58
|
* Creates or replaces a changeset. If a changeset with the provided key exist it is replaced.
|
|
67
59
|
* Otherwise a new changeset is created.
|
|
68
60
|
*/
|
|
69
|
-
const changesetsPut = (options) => {
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
|
|
76
|
-
|
|
77
|
-
|
|
78
|
-
});
|
|
79
|
-
};
|
|
61
|
+
const changesetsPut = (options) => (options.client ?? client_gen_1.client).put({
|
|
62
|
+
responseTransformer: transformers_gen_1.changesetsPutResponseTransformer,
|
|
63
|
+
url: '/changesets/{key}',
|
|
64
|
+
...options,
|
|
65
|
+
headers: {
|
|
66
|
+
'Content-Type': 'application/json',
|
|
67
|
+
...options.headers
|
|
68
|
+
}
|
|
69
|
+
});
|
|
80
70
|
exports.changesetsPut = changesetsPut;
|
|
81
71
|
/**
|
|
82
72
|
* Delete changeset item
|
|
83
73
|
*
|
|
84
74
|
* Deletes the specified changeset item from the changeset.
|
|
85
75
|
*/
|
|
86
|
-
const changesetsDeleteItem = (options) => {
|
|
87
|
-
return (options.client ?? client_gen_1.client).delete({
|
|
88
|
-
responseTransformer: transformers_gen_1.changesetsDeleteItemResponseTransformer,
|
|
89
|
-
url: '/changesets/{changeset}/items/{key}/versions/{version}',
|
|
90
|
-
...options
|
|
91
|
-
});
|
|
92
|
-
};
|
|
76
|
+
const changesetsDeleteItem = (options) => (options.client ?? client_gen_1.client).delete({ url: '/changesets/{changeset}/items/{key}/versions/{version}', ...options });
|
|
93
77
|
exports.changesetsDeleteItem = changesetsDeleteItem;
|
|
94
78
|
/**
|
|
95
79
|
* Get changeset item
|
|
96
80
|
*
|
|
97
81
|
* Gets the changeset item for the specified content reference.
|
|
98
82
|
*/
|
|
99
|
-
const changesetsGetItem = (options) => {
|
|
100
|
-
return (options.client ?? client_gen_1.client).get({
|
|
101
|
-
responseTransformer: transformers_gen_1.changesetsGetItemResponseTransformer,
|
|
102
|
-
url: '/changesets/{changeset}/items/{key}/versions/{version}',
|
|
103
|
-
...options
|
|
104
|
-
});
|
|
105
|
-
};
|
|
83
|
+
const changesetsGetItem = (options) => (options.client ?? client_gen_1.client).get({ url: '/changesets/{changeset}/items/{key}/versions/{version}', ...options });
|
|
106
84
|
exports.changesetsGetItem = changesetsGetItem;
|
|
107
85
|
/**
|
|
108
86
|
* List changeset items
|
|
@@ -110,348 +88,294 @@ exports.changesetsGetItem = changesetsGetItem;
|
|
|
110
88
|
* Lists the available changeset items for the specified changeset using
|
|
111
89
|
* the provided options.
|
|
112
90
|
*/
|
|
113
|
-
const changesetsListItems = (options) => {
|
|
114
|
-
return (options.client ?? client_gen_1.client).get({
|
|
115
|
-
responseTransformer: transformers_gen_1.changesetsListItemsResponseTransformer,
|
|
116
|
-
url: '/changesets/{changeset}/items',
|
|
117
|
-
...options
|
|
118
|
-
});
|
|
119
|
-
};
|
|
91
|
+
const changesetsListItems = (options) => (options.client ?? client_gen_1.client).get({ url: '/changesets/{changeset}/items', ...options });
|
|
120
92
|
exports.changesetsListItems = changesetsListItems;
|
|
121
93
|
/**
|
|
122
94
|
* Create changeset item
|
|
123
95
|
*
|
|
124
96
|
* Creates the given changeset item.
|
|
125
97
|
*/
|
|
126
|
-
const changesetsCreateItem = (options) => {
|
|
127
|
-
|
|
128
|
-
|
|
129
|
-
|
|
130
|
-
|
|
131
|
-
headers
|
|
132
|
-
|
|
133
|
-
|
|
134
|
-
}
|
|
135
|
-
});
|
|
136
|
-
};
|
|
98
|
+
const changesetsCreateItem = (options) => (options.client ?? client_gen_1.client).post({
|
|
99
|
+
url: '/changesets/{changeset}/items',
|
|
100
|
+
...options,
|
|
101
|
+
headers: {
|
|
102
|
+
'Content-Type': 'application/json',
|
|
103
|
+
...options.headers
|
|
104
|
+
}
|
|
105
|
+
});
|
|
137
106
|
exports.changesetsCreateItem = changesetsCreateItem;
|
|
138
107
|
/**
|
|
139
108
|
* Update changeset item
|
|
140
109
|
*
|
|
141
110
|
* Updates the given changeset item.
|
|
142
111
|
*/
|
|
143
|
-
const changesetsUpdateItem = (options) => {
|
|
144
|
-
|
|
145
|
-
|
|
146
|
-
|
|
147
|
-
|
|
148
|
-
headers
|
|
149
|
-
|
|
150
|
-
|
|
151
|
-
}
|
|
152
|
-
});
|
|
153
|
-
};
|
|
112
|
+
const changesetsUpdateItem = (options) => (options.client ?? client_gen_1.client).put({
|
|
113
|
+
url: '/changesets/{changeset}/items/{contentKey}/versions/{contentVersion}',
|
|
114
|
+
...options,
|
|
115
|
+
headers: {
|
|
116
|
+
'Content-Type': 'application/json',
|
|
117
|
+
...options.headers
|
|
118
|
+
}
|
|
119
|
+
});
|
|
154
120
|
exports.changesetsUpdateItem = changesetsUpdateItem;
|
|
155
121
|
/**
|
|
156
122
|
* Create content
|
|
157
123
|
*
|
|
158
124
|
* Create a new content item.
|
|
159
125
|
*/
|
|
160
|
-
const contentCreate = (options) => {
|
|
161
|
-
|
|
162
|
-
|
|
163
|
-
|
|
164
|
-
|
|
165
|
-
|
|
166
|
-
|
|
167
|
-
|
|
168
|
-
|
|
169
|
-
});
|
|
170
|
-
};
|
|
126
|
+
const contentCreate = (options) => (options.client ?? client_gen_1.client).post({
|
|
127
|
+
responseTransformer: transformers_gen_1.contentCreateResponseTransformer,
|
|
128
|
+
url: '/content',
|
|
129
|
+
...options,
|
|
130
|
+
headers: {
|
|
131
|
+
'Content-Type': 'application/json',
|
|
132
|
+
...options.headers
|
|
133
|
+
}
|
|
134
|
+
});
|
|
171
135
|
exports.contentCreate = contentCreate;
|
|
172
136
|
/**
|
|
173
137
|
* Delete content
|
|
174
138
|
*
|
|
175
139
|
* Deletes the content item with the provided key. If a content item with the provided key does not exist an error is returned.
|
|
176
140
|
*/
|
|
177
|
-
const contentDelete = (options) => {
|
|
178
|
-
|
|
179
|
-
|
|
180
|
-
|
|
181
|
-
|
|
182
|
-
});
|
|
183
|
-
};
|
|
141
|
+
const contentDelete = (options) => (options.client ?? client_gen_1.client).delete({
|
|
142
|
+
responseTransformer: transformers_gen_1.contentDeleteResponseTransformer,
|
|
143
|
+
url: '/content/{key}',
|
|
144
|
+
...options
|
|
145
|
+
});
|
|
184
146
|
exports.contentDelete = contentDelete;
|
|
185
147
|
/**
|
|
186
148
|
* Get content
|
|
187
149
|
*
|
|
188
150
|
* Get shared metadata about the content instance with the provided key.
|
|
189
151
|
*/
|
|
190
|
-
const contentGetMetadata = (options) => {
|
|
191
|
-
|
|
192
|
-
|
|
193
|
-
|
|
194
|
-
|
|
195
|
-
});
|
|
196
|
-
};
|
|
152
|
+
const contentGetMetadata = (options) => (options.client ?? client_gen_1.client).get({
|
|
153
|
+
responseTransformer: transformers_gen_1.contentGetMetadataResponseTransformer,
|
|
154
|
+
url: '/content/{key}',
|
|
155
|
+
...options
|
|
156
|
+
});
|
|
197
157
|
exports.contentGetMetadata = contentGetMetadata;
|
|
198
158
|
/**
|
|
199
159
|
* Update content
|
|
200
160
|
*
|
|
201
161
|
* Update an existing content item. If a content item with the provided key does not exist an error is returned.
|
|
202
162
|
*/
|
|
203
|
-
const contentPatchMetadata = (options) => {
|
|
204
|
-
|
|
205
|
-
|
|
206
|
-
|
|
207
|
-
|
|
208
|
-
|
|
209
|
-
|
|
210
|
-
|
|
211
|
-
|
|
212
|
-
});
|
|
213
|
-
};
|
|
163
|
+
const contentPatchMetadata = (options) => (options.client ?? client_gen_1.client).patch({
|
|
164
|
+
responseTransformer: transformers_gen_1.contentPatchMetadataResponseTransformer,
|
|
165
|
+
url: '/content/{key}',
|
|
166
|
+
...options,
|
|
167
|
+
headers: {
|
|
168
|
+
'Content-Type': 'application/merge-patch+json',
|
|
169
|
+
...options.headers
|
|
170
|
+
}
|
|
171
|
+
});
|
|
214
172
|
exports.contentPatchMetadata = contentPatchMetadata;
|
|
215
173
|
/**
|
|
216
174
|
* Get content path
|
|
217
175
|
*
|
|
218
176
|
* Get the content path with the provided key.
|
|
219
177
|
*/
|
|
220
|
-
const contentGetPath = (options) => {
|
|
221
|
-
|
|
222
|
-
|
|
223
|
-
|
|
224
|
-
|
|
225
|
-
});
|
|
226
|
-
};
|
|
178
|
+
const contentGetPath = (options) => (options.client ?? client_gen_1.client).get({
|
|
179
|
+
responseTransformer: transformers_gen_1.contentGetPathResponseTransformer,
|
|
180
|
+
url: '/content/{key}/path',
|
|
181
|
+
...options
|
|
182
|
+
});
|
|
227
183
|
exports.contentGetPath = contentGetPath;
|
|
228
184
|
/**
|
|
229
185
|
* List content in container
|
|
230
186
|
*
|
|
231
187
|
* List the content items located in a specific container.
|
|
232
188
|
*/
|
|
233
|
-
const contentListItems = (options) => {
|
|
234
|
-
|
|
235
|
-
|
|
236
|
-
|
|
237
|
-
|
|
238
|
-
});
|
|
239
|
-
};
|
|
189
|
+
const contentListItems = (options) => (options.client ?? client_gen_1.client).get({
|
|
190
|
+
responseTransformer: transformers_gen_1.contentListItemsResponseTransformer,
|
|
191
|
+
url: '/content/{key}/items',
|
|
192
|
+
...options
|
|
193
|
+
});
|
|
240
194
|
exports.contentListItems = contentListItems;
|
|
241
195
|
/**
|
|
242
196
|
* List assets
|
|
243
197
|
*
|
|
244
198
|
* List the assets that belongs to a content instance.
|
|
245
199
|
*/
|
|
246
|
-
const contentListAssets = (options) => {
|
|
247
|
-
|
|
248
|
-
|
|
249
|
-
|
|
250
|
-
|
|
251
|
-
});
|
|
252
|
-
};
|
|
200
|
+
const contentListAssets = (options) => (options.client ?? client_gen_1.client).get({
|
|
201
|
+
responseTransformer: transformers_gen_1.contentListAssetsResponseTransformer,
|
|
202
|
+
url: '/content/{key}/assets',
|
|
203
|
+
...options
|
|
204
|
+
});
|
|
253
205
|
exports.contentListAssets = contentListAssets;
|
|
254
206
|
/**
|
|
255
207
|
* Copy content
|
|
256
208
|
*
|
|
257
209
|
* Create a copy of the content item with the provided key.
|
|
258
210
|
*/
|
|
259
|
-
const contentCopy = (options) => {
|
|
260
|
-
|
|
261
|
-
|
|
262
|
-
|
|
263
|
-
|
|
264
|
-
|
|
265
|
-
|
|
266
|
-
|
|
267
|
-
|
|
268
|
-
});
|
|
269
|
-
};
|
|
211
|
+
const contentCopy = (options) => (options.client ?? client_gen_1.client).post({
|
|
212
|
+
responseTransformer: transformers_gen_1.contentCopyResponseTransformer,
|
|
213
|
+
url: '/content/{key}:copy',
|
|
214
|
+
...options,
|
|
215
|
+
headers: {
|
|
216
|
+
'Content-Type': 'application/json',
|
|
217
|
+
...options.headers
|
|
218
|
+
}
|
|
219
|
+
});
|
|
270
220
|
exports.contentCopy = contentCopy;
|
|
271
221
|
/**
|
|
272
222
|
* Restore content
|
|
273
223
|
*
|
|
274
224
|
* Restore the deleted content item with the provided key. If a content item with the provided key is not deleted an error is returned.
|
|
275
225
|
*/
|
|
276
|
-
const contentUndelete = (options) => {
|
|
277
|
-
|
|
278
|
-
|
|
279
|
-
|
|
280
|
-
|
|
281
|
-
});
|
|
282
|
-
};
|
|
226
|
+
const contentUndelete = (options) => (options.client ?? client_gen_1.client).post({
|
|
227
|
+
responseTransformer: transformers_gen_1.contentUndeleteResponseTransformer,
|
|
228
|
+
url: '/content/{key}:undelete',
|
|
229
|
+
...options
|
|
230
|
+
});
|
|
283
231
|
exports.contentUndelete = contentUndelete;
|
|
284
232
|
/**
|
|
285
233
|
* Query versions
|
|
286
234
|
*
|
|
287
235
|
* List content versions based on the provided query options.
|
|
288
236
|
*/
|
|
289
|
-
const contentListAllVersions = (options) => {
|
|
290
|
-
|
|
291
|
-
|
|
292
|
-
|
|
293
|
-
|
|
294
|
-
});
|
|
295
|
-
};
|
|
237
|
+
const contentListAllVersions = (options) => (options?.client ?? client_gen_1.client).get({
|
|
238
|
+
responseTransformer: transformers_gen_1.contentListAllVersionsResponseTransformer,
|
|
239
|
+
url: '/content/versions',
|
|
240
|
+
...options
|
|
241
|
+
});
|
|
296
242
|
exports.contentListAllVersions = contentListAllVersions;
|
|
297
243
|
/**
|
|
298
244
|
* Delete locale
|
|
299
245
|
*
|
|
300
246
|
* Deletes the content item with the provided key. If a content item with the provided key does not exist an error is returned.
|
|
301
247
|
*/
|
|
302
|
-
const contentDeleteLocale = (options) => {
|
|
303
|
-
|
|
304
|
-
|
|
305
|
-
|
|
306
|
-
|
|
307
|
-
});
|
|
308
|
-
};
|
|
248
|
+
const contentDeleteLocale = (options) => (options.client ?? client_gen_1.client).delete({
|
|
249
|
+
responseTransformer: transformers_gen_1.contentDeleteLocaleResponseTransformer,
|
|
250
|
+
url: '/content/{key}/versions',
|
|
251
|
+
...options
|
|
252
|
+
});
|
|
309
253
|
exports.contentDeleteLocale = contentDeleteLocale;
|
|
310
254
|
/**
|
|
311
255
|
* List versions
|
|
312
256
|
*
|
|
313
257
|
* List versions of the content item with the provided key and the provided options.
|
|
314
258
|
*/
|
|
315
|
-
const contentListVersions = (options) => {
|
|
316
|
-
|
|
317
|
-
|
|
318
|
-
|
|
319
|
-
|
|
320
|
-
});
|
|
321
|
-
};
|
|
259
|
+
const contentListVersions = (options) => (options.client ?? client_gen_1.client).get({
|
|
260
|
+
responseTransformer: transformers_gen_1.contentListVersionsResponseTransformer,
|
|
261
|
+
url: '/content/{key}/versions',
|
|
262
|
+
...options
|
|
263
|
+
});
|
|
322
264
|
exports.contentListVersions = contentListVersions;
|
|
323
265
|
/**
|
|
324
266
|
* Create version
|
|
325
267
|
*
|
|
326
268
|
* Create a new version of a content item.
|
|
327
269
|
*/
|
|
328
|
-
const contentCreateVersion = (options) => {
|
|
329
|
-
|
|
330
|
-
|
|
331
|
-
|
|
332
|
-
|
|
333
|
-
|
|
334
|
-
|
|
335
|
-
|
|
336
|
-
|
|
337
|
-
});
|
|
338
|
-
};
|
|
270
|
+
const contentCreateVersion = (options) => (options.client ?? client_gen_1.client).post({
|
|
271
|
+
responseTransformer: transformers_gen_1.contentCreateVersionResponseTransformer,
|
|
272
|
+
url: '/content/{key}/versions',
|
|
273
|
+
...options,
|
|
274
|
+
headers: {
|
|
275
|
+
'Content-Type': 'application/json',
|
|
276
|
+
...options.headers
|
|
277
|
+
}
|
|
278
|
+
});
|
|
339
279
|
exports.contentCreateVersion = contentCreateVersion;
|
|
340
280
|
/**
|
|
341
281
|
* Delete version
|
|
342
282
|
*
|
|
343
283
|
* Deletes the content item with the provided key. If a content item with the provided key does not exist an error is returned.
|
|
344
284
|
*/
|
|
345
|
-
const contentDeleteVersion = (options) => {
|
|
346
|
-
|
|
347
|
-
|
|
348
|
-
|
|
349
|
-
|
|
350
|
-
});
|
|
351
|
-
};
|
|
285
|
+
const contentDeleteVersion = (options) => (options.client ?? client_gen_1.client).delete({
|
|
286
|
+
responseTransformer: transformers_gen_1.contentDeleteVersionResponseTransformer,
|
|
287
|
+
url: '/content/{key}/versions/{version}',
|
|
288
|
+
...options
|
|
289
|
+
});
|
|
352
290
|
exports.contentDeleteVersion = contentDeleteVersion;
|
|
353
291
|
/**
|
|
354
292
|
* Get version
|
|
355
293
|
*
|
|
356
294
|
* Get the content item with the provided key and version.
|
|
357
295
|
*/
|
|
358
|
-
const contentGetVersion = (options) => {
|
|
359
|
-
|
|
360
|
-
|
|
361
|
-
|
|
362
|
-
|
|
363
|
-
});
|
|
364
|
-
};
|
|
296
|
+
const contentGetVersion = (options) => (options.client ?? client_gen_1.client).get({
|
|
297
|
+
responseTransformer: transformers_gen_1.contentGetVersionResponseTransformer,
|
|
298
|
+
url: '/content/{key}/versions/{version}',
|
|
299
|
+
...options
|
|
300
|
+
});
|
|
365
301
|
exports.contentGetVersion = contentGetVersion;
|
|
366
302
|
/**
|
|
367
303
|
* Update version
|
|
368
304
|
*
|
|
369
305
|
* Update an existing content item. If a content item with the provided key does not exist an error is returned.
|
|
370
306
|
*/
|
|
371
|
-
const contentPatchVersion = (options) => {
|
|
372
|
-
|
|
373
|
-
|
|
374
|
-
|
|
375
|
-
|
|
376
|
-
|
|
377
|
-
|
|
378
|
-
|
|
379
|
-
|
|
380
|
-
});
|
|
381
|
-
};
|
|
307
|
+
const contentPatchVersion = (options) => (options.client ?? client_gen_1.client).patch({
|
|
308
|
+
responseTransformer: transformers_gen_1.contentPatchVersionResponseTransformer,
|
|
309
|
+
url: '/content/{key}/versions/{version}',
|
|
310
|
+
...options,
|
|
311
|
+
headers: {
|
|
312
|
+
'Content-Type': 'application/merge-patch+json',
|
|
313
|
+
...options.headers
|
|
314
|
+
}
|
|
315
|
+
});
|
|
382
316
|
exports.contentPatchVersion = contentPatchVersion;
|
|
383
317
|
/**
|
|
384
318
|
* List content types
|
|
385
319
|
*
|
|
386
320
|
* List content types using the provided options.
|
|
387
321
|
*/
|
|
388
|
-
const contentTypesList = (options) => {
|
|
389
|
-
|
|
390
|
-
|
|
391
|
-
|
|
392
|
-
|
|
393
|
-
});
|
|
394
|
-
};
|
|
322
|
+
const contentTypesList = (options) => (options?.client ?? client_gen_1.client).get({
|
|
323
|
+
responseTransformer: transformers_gen_1.contentTypesListResponseTransformer,
|
|
324
|
+
url: '/contenttypes',
|
|
325
|
+
...options
|
|
326
|
+
});
|
|
395
327
|
exports.contentTypesList = contentTypesList;
|
|
396
328
|
/**
|
|
397
329
|
* Create content type
|
|
398
330
|
*
|
|
399
331
|
* Create a new content type.
|
|
400
332
|
*/
|
|
401
|
-
const contentTypesCreate = (options) => {
|
|
402
|
-
|
|
403
|
-
|
|
404
|
-
|
|
405
|
-
|
|
406
|
-
|
|
407
|
-
|
|
408
|
-
|
|
409
|
-
|
|
410
|
-
});
|
|
411
|
-
};
|
|
333
|
+
const contentTypesCreate = (options) => (options.client ?? client_gen_1.client).post({
|
|
334
|
+
responseTransformer: transformers_gen_1.contentTypesCreateResponseTransformer,
|
|
335
|
+
url: '/contenttypes',
|
|
336
|
+
...options,
|
|
337
|
+
headers: {
|
|
338
|
+
'Content-Type': 'application/json',
|
|
339
|
+
...options.headers
|
|
340
|
+
}
|
|
341
|
+
});
|
|
412
342
|
exports.contentTypesCreate = contentTypesCreate;
|
|
413
343
|
/**
|
|
414
344
|
* Delete content type
|
|
415
345
|
*
|
|
416
346
|
* Deletes the content type with the provided key. If a content type with the provided key does not exist an error is returned.
|
|
417
347
|
*/
|
|
418
|
-
const contentTypesDelete = (options) => {
|
|
419
|
-
|
|
420
|
-
|
|
421
|
-
|
|
422
|
-
|
|
423
|
-
});
|
|
424
|
-
};
|
|
348
|
+
const contentTypesDelete = (options) => (options.client ?? client_gen_1.client).delete({
|
|
349
|
+
responseTransformer: transformers_gen_1.contentTypesDeleteResponseTransformer,
|
|
350
|
+
url: '/contenttypes/{key}',
|
|
351
|
+
...options
|
|
352
|
+
});
|
|
425
353
|
exports.contentTypesDelete = contentTypesDelete;
|
|
426
354
|
/**
|
|
427
355
|
* Get content type
|
|
428
356
|
*
|
|
429
357
|
* Get the content type with the provided key.
|
|
430
358
|
*/
|
|
431
|
-
const contentTypesGet = (options) => {
|
|
432
|
-
|
|
433
|
-
|
|
434
|
-
|
|
435
|
-
|
|
436
|
-
});
|
|
437
|
-
};
|
|
359
|
+
const contentTypesGet = (options) => (options.client ?? client_gen_1.client).get({
|
|
360
|
+
responseTransformer: transformers_gen_1.contentTypesGetResponseTransformer,
|
|
361
|
+
url: '/contenttypes/{key}',
|
|
362
|
+
...options
|
|
363
|
+
});
|
|
438
364
|
exports.contentTypesGet = contentTypesGet;
|
|
439
365
|
/**
|
|
440
366
|
* Update content type
|
|
441
367
|
*
|
|
442
368
|
* Update an existing content type. If a content type with the provided key does not exist an error is returned.
|
|
443
369
|
*/
|
|
444
|
-
const contentTypesPatch = (options) => {
|
|
445
|
-
|
|
446
|
-
|
|
447
|
-
|
|
448
|
-
|
|
449
|
-
|
|
450
|
-
|
|
451
|
-
|
|
452
|
-
|
|
453
|
-
});
|
|
454
|
-
};
|
|
370
|
+
const contentTypesPatch = (options) => (options.client ?? client_gen_1.client).patch({
|
|
371
|
+
responseTransformer: transformers_gen_1.contentTypesPatchResponseTransformer,
|
|
372
|
+
url: '/contenttypes/{key}',
|
|
373
|
+
...options,
|
|
374
|
+
headers: {
|
|
375
|
+
'Content-Type': 'application/merge-patch+json',
|
|
376
|
+
...options.headers
|
|
377
|
+
}
|
|
378
|
+
});
|
|
455
379
|
exports.contentTypesPatch = contentTypesPatch;
|
|
456
380
|
/**
|
|
457
381
|
* Create or replace content type
|
|
@@ -459,90 +383,78 @@ exports.contentTypesPatch = contentTypesPatch;
|
|
|
459
383
|
* Create or replace a content type. If a content type with the provided key exist it is replaced.
|
|
460
384
|
* Otherwise a new content type is created.
|
|
461
385
|
*/
|
|
462
|
-
const contentTypesPut = (options) => {
|
|
463
|
-
|
|
464
|
-
|
|
465
|
-
|
|
466
|
-
|
|
467
|
-
|
|
468
|
-
|
|
469
|
-
|
|
470
|
-
|
|
471
|
-
});
|
|
472
|
-
};
|
|
386
|
+
const contentTypesPut = (options) => (options.client ?? client_gen_1.client).put({
|
|
387
|
+
responseTransformer: transformers_gen_1.contentTypesPutResponseTransformer,
|
|
388
|
+
url: '/contenttypes/{key}',
|
|
389
|
+
...options,
|
|
390
|
+
headers: {
|
|
391
|
+
'Content-Type': 'application/json',
|
|
392
|
+
...options.headers
|
|
393
|
+
}
|
|
394
|
+
});
|
|
473
395
|
exports.contentTypesPut = contentTypesPut;
|
|
474
396
|
/**
|
|
475
397
|
* List display templates
|
|
476
398
|
*
|
|
477
399
|
* List display templates using the provided options.
|
|
478
400
|
*/
|
|
479
|
-
const displayTemplatesList = (options) => {
|
|
480
|
-
|
|
481
|
-
|
|
482
|
-
|
|
483
|
-
|
|
484
|
-
});
|
|
485
|
-
};
|
|
401
|
+
const displayTemplatesList = (options) => (options?.client ?? client_gen_1.client).get({
|
|
402
|
+
responseTransformer: transformers_gen_1.displayTemplatesListResponseTransformer,
|
|
403
|
+
url: '/displaytemplates',
|
|
404
|
+
...options
|
|
405
|
+
});
|
|
486
406
|
exports.displayTemplatesList = displayTemplatesList;
|
|
487
407
|
/**
|
|
488
408
|
* Create display template
|
|
489
409
|
*
|
|
490
410
|
* Create a new display template.
|
|
491
411
|
*/
|
|
492
|
-
const displayTemplatesCreate = (options) => {
|
|
493
|
-
|
|
494
|
-
|
|
495
|
-
|
|
496
|
-
|
|
497
|
-
|
|
498
|
-
|
|
499
|
-
|
|
500
|
-
|
|
501
|
-
});
|
|
502
|
-
};
|
|
412
|
+
const displayTemplatesCreate = (options) => (options.client ?? client_gen_1.client).post({
|
|
413
|
+
responseTransformer: transformers_gen_1.displayTemplatesCreateResponseTransformer,
|
|
414
|
+
url: '/displaytemplates',
|
|
415
|
+
...options,
|
|
416
|
+
headers: {
|
|
417
|
+
'Content-Type': 'application/json',
|
|
418
|
+
...options.headers
|
|
419
|
+
}
|
|
420
|
+
});
|
|
503
421
|
exports.displayTemplatesCreate = displayTemplatesCreate;
|
|
504
422
|
/**
|
|
505
423
|
* Delete display template
|
|
506
424
|
*
|
|
507
425
|
* Deletes the display template with the provided key.
|
|
508
426
|
*/
|
|
509
|
-
const displayTemplatesDelete = (options) => {
|
|
510
|
-
|
|
511
|
-
|
|
512
|
-
|
|
513
|
-
|
|
514
|
-
});
|
|
515
|
-
};
|
|
427
|
+
const displayTemplatesDelete = (options) => (options.client ?? client_gen_1.client).delete({
|
|
428
|
+
responseTransformer: transformers_gen_1.displayTemplatesDeleteResponseTransformer,
|
|
429
|
+
url: '/displaytemplates/{key}',
|
|
430
|
+
...options
|
|
431
|
+
});
|
|
516
432
|
exports.displayTemplatesDelete = displayTemplatesDelete;
|
|
517
433
|
/**
|
|
518
434
|
* Get display template
|
|
519
435
|
*
|
|
520
436
|
* Get the display template with the provided key.
|
|
521
437
|
*/
|
|
522
|
-
const displayTemplatesGet = (options) => {
|
|
523
|
-
|
|
524
|
-
|
|
525
|
-
|
|
526
|
-
|
|
527
|
-
});
|
|
528
|
-
};
|
|
438
|
+
const displayTemplatesGet = (options) => (options.client ?? client_gen_1.client).get({
|
|
439
|
+
responseTransformer: transformers_gen_1.displayTemplatesGetResponseTransformer,
|
|
440
|
+
url: '/displaytemplates/{key}',
|
|
441
|
+
...options
|
|
442
|
+
});
|
|
529
443
|
exports.displayTemplatesGet = displayTemplatesGet;
|
|
530
444
|
/**
|
|
531
445
|
* Update display template
|
|
532
446
|
*
|
|
533
447
|
* Update an existing display template.
|
|
534
448
|
*/
|
|
535
|
-
const displayTemplatesPatch = (options) => {
|
|
536
|
-
|
|
537
|
-
|
|
538
|
-
|
|
539
|
-
|
|
540
|
-
|
|
541
|
-
|
|
542
|
-
|
|
543
|
-
|
|
544
|
-
});
|
|
545
|
-
};
|
|
449
|
+
const displayTemplatesPatch = (options) => (options.client ?? client_gen_1.client).patch({
|
|
450
|
+
responseTransformer: transformers_gen_1.displayTemplatesPatchResponseTransformer,
|
|
451
|
+
url: '/displaytemplates/{key}',
|
|
452
|
+
...options,
|
|
453
|
+
headers: {
|
|
454
|
+
'Content-Type': 'application/merge-patch+json',
|
|
455
|
+
...options.headers
|
|
456
|
+
}
|
|
457
|
+
});
|
|
546
458
|
exports.displayTemplatesPatch = displayTemplatesPatch;
|
|
547
459
|
/**
|
|
548
460
|
* Create or replace a display template
|
|
@@ -550,17 +462,15 @@ exports.displayTemplatesPatch = displayTemplatesPatch;
|
|
|
550
462
|
* Create or replace a display template. If a display template with the provided key exist it is replaced.
|
|
551
463
|
* Otherwise a new display template is created.
|
|
552
464
|
*/
|
|
553
|
-
const displayTemplatesPut = (options) => {
|
|
554
|
-
|
|
555
|
-
|
|
556
|
-
|
|
557
|
-
|
|
558
|
-
|
|
559
|
-
|
|
560
|
-
|
|
561
|
-
|
|
562
|
-
});
|
|
563
|
-
};
|
|
465
|
+
const displayTemplatesPut = (options) => (options.client ?? client_gen_1.client).put({
|
|
466
|
+
responseTransformer: transformers_gen_1.displayTemplatesPutResponseTransformer,
|
|
467
|
+
url: '/displaytemplates/{key}',
|
|
468
|
+
...options,
|
|
469
|
+
headers: {
|
|
470
|
+
'Content-Type': 'application/json',
|
|
471
|
+
...options.headers
|
|
472
|
+
}
|
|
473
|
+
});
|
|
564
474
|
exports.displayTemplatesPut = displayTemplatesPut;
|
|
565
475
|
/**
|
|
566
476
|
* Request access token
|
|
@@ -568,116 +478,77 @@ exports.displayTemplatesPut = displayTemplatesPut;
|
|
|
568
478
|
* Request an access token. This endpoint only supports the 'client_credentials' grant type
|
|
569
479
|
* and will only issue short-lived tokens.
|
|
570
480
|
*/
|
|
571
|
-
const oauthToken = (options) => {
|
|
572
|
-
|
|
573
|
-
|
|
574
|
-
|
|
575
|
-
|
|
576
|
-
headers
|
|
577
|
-
|
|
578
|
-
|
|
579
|
-
}
|
|
580
|
-
});
|
|
581
|
-
};
|
|
481
|
+
const oauthToken = (options) => (options.client ?? client_gen_1.client).post({
|
|
482
|
+
url: '/oauth/token',
|
|
483
|
+
...options,
|
|
484
|
+
headers: {
|
|
485
|
+
'Content-Type': 'application/json',
|
|
486
|
+
...options.headers
|
|
487
|
+
}
|
|
488
|
+
});
|
|
582
489
|
exports.oauthToken = oauthToken;
|
|
583
490
|
/**
|
|
584
491
|
* List property formats
|
|
585
492
|
*
|
|
586
493
|
* List all property formats using the provided options.
|
|
587
494
|
*/
|
|
588
|
-
const propertyFormatsList = (options) => {
|
|
589
|
-
return (options?.client ?? client_gen_1.client).get({
|
|
590
|
-
responseTransformer: transformers_gen_1.propertyFormatsListResponseTransformer,
|
|
591
|
-
url: '/propertyformats',
|
|
592
|
-
...options
|
|
593
|
-
});
|
|
594
|
-
};
|
|
495
|
+
const propertyFormatsList = (options) => (options?.client ?? client_gen_1.client).get({ url: '/propertyformats', ...options });
|
|
595
496
|
exports.propertyFormatsList = propertyFormatsList;
|
|
596
497
|
/**
|
|
597
498
|
* Get property format
|
|
598
499
|
*
|
|
599
500
|
* Get the property format with the provided key.
|
|
600
501
|
*/
|
|
601
|
-
const propertyFormatsGet = (options) => {
|
|
602
|
-
return (options.client ?? client_gen_1.client).get({
|
|
603
|
-
responseTransformer: transformers_gen_1.propertyFormatsGetResponseTransformer,
|
|
604
|
-
url: '/propertyformats/{key}',
|
|
605
|
-
...options
|
|
606
|
-
});
|
|
607
|
-
};
|
|
502
|
+
const propertyFormatsGet = (options) => (options.client ?? client_gen_1.client).get({ url: '/propertyformats/{key}', ...options });
|
|
608
503
|
exports.propertyFormatsGet = propertyFormatsGet;
|
|
609
504
|
/**
|
|
610
505
|
* List property groups
|
|
611
506
|
*
|
|
612
507
|
* List property groups using the provided options.
|
|
613
508
|
*/
|
|
614
|
-
const propertyGroupsList = (options) => {
|
|
615
|
-
return (options?.client ?? client_gen_1.client).get({
|
|
616
|
-
responseTransformer: transformers_gen_1.propertyGroupsListResponseTransformer,
|
|
617
|
-
url: '/propertygroups',
|
|
618
|
-
...options
|
|
619
|
-
});
|
|
620
|
-
};
|
|
509
|
+
const propertyGroupsList = (options) => (options?.client ?? client_gen_1.client).get({ url: '/propertygroups', ...options });
|
|
621
510
|
exports.propertyGroupsList = propertyGroupsList;
|
|
622
511
|
/**
|
|
623
512
|
* Create property group
|
|
624
513
|
*
|
|
625
514
|
* Create a new property group.
|
|
626
515
|
*/
|
|
627
|
-
const propertyGroupsCreate = (options) => {
|
|
628
|
-
|
|
629
|
-
|
|
630
|
-
|
|
631
|
-
|
|
632
|
-
headers
|
|
633
|
-
|
|
634
|
-
|
|
635
|
-
}
|
|
636
|
-
});
|
|
637
|
-
};
|
|
516
|
+
const propertyGroupsCreate = (options) => (options.client ?? client_gen_1.client).post({
|
|
517
|
+
url: '/propertygroups',
|
|
518
|
+
...options,
|
|
519
|
+
headers: {
|
|
520
|
+
'Content-Type': 'application/json',
|
|
521
|
+
...options.headers
|
|
522
|
+
}
|
|
523
|
+
});
|
|
638
524
|
exports.propertyGroupsCreate = propertyGroupsCreate;
|
|
639
525
|
/**
|
|
640
526
|
* Delete property group
|
|
641
527
|
*
|
|
642
528
|
* Deletes the property group with the provided key.
|
|
643
529
|
*/
|
|
644
|
-
const propertyGroupsDelete = (options) => {
|
|
645
|
-
return (options.client ?? client_gen_1.client).delete({
|
|
646
|
-
responseTransformer: transformers_gen_1.propertyGroupsDeleteResponseTransformer,
|
|
647
|
-
url: '/propertygroups/{key}',
|
|
648
|
-
...options
|
|
649
|
-
});
|
|
650
|
-
};
|
|
530
|
+
const propertyGroupsDelete = (options) => (options.client ?? client_gen_1.client).delete({ url: '/propertygroups/{key}', ...options });
|
|
651
531
|
exports.propertyGroupsDelete = propertyGroupsDelete;
|
|
652
532
|
/**
|
|
653
533
|
* Get property group
|
|
654
534
|
*
|
|
655
535
|
* Get the property group with the provided key.
|
|
656
536
|
*/
|
|
657
|
-
const propertyGroupsGet = (options) => {
|
|
658
|
-
return (options.client ?? client_gen_1.client).get({
|
|
659
|
-
responseTransformer: transformers_gen_1.propertyGroupsGetResponseTransformer,
|
|
660
|
-
url: '/propertygroups/{key}',
|
|
661
|
-
...options
|
|
662
|
-
});
|
|
663
|
-
};
|
|
537
|
+
const propertyGroupsGet = (options) => (options.client ?? client_gen_1.client).get({ url: '/propertygroups/{key}', ...options });
|
|
664
538
|
exports.propertyGroupsGet = propertyGroupsGet;
|
|
665
539
|
/**
|
|
666
540
|
* Update property group
|
|
667
541
|
*
|
|
668
542
|
* Update an existing property group.
|
|
669
543
|
*/
|
|
670
|
-
const propertyGroupsPatch = (options) => {
|
|
671
|
-
|
|
672
|
-
|
|
673
|
-
|
|
674
|
-
|
|
675
|
-
headers
|
|
676
|
-
|
|
677
|
-
|
|
678
|
-
}
|
|
679
|
-
});
|
|
680
|
-
};
|
|
544
|
+
const propertyGroupsPatch = (options) => (options.client ?? client_gen_1.client).patch({
|
|
545
|
+
url: '/propertygroups/{key}',
|
|
546
|
+
...options,
|
|
547
|
+
headers: {
|
|
548
|
+
'Content-Type': 'application/merge-patch+json',
|
|
549
|
+
...options.headers
|
|
550
|
+
}
|
|
551
|
+
});
|
|
681
552
|
exports.propertyGroupsPatch = propertyGroupsPatch;
|
|
682
553
|
/**
|
|
683
554
|
* Create or replace property group
|
|
@@ -685,15 +556,12 @@ exports.propertyGroupsPatch = propertyGroupsPatch;
|
|
|
685
556
|
* Create or replace a property group. If a property group with the provided key exist it is replaced.
|
|
686
557
|
* Otherwise a new property group is created.
|
|
687
558
|
*/
|
|
688
|
-
const propertyGroupsPut = (options) => {
|
|
689
|
-
|
|
690
|
-
|
|
691
|
-
|
|
692
|
-
|
|
693
|
-
headers
|
|
694
|
-
|
|
695
|
-
|
|
696
|
-
}
|
|
697
|
-
});
|
|
698
|
-
};
|
|
559
|
+
const propertyGroupsPut = (options) => (options.client ?? client_gen_1.client).put({
|
|
560
|
+
url: '/propertygroups/{key}',
|
|
561
|
+
...options,
|
|
562
|
+
headers: {
|
|
563
|
+
'Content-Type': 'application/json',
|
|
564
|
+
...options.headers
|
|
565
|
+
}
|
|
566
|
+
});
|
|
699
567
|
exports.propertyGroupsPut = propertyGroupsPut;
|