@datocms/cma-client 6.4.0 → 6.8.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/cjs/generated/Client.js +1 -1
- package/dist/cjs/generated/resources/Field.js +16 -12
- package/dist/cjs/generated/resources/Field.js.map +1 -1
- package/dist/cjs/generated/resources/Fieldset.js +8 -6
- package/dist/cjs/generated/resources/Fieldset.js.map +1 -1
- package/dist/cjs/generated/resources/Item.js +4 -4
- package/dist/cjs/generated/resources/ItemType.js +12 -9
- package/dist/cjs/generated/resources/ItemType.js.map +1 -1
- package/dist/esm/generated/ApiTypes.d.ts +205 -3
- package/dist/esm/generated/Client.js +1 -1
- package/dist/esm/generated/RawApiTypes.d.ts +208 -2
- package/dist/esm/generated/resources/Field.d.ts +8 -8
- package/dist/esm/generated/resources/Field.js +16 -12
- package/dist/esm/generated/resources/Field.js.map +1 -1
- package/dist/esm/generated/resources/Fieldset.d.ts +4 -4
- package/dist/esm/generated/resources/Fieldset.js +8 -6
- package/dist/esm/generated/resources/Fieldset.js.map +1 -1
- package/dist/esm/generated/resources/Item.d.ts +4 -4
- package/dist/esm/generated/resources/Item.js +4 -4
- package/dist/esm/generated/resources/ItemType.d.ts +6 -6
- package/dist/esm/generated/resources/ItemType.js +12 -9
- package/dist/esm/generated/resources/ItemType.js.map +1 -1
- package/dist/types/generated/ApiTypes.d.ts +205 -3
- package/dist/types/generated/RawApiTypes.d.ts +208 -2
- package/dist/types/generated/resources/Field.d.ts +8 -8
- package/dist/types/generated/resources/Fieldset.d.ts +4 -4
- package/dist/types/generated/resources/Item.d.ts +4 -4
- package/dist/types/generated/resources/ItemType.d.ts +6 -6
- package/package.json +1 -1
- package/resources.json +11 -2
- package/src/generated/ApiTypes.ts +205 -3
- package/src/generated/Client.ts +1 -1
- package/src/generated/RawApiTypes.ts +208 -2
- package/src/generated/resources/Field.ts +38 -13
- package/src/generated/resources/Fieldset.ts +17 -5
- package/src/generated/resources/Item.ts +4 -4
- package/src/generated/resources/ItemType.ts +27 -11
|
@@ -90,7 +90,7 @@ class Client {
|
|
|
90
90
|
return this.config.baseUrl || Client.defaultBaseUrl;
|
|
91
91
|
}
|
|
92
92
|
request(options) {
|
|
93
|
-
return (0, rest_client_utils_1.request)(Object.assign(Object.assign(Object.assign({}, this.config), options), { logFn: this.config.logFn || console.log, userAgent: '@datocms/cma-client v6.
|
|
93
|
+
return (0, rest_client_utils_1.request)(Object.assign(Object.assign(Object.assign({}, this.config), options), { logFn: this.config.logFn || console.log, userAgent: '@datocms/cma-client v6.8.0', baseUrl: this.baseUrl, preCallStack: new Error().stack, extraHeaders: Object.assign(Object.assign(Object.assign({}, (this.config.extraHeaders || {})), (this.config.environment
|
|
94
94
|
? { 'X-Environment': this.config.environment }
|
|
95
95
|
: {})), { 'X-API-Version': '3' }), fetchJobResult: (jobId) => {
|
|
96
96
|
return this.jobResultsFetcher
|
|
@@ -124,8 +124,8 @@ class Field extends BaseResource_js_1.default {
|
|
|
124
124
|
* @throws {ApiError}
|
|
125
125
|
* @throws {TimeoutError}
|
|
126
126
|
*/
|
|
127
|
-
list(itemTypeId) {
|
|
128
|
-
return this.rawList(Utils.toId(itemTypeId)).then((body) => Utils.deserializeResponseBody(body));
|
|
127
|
+
list(itemTypeId, queryParams) {
|
|
128
|
+
return this.rawList(Utils.toId(itemTypeId), queryParams).then((body) => Utils.deserializeResponseBody(body));
|
|
129
129
|
}
|
|
130
130
|
/**
|
|
131
131
|
* List all fields of a model/block
|
|
@@ -135,10 +135,11 @@ class Field extends BaseResource_js_1.default {
|
|
|
135
135
|
* @throws {ApiError}
|
|
136
136
|
* @throws {TimeoutError}
|
|
137
137
|
*/
|
|
138
|
-
rawList(itemTypeId) {
|
|
138
|
+
rawList(itemTypeId, queryParams) {
|
|
139
139
|
return this.client.request({
|
|
140
140
|
method: 'GET',
|
|
141
141
|
url: `/item-types/${itemTypeId}/fields`,
|
|
142
|
+
queryParams,
|
|
142
143
|
});
|
|
143
144
|
}
|
|
144
145
|
/**
|
|
@@ -149,8 +150,8 @@ class Field extends BaseResource_js_1.default {
|
|
|
149
150
|
* @throws {ApiError}
|
|
150
151
|
* @throws {TimeoutError}
|
|
151
152
|
*/
|
|
152
|
-
referencing(itemTypeId) {
|
|
153
|
-
return this.rawReferencing(Utils.toId(itemTypeId)).then((body) => Utils.deserializeResponseBody(body));
|
|
153
|
+
referencing(itemTypeId, queryParams) {
|
|
154
|
+
return this.rawReferencing(Utils.toId(itemTypeId), queryParams).then((body) => Utils.deserializeResponseBody(body));
|
|
154
155
|
}
|
|
155
156
|
/**
|
|
156
157
|
* List fields referencing a model/block
|
|
@@ -160,10 +161,11 @@ class Field extends BaseResource_js_1.default {
|
|
|
160
161
|
* @throws {ApiError}
|
|
161
162
|
* @throws {TimeoutError}
|
|
162
163
|
*/
|
|
163
|
-
rawReferencing(itemTypeId) {
|
|
164
|
+
rawReferencing(itemTypeId, queryParams) {
|
|
164
165
|
return this.client.request({
|
|
165
166
|
method: 'GET',
|
|
166
167
|
url: `/item-types/${itemTypeId}/fields/referencing`,
|
|
168
|
+
queryParams,
|
|
167
169
|
});
|
|
168
170
|
}
|
|
169
171
|
/**
|
|
@@ -176,8 +178,8 @@ class Field extends BaseResource_js_1.default {
|
|
|
176
178
|
*
|
|
177
179
|
* @deprecated This API call is to be considered private and might change without notice
|
|
178
180
|
*/
|
|
179
|
-
related(itemTypeId) {
|
|
180
|
-
return this.rawRelated(Utils.toId(itemTypeId)).then((body) => Utils.deserializeResponseBody(body));
|
|
181
|
+
related(itemTypeId, queryParams) {
|
|
182
|
+
return this.rawRelated(Utils.toId(itemTypeId), queryParams).then((body) => Utils.deserializeResponseBody(body));
|
|
181
183
|
}
|
|
182
184
|
/**
|
|
183
185
|
* List related fields
|
|
@@ -189,10 +191,11 @@ class Field extends BaseResource_js_1.default {
|
|
|
189
191
|
*
|
|
190
192
|
* @deprecated This API call is to be considered private and might change without notice
|
|
191
193
|
*/
|
|
192
|
-
rawRelated(itemTypeId) {
|
|
194
|
+
rawRelated(itemTypeId, queryParams) {
|
|
193
195
|
return this.client.request({
|
|
194
196
|
method: 'GET',
|
|
195
197
|
url: `/item-types/${itemTypeId}/fields/related`,
|
|
198
|
+
queryParams,
|
|
196
199
|
});
|
|
197
200
|
}
|
|
198
201
|
/**
|
|
@@ -203,8 +206,8 @@ class Field extends BaseResource_js_1.default {
|
|
|
203
206
|
* @throws {ApiError}
|
|
204
207
|
* @throws {TimeoutError}
|
|
205
208
|
*/
|
|
206
|
-
find(fieldId) {
|
|
207
|
-
return this.rawFind(Utils.toId(fieldId)).then((body) => Utils.deserializeResponseBody(body));
|
|
209
|
+
find(fieldId, queryParams) {
|
|
210
|
+
return this.rawFind(Utils.toId(fieldId), queryParams).then((body) => Utils.deserializeResponseBody(body));
|
|
208
211
|
}
|
|
209
212
|
/**
|
|
210
213
|
* Retrieve a field
|
|
@@ -214,10 +217,11 @@ class Field extends BaseResource_js_1.default {
|
|
|
214
217
|
* @throws {ApiError}
|
|
215
218
|
* @throws {TimeoutError}
|
|
216
219
|
*/
|
|
217
|
-
rawFind(fieldId) {
|
|
220
|
+
rawFind(fieldId, queryParams) {
|
|
218
221
|
return this.client.request({
|
|
219
222
|
method: 'GET',
|
|
220
223
|
url: `/fields/${fieldId}`,
|
|
224
|
+
queryParams,
|
|
221
225
|
});
|
|
222
226
|
}
|
|
223
227
|
/**
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"Field.js","sourceRoot":"","sources":["../../../../src/generated/resources/Field.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA,kEAAoD;AACpD,4EAAiD;AAIjD,MAAqB,KAAM,SAAQ,yBAAY;IAG7C;;;;;;;OAOG;IACH,MAAM,CACJ,UAA0C,EAC1C,IAAgC;QAEhC,OAAO,IAAI,CAAC,SAAS,CACnB,KAAK,CAAC,IAAI,CAAC,UAAU,CAAC,EACtB,KAAK,CAAC,oBAAoB,CAAgC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EnC,OAAO,IAAI,CAAC,MAAM,CAAC,OAAO,CAAmC;YAC3D,MAAM,EAAE,KAAK;YACb,GAAG,EAAE,WAAW,OAAO,EAAE;YACzB,IAAI;SACL,CAAC,CAAC;IACL,CAAC;IAED;;;;;;;OAOG;IACH,IAAI,
|
|
1
|
+
{"version":3,"file":"Field.js","sourceRoot":"","sources":["../../../../src/generated/resources/Field.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA,kEAAoD;AACpD,4EAAiD;AAIjD,MAAqB,KAAM,SAAQ,yBAAY;IAG7C;;;;;;;OAOG;IACH,MAAM,CACJ,UAA0C,EAC1C,IAAgC;QAEhC,OAAO,IAAI,CAAC,SAAS,CACnB,KAAK,CAAC,IAAI,CAAC,UAAU,CAAC,EACtB,KAAK,CAAC,oBAAoB,CAAgC,IAAI,EAAE;YAC9D,IAAI,EAAE,OAAO;YACb,UAAU,EAAE;gBACV,OAAO;gBACP,YAAY;gBACZ,SAAS;gBACT,WAAW;gBACX,YAAY;gBACZ,aAAa;gBACb,YAAY;gBACZ,UAAU;gBACV,MAAM;gBACN,eAAe;gBACf,wBAAwB;gBACxB,sBAAsB;aACvB;YACD,aAAa,EAAE,CAAC,UAAU,CAAC;SAC5B,CAAC,CACH,CAAC,IAAI,CAAC,CAAC,IAAI,EAAE,EAAE,CACd,KAAK,CAAC,uBAAuB,CAAgC,IAAI,CAAC,CACnE,CAAC;IACJ,CAAC;IAED;;;;;;;OAOG;IACH,SAAS,CACP,UAAkB,EAClB,IAAmC;QAEnC,OAAO,IAAI,CAAC,MAAM,CAAC,OAAO,CAAmC;YAC3D,MAAM,EAAE,MAAM;YACd,GAAG,EAAE,eAAe,UAAU,SAAS;YACvC,IAAI;SACL,CAAC,CAAC;IACL,CAAC;IAED;;;;;;;OAOG;IACH,MAAM,CACJ,OAAoC,EACpC,IAAgC;QAEhC,OAAO,IAAI,CAAC,SAAS,CACnB,KAAK,CAAC,IAAI,CAAC,OAAO,CAAC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AE,WAAW,OAAO,EAAE;YACzB,WAAW;SACZ,CAAC,CAAC;IACL,CAAC;IAED;;;;;;;OAOG;IACH,OAAO,CAAC,OAAoC;QAC1C,OAAO,IAAI,CAAC,UAAU,CAAC,KAAK,CAAC,IAAI,CAAC,OAAO,CAAC,CAAC,CAAC,IAAI,CAAC,CAAC,IAAI,EAAE,EAAE,CACxD,KAAK,CAAC,uBAAuB,CAAiC,IAAI,CAAC,CACpE,CAAC;IACJ,CAAC;IAED;;;;;;;OAOG;IACH,UAAU,CAAC,OAAe;QACxB,OAAO,IAAI,CAAC,MAAM,CAAC,OAAO,CAAoC;YAC5D,MAAM,EAAE,QAAQ;YAChB,GAAG,EAAE,WAAW,OAAO,EAAE;SAC1B,CAAC,CAAC;IACL,CAAC;IAED;;;;;;;OAOG;IACH,SAAS,CAAC,OAAoC;QAC5C,OAAO,IAAI,CAAC,YAAY,CAAC,KAAK,CAAC,IAAI,CAAC,OAAO,CAAC,CAAC,CAAC,IAAI,CAAC,CAAC,IAAI,EAAE,EAAE,CAC1D,KAAK,CAAC,uBAAuB,CAAmC,IAAI,CAAC,CACtE,CAAC;IACJ,CAAC;IAED;;;;;;;OAOG;IACH,YAAY,CAAC,OAAe;QAC1B,OAAO,IAAI,CAAC,MAAM,CAAC,OAAO,CAAsC;YAC9D,MAAM,EAAE,MAAM;YACd,GAAG,EAAE,WAAW,OAAO,YAAY;SACpC,CAAC,CAAC;IACL,CAAC;;AAnUH,wBAoUC;AAnUiB,UAAI,GAAG,OAAgB,CAAC"}
|
|
@@ -110,8 +110,8 @@ class Fieldset extends BaseResource_js_1.default {
|
|
|
110
110
|
* @throws {ApiError}
|
|
111
111
|
* @throws {TimeoutError}
|
|
112
112
|
*/
|
|
113
|
-
list(itemTypeId) {
|
|
114
|
-
return this.rawList(Utils.toId(itemTypeId)).then((body) => Utils.deserializeResponseBody(body));
|
|
113
|
+
list(itemTypeId, queryParams) {
|
|
114
|
+
return this.rawList(Utils.toId(itemTypeId), queryParams).then((body) => Utils.deserializeResponseBody(body));
|
|
115
115
|
}
|
|
116
116
|
/**
|
|
117
117
|
* List all fieldsets of a model/block
|
|
@@ -121,10 +121,11 @@ class Fieldset extends BaseResource_js_1.default {
|
|
|
121
121
|
* @throws {ApiError}
|
|
122
122
|
* @throws {TimeoutError}
|
|
123
123
|
*/
|
|
124
|
-
rawList(itemTypeId) {
|
|
124
|
+
rawList(itemTypeId, queryParams) {
|
|
125
125
|
return this.client.request({
|
|
126
126
|
method: 'GET',
|
|
127
127
|
url: `/item-types/${itemTypeId}/fieldsets`,
|
|
128
|
+
queryParams,
|
|
128
129
|
});
|
|
129
130
|
}
|
|
130
131
|
/**
|
|
@@ -135,8 +136,8 @@ class Fieldset extends BaseResource_js_1.default {
|
|
|
135
136
|
* @throws {ApiError}
|
|
136
137
|
* @throws {TimeoutError}
|
|
137
138
|
*/
|
|
138
|
-
find(fieldsetId) {
|
|
139
|
-
return this.rawFind(Utils.toId(fieldsetId)).then((body) => Utils.deserializeResponseBody(body));
|
|
139
|
+
find(fieldsetId, queryParams) {
|
|
140
|
+
return this.rawFind(Utils.toId(fieldsetId), queryParams).then((body) => Utils.deserializeResponseBody(body));
|
|
140
141
|
}
|
|
141
142
|
/**
|
|
142
143
|
* Retrieve a fieldset
|
|
@@ -146,10 +147,11 @@ class Fieldset extends BaseResource_js_1.default {
|
|
|
146
147
|
* @throws {ApiError}
|
|
147
148
|
* @throws {TimeoutError}
|
|
148
149
|
*/
|
|
149
|
-
rawFind(fieldsetId) {
|
|
150
|
+
rawFind(fieldsetId, queryParams) {
|
|
150
151
|
return this.client.request({
|
|
151
152
|
method: 'GET',
|
|
152
153
|
url: `/fieldsets/${fieldsetId}`,
|
|
154
|
+
queryParams,
|
|
153
155
|
});
|
|
154
156
|
}
|
|
155
157
|
/**
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"Fieldset.js","sourceRoot":"","sources":["../../../../src/generated/resources/Fieldset.ts"],"names":[],"mappings":";;;;;;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;;;;;OAOG;IACH,SAAS,CACP,UAAkB,EAClB,IAAsC;QAEtC,OAAO,IAAI,CAAC,MAAM,CAAC,OAAO,CAAyC;YACjE,MAAM,EAAE,KAAK;YACb,GAAG,EAAE,cAAc,UAAU,EAAE;YAC/B,IAAI;SACL,CAAC,CAAC;IACL,CAAC;IAED;;;;;;;OAOG;IACH,IAAI,
|
|
1
|
+
{"version":3,"file":"Fieldset.js","sourceRoot":"","sources":["../../../../src/generated/resources/Fieldset.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA,kEAAoD;AACpD,4EAAiD;AAIjD,MAAqB,QAAS,SAAQ,yBAAY;IAGhD;;;;;;;OAOG;IACH,MAAM,CACJ,UAA0C,EAC1C,IAAmC;QAEnC,OAAO,IAAI,CAAC,SAAS,CACnB,KAAK,CAAC,IAAI,CAAC,UAAU,CAAC,EACtB,KAAK,CAAC,oBAAoB,CAAmC,IAAI,EAAE;YACjE,IAAI,EAAE,UAAU;YAChB,UAAU,EAAE;gBACV,OAAO;gBACP,MAAM;gBACN,UAAU;gBACV,aAAa;gBACb,iBAAiB;aAClB;YACD,aAAa,EAAE,EAAE;SAClB,CAAC,CACH,CAAC,IAAI,CAAC,CAAC,IAAI,EAAE,EAAE,CACd,KAAK,CAAC,uBAAuB,CAAsC,IAAI,CAAC,CACzE,CAAC;IACJ,CAAC;IAED;;;;;;;OAOG;IACH,SAAS,CACP,UAAkB,EAClB,IAAsC;QAEtC,OAAO,IAAI,CAAC,MAAM,CAAC,OAAO,CAAyC;YACjE,MAAM,EAAE,MAAM;YACd,GAAG,EAAE,eAAe,UAAU,YAAY;YAC1C,IAAI;SACL,CAAC,CAAC;IACL,CAAC;IAED;;;;;;;OAOG;IACH,MAAM,CACJ,UAA0C,EAC1C,IAAmC;QAEnC,OAAO,IAAI,CAAC,SAAS,CACnB,KAAK,CAAC,IAAI,CAAC,UAAU,CAAC,EACtB,KAAK,CAAC,oBAAoB,CAAmC,IAAI,EAAE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,CAAC;IAED;;;;;;;OAOG;IACH,OAAO,CACL,UAAkB,EAClB,WAAgD;QAEhD,OAAO,IAAI,CAAC,MAAM,CAAC,OAAO,CAAuC;YAC/D,MAAM,EAAE,KAAK;YACb,GAAG,EAAE,cAAc,UAAU,EAAE;YAC/B,WAAW;SACZ,CAAC,CAAC;IACL,CAAC;IAED;;;;;;;OAOG;IACH,OAAO,CAAC,UAA0C;QAChD,OAAO,IAAI,CAAC,UAAU,CAAC,KAAK,CAAC,IAAI,CAAC,UAAU,CAAC,CAAC,CAAC,IAAI,CAAC,CAAC,IAAI,EAAE,EAAE,CAC3D,KAAK,CAAC,uBAAuB,CAAuC,IAAI,CAAC,CAC1E,CAAC;IACJ,CAAC;IAED;;;;;;;OAOG;IACH,UAAU,CACR,UAAkB;QAElB,OAAO,IAAI,CAAC,MAAM,CAAC,OAAO,CAA0C;YAClE,MAAM,EAAE,QAAQ;YAChB,GAAG,EAAE,cAAc,UAAU,EAAE;SAChC,CAAC,CAAC;IACL,CAAC;;AA7MH,2BA8MC;AA7MiB,aAAI,GAAG,UAAmB,CAAC"}
|
|
@@ -109,7 +109,7 @@ class Item extends BaseResource_js_1.default {
|
|
|
109
109
|
}, (page) => this.rawList(Object.assign(Object.assign({}, queryParams), { page })), iteratorOptions, true);
|
|
110
110
|
}
|
|
111
111
|
/**
|
|
112
|
-
*
|
|
112
|
+
* Validate an existing record
|
|
113
113
|
*
|
|
114
114
|
* Read more: https://www.datocms.com/docs/content-management-api/resources/item/validate_existing
|
|
115
115
|
*
|
|
@@ -127,7 +127,7 @@ class Item extends BaseResource_js_1.default {
|
|
|
127
127
|
}));
|
|
128
128
|
}
|
|
129
129
|
/**
|
|
130
|
-
*
|
|
130
|
+
* Validate an existing record
|
|
131
131
|
*
|
|
132
132
|
* Read more: https://www.datocms.com/docs/content-management-api/resources/item/validate_existing
|
|
133
133
|
*
|
|
@@ -144,7 +144,7 @@ class Item extends BaseResource_js_1.default {
|
|
|
144
144
|
});
|
|
145
145
|
}
|
|
146
146
|
/**
|
|
147
|
-
*
|
|
147
|
+
* Validate a new record
|
|
148
148
|
*
|
|
149
149
|
* Read more: https://www.datocms.com/docs/content-management-api/resources/item/validate_new
|
|
150
150
|
*
|
|
@@ -161,7 +161,7 @@ class Item extends BaseResource_js_1.default {
|
|
|
161
161
|
}));
|
|
162
162
|
}
|
|
163
163
|
/**
|
|
164
|
-
*
|
|
164
|
+
* Validate a new record
|
|
165
165
|
*
|
|
166
166
|
* Read more: https://www.datocms.com/docs/content-management-api/resources/item/validate_new
|
|
167
167
|
*
|
|
@@ -148,8 +148,8 @@ class ItemType extends BaseResource_js_1.default {
|
|
|
148
148
|
* @throws {ApiError}
|
|
149
149
|
* @throws {TimeoutError}
|
|
150
150
|
*/
|
|
151
|
-
list() {
|
|
152
|
-
return this.rawList().then((body) => Utils.deserializeResponseBody(body));
|
|
151
|
+
list(queryParams) {
|
|
152
|
+
return this.rawList(queryParams).then((body) => Utils.deserializeResponseBody(body));
|
|
153
153
|
}
|
|
154
154
|
/**
|
|
155
155
|
* List all models/block models
|
|
@@ -159,10 +159,11 @@ class ItemType extends BaseResource_js_1.default {
|
|
|
159
159
|
* @throws {ApiError}
|
|
160
160
|
* @throws {TimeoutError}
|
|
161
161
|
*/
|
|
162
|
-
rawList() {
|
|
162
|
+
rawList(queryParams) {
|
|
163
163
|
return this.client.request({
|
|
164
164
|
method: 'GET',
|
|
165
165
|
url: '/item-types',
|
|
166
|
+
queryParams,
|
|
166
167
|
});
|
|
167
168
|
}
|
|
168
169
|
/**
|
|
@@ -173,8 +174,8 @@ class ItemType extends BaseResource_js_1.default {
|
|
|
173
174
|
* @throws {ApiError}
|
|
174
175
|
* @throws {TimeoutError}
|
|
175
176
|
*/
|
|
176
|
-
find(itemTypeId) {
|
|
177
|
-
return this.rawFind(Utils.toId(itemTypeId)).then((body) => Utils.deserializeResponseBody(body));
|
|
177
|
+
find(itemTypeId, queryParams) {
|
|
178
|
+
return this.rawFind(Utils.toId(itemTypeId), queryParams).then((body) => Utils.deserializeResponseBody(body));
|
|
178
179
|
}
|
|
179
180
|
/**
|
|
180
181
|
* Retrieve a model/block model
|
|
@@ -184,10 +185,11 @@ class ItemType extends BaseResource_js_1.default {
|
|
|
184
185
|
* @throws {ApiError}
|
|
185
186
|
* @throws {TimeoutError}
|
|
186
187
|
*/
|
|
187
|
-
rawFind(itemTypeId) {
|
|
188
|
+
rawFind(itemTypeId, queryParams) {
|
|
188
189
|
return this.client.request({
|
|
189
190
|
method: 'GET',
|
|
190
191
|
url: `/item-types/${itemTypeId}`,
|
|
192
|
+
queryParams,
|
|
191
193
|
});
|
|
192
194
|
}
|
|
193
195
|
/**
|
|
@@ -249,8 +251,8 @@ class ItemType extends BaseResource_js_1.default {
|
|
|
249
251
|
* @throws {ApiError}
|
|
250
252
|
* @throws {TimeoutError}
|
|
251
253
|
*/
|
|
252
|
-
referencing(itemTypeId) {
|
|
253
|
-
return this.rawReferencing(Utils.toId(itemTypeId)).then((body) => Utils.deserializeResponseBody(body));
|
|
254
|
+
referencing(itemTypeId, queryParams) {
|
|
255
|
+
return this.rawReferencing(Utils.toId(itemTypeId), queryParams).then((body) => Utils.deserializeResponseBody(body));
|
|
254
256
|
}
|
|
255
257
|
/**
|
|
256
258
|
* List models referencing another model/block
|
|
@@ -260,10 +262,11 @@ class ItemType extends BaseResource_js_1.default {
|
|
|
260
262
|
* @throws {ApiError}
|
|
261
263
|
* @throws {TimeoutError}
|
|
262
264
|
*/
|
|
263
|
-
rawReferencing(itemTypeId) {
|
|
265
|
+
rawReferencing(itemTypeId, queryParams) {
|
|
264
266
|
return this.client.request({
|
|
265
267
|
method: 'GET',
|
|
266
268
|
url: `/item-types/${itemTypeId}/referencing`,
|
|
269
|
+
queryParams,
|
|
267
270
|
});
|
|
268
271
|
}
|
|
269
272
|
/**
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"ItemType.js","sourceRoot":"","sources":["../../../../src/generated/resources/ItemType.ts"],"names":[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ACV,MAAM;gBACN,SAAS;gBACT,wBAAwB;gBACxB,uBAAuB;gBACvB,WAAW;gBACX,sBAAsB;gBACtB,UAAU;gBACV,eAAe;gBACf,mBAAmB;gBACnB,qBAAqB;gBACrB,MAAM;gBACN,oBAAoB;gBACpB,eAAe;gBACf,oBAAoB;gBACpB,MAAM;gBACN,+BAA+B;aAChC;YACD,aAAa,EAAE;gBACb,gBAAgB;gBAChB,0BAA0B;gBAC1B,0BAA0B;gBAC1B,aAAa;gBACb,qBAAqB;gBACrB,eAAe;gBACf,UAAU;aACX;SACF,CAAC,CACH,CAAC,IAAI,CAAC,CAAC,IAAI,EAAE,EAAE,CACd,KAAK,CAAC,uBAAuB,CAAmC,IAAI,CAAC,CACtE,CAAC;IACJ,CAAC;IAED;;;;;;;OAOG;IACH,SAAS,CACP,UAAkB,EAClB,IAAsC;QAEtC,OAAO,IAAI,CAAC,MAAM,CAAC,OAAO,CAAsC;YAC9D,MAAM,EAAE,KAAK;YACb,GAAG,EAAE,eAAe,UAAU,EAAE;YAChC,IAAI;SACL,CAAC,CAAC;IACL,CAAC;IAED;;;;;;;OAOG;IACH,IAAI;
|
|
1
|
+
{"version":3,"file":"ItemType.js","sourceRoot":"","sources":["../../../../src/generated/resources/ItemType.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA,kEAAoD;AACpD,4EAAiD;AAIjD,MAAqB,QAAS,SAAQ,yBAAY;IAGhD;;;;;;;OAOG;IACH,MAAM,CACJ,IAAmC,EACnC,WAA+C;QAE/C,OAAO,IAAI,CAAC,SAAS,CACnB,KAAK,CAAC,oBAAoB,CAAmC,IAAI,EAAE;YACjE,IAAI,EAAE,WAAW;YACjB,UAAU,EAAE;gBACV,MAAM;gBACN,SAAS;gBACT,WAAW;gBACX,sBAAsB;gBACtB,UAAU;gBACV,eAAe;gBACf,mBAAmB;gBACnB,qBAAqB;gBACrB,MAAM;gBACN,oBAAoB;gBACpB,eAAe;gBACf,wBAAwB;gBAC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ClB,IAAyD;QAEzD,OAAO,IAAI,CAAC,MAAM,CAAC,OAAO,CACxB;YACE,MAAM,EAAE,MAAM;YACd,GAAG,EAAE,eAAe,UAAU,+BAA+B;YAC7D,IAAI;SACL,CACF,CAAC;IACJ,CAAC;;AAnVH,2BAoVC;AAnViB,aAAI,GAAG,WAAoB,CAAC"}
|
|
@@ -248,6 +248,13 @@ export type AccountIdentity = string;
|
|
|
248
248
|
* via the `definition` "type".
|
|
249
249
|
*/
|
|
250
250
|
export type AccountType = 'account';
|
|
251
|
+
/**
|
|
252
|
+
* Attributes and relationships to return for each `account` that this endpoint returns.
|
|
253
|
+
*
|
|
254
|
+
* This interface was referenced by `Account`'s JSON-Schema
|
|
255
|
+
* via the `definition` "sparse_fieldset".
|
|
256
|
+
*/
|
|
257
|
+
export type AccountSparseFieldset = string;
|
|
251
258
|
/**
|
|
252
259
|
* ID of organization
|
|
253
260
|
*
|
|
@@ -263,6 +270,13 @@ export type OrganizationIdentity = string;
|
|
|
263
270
|
* via the `definition` "type".
|
|
264
271
|
*/
|
|
265
272
|
export type OrganizationType = 'organization';
|
|
273
|
+
/**
|
|
274
|
+
* Attributes and relationships to return for each `organization` that this endpoint returns.
|
|
275
|
+
*
|
|
276
|
+
* This interface was referenced by `Organization`'s JSON-Schema
|
|
277
|
+
* via the `definition` "sparse_fieldset".
|
|
278
|
+
*/
|
|
279
|
+
export type OrganizationSparseFieldset = string;
|
|
266
280
|
/**
|
|
267
281
|
* This interface was referenced by `User`'s JSON-Schema
|
|
268
282
|
* via the `me.hrefSchema` link.
|
|
@@ -553,6 +567,13 @@ export type FieldsetIdentity = string;
|
|
|
553
567
|
* via the `definition` "type".
|
|
554
568
|
*/
|
|
555
569
|
export type WorkflowType = 'workflow';
|
|
570
|
+
/**
|
|
571
|
+
* Attributes and relationships to return for each `item_type` that this endpoint returns.
|
|
572
|
+
*
|
|
573
|
+
* This interface was referenced by `ItemType`'s JSON-Schema
|
|
574
|
+
* via the `definition` "sparse_fieldset".
|
|
575
|
+
*/
|
|
576
|
+
export type ItemTypeSparseFieldset = string;
|
|
556
577
|
/**
|
|
557
578
|
* This interface was referenced by `ItemType`'s JSON-Schema
|
|
558
579
|
* via the `create.hrefSchema` link.
|
|
@@ -577,6 +598,42 @@ export type ItemTypeCreateHrefSchema = {
|
|
|
577
598
|
* via the `instances.targetSchema` link.
|
|
578
599
|
*/
|
|
579
600
|
export type ItemTypeInstancesTargetSchema = ItemType[];
|
|
601
|
+
/**
|
|
602
|
+
* This interface was referenced by `ItemType`'s JSON-Schema
|
|
603
|
+
* via the `instances.hrefSchema` link.
|
|
604
|
+
*/
|
|
605
|
+
export type ItemTypeInstancesHrefSchema = {
|
|
606
|
+
/**
|
|
607
|
+
* Sparse fieldsets: for each entity type, the attributes and the relationships to return, separated by commas. Each entity declares its attributes and its relationships in its own schema.
|
|
608
|
+
*/
|
|
609
|
+
fields?: {
|
|
610
|
+
item_type?: ItemTypeSparseFieldset;
|
|
611
|
+
[k: string]: unknown;
|
|
612
|
+
};
|
|
613
|
+
[k: string]: unknown;
|
|
614
|
+
};
|
|
615
|
+
/**
|
|
616
|
+
* This interface was referenced by `ItemType`'s JSON-Schema
|
|
617
|
+
* via the `self.hrefSchema` link.
|
|
618
|
+
*/
|
|
619
|
+
export type ItemTypeSelfHrefSchema = {
|
|
620
|
+
/**
|
|
621
|
+
* Sparse fieldsets: for each entity type, the attributes and the relationships to return, separated by commas. Each entity declares its attributes and its relationships in its own schema.
|
|
622
|
+
*/
|
|
623
|
+
fields?: {
|
|
624
|
+
item_type?: ItemTypeSparseFieldset;
|
|
625
|
+
field?: FieldSparseFieldset;
|
|
626
|
+
[k: string]: unknown;
|
|
627
|
+
};
|
|
628
|
+
[k: string]: unknown;
|
|
629
|
+
};
|
|
630
|
+
/**
|
|
631
|
+
* Attributes and relationships to return for each `field` that this endpoint returns.
|
|
632
|
+
*
|
|
633
|
+
* This interface was referenced by `Field`'s JSON-Schema
|
|
634
|
+
* via the `definition` "sparse_fieldset".
|
|
635
|
+
*/
|
|
636
|
+
export type FieldSparseFieldset = string;
|
|
580
637
|
/**
|
|
581
638
|
* This interface was referenced by `ItemType`'s JSON-Schema
|
|
582
639
|
* via the `destroy.hrefSchema` link.
|
|
@@ -593,6 +650,20 @@ export type ItemTypeDestroyHrefSchema = {
|
|
|
593
650
|
* via the `referencing.targetSchema` link.
|
|
594
651
|
*/
|
|
595
652
|
export type ItemTypeReferencingTargetSchema = ItemType[];
|
|
653
|
+
/**
|
|
654
|
+
* This interface was referenced by `ItemType`'s JSON-Schema
|
|
655
|
+
* via the `referencing.hrefSchema` link.
|
|
656
|
+
*/
|
|
657
|
+
export type ItemTypeReferencingHrefSchema = {
|
|
658
|
+
/**
|
|
659
|
+
* Sparse fieldsets: for each entity type, the attributes and the relationships to return, separated by commas. Each entity declares its attributes and its relationships in its own schema.
|
|
660
|
+
*/
|
|
661
|
+
fields?: {
|
|
662
|
+
item_type?: ItemTypeSparseFieldset;
|
|
663
|
+
[k: string]: unknown;
|
|
664
|
+
};
|
|
665
|
+
[k: string]: unknown;
|
|
666
|
+
};
|
|
596
667
|
/**
|
|
597
668
|
* This interface was referenced by `ItemType`'s JSON-Schema
|
|
598
669
|
* via the `reorder_fields_and_fieldsets.schema` link.
|
|
@@ -618,21 +689,112 @@ export type ItemTypeReorderFieldsAndFieldsetsSchema = ({
|
|
|
618
689
|
* via the `instances.targetSchema` link.
|
|
619
690
|
*/
|
|
620
691
|
export type FieldInstancesTargetSchema = Field[];
|
|
692
|
+
/**
|
|
693
|
+
* This interface was referenced by `Field`'s JSON-Schema
|
|
694
|
+
* via the `instances.hrefSchema` link.
|
|
695
|
+
*/
|
|
696
|
+
export type FieldInstancesHrefSchema = {
|
|
697
|
+
/**
|
|
698
|
+
* Sparse fieldsets: for each entity type, the attributes and the relationships to return, separated by commas. Each entity declares its attributes and its relationships in its own schema.
|
|
699
|
+
*/
|
|
700
|
+
fields?: {
|
|
701
|
+
field?: FieldSparseFieldset;
|
|
702
|
+
[k: string]: unknown;
|
|
703
|
+
};
|
|
704
|
+
[k: string]: unknown;
|
|
705
|
+
};
|
|
621
706
|
/**
|
|
622
707
|
* This interface was referenced by `Field`'s JSON-Schema
|
|
623
708
|
* via the `referencing.targetSchema` link.
|
|
624
709
|
*/
|
|
625
710
|
export type FieldReferencingTargetSchema = Field[];
|
|
711
|
+
/**
|
|
712
|
+
* This interface was referenced by `Field`'s JSON-Schema
|
|
713
|
+
* via the `referencing.hrefSchema` link.
|
|
714
|
+
*/
|
|
715
|
+
export type FieldReferencingHrefSchema = {
|
|
716
|
+
/**
|
|
717
|
+
* Sparse fieldsets: for each entity type, the attributes and the relationships to return, separated by commas. Each entity declares its attributes and its relationships in its own schema.
|
|
718
|
+
*/
|
|
719
|
+
fields?: {
|
|
720
|
+
field?: FieldSparseFieldset;
|
|
721
|
+
[k: string]: unknown;
|
|
722
|
+
};
|
|
723
|
+
[k: string]: unknown;
|
|
724
|
+
};
|
|
626
725
|
/**
|
|
627
726
|
* This interface was referenced by `Field`'s JSON-Schema
|
|
628
727
|
* via the `related.targetSchema` link.
|
|
629
728
|
*/
|
|
630
729
|
export type FieldRelatedTargetSchema = Field[];
|
|
730
|
+
/**
|
|
731
|
+
* This interface was referenced by `Field`'s JSON-Schema
|
|
732
|
+
* via the `related.hrefSchema` link.
|
|
733
|
+
*/
|
|
734
|
+
export type FieldRelatedHrefSchema = {
|
|
735
|
+
/**
|
|
736
|
+
* Sparse fieldsets: for each entity type, the attributes and the relationships to return, separated by commas. Each entity declares its attributes and its relationships in its own schema.
|
|
737
|
+
*/
|
|
738
|
+
fields?: {
|
|
739
|
+
field?: FieldSparseFieldset;
|
|
740
|
+
[k: string]: unknown;
|
|
741
|
+
};
|
|
742
|
+
[k: string]: unknown;
|
|
743
|
+
};
|
|
744
|
+
/**
|
|
745
|
+
* This interface was referenced by `Field`'s JSON-Schema
|
|
746
|
+
* via the `self.hrefSchema` link.
|
|
747
|
+
*/
|
|
748
|
+
export type FieldSelfHrefSchema = {
|
|
749
|
+
/**
|
|
750
|
+
* Sparse fieldsets: for each entity type, the attributes and the relationships to return, separated by commas. Each entity declares its attributes and its relationships in its own schema.
|
|
751
|
+
*/
|
|
752
|
+
fields?: {
|
|
753
|
+
field?: FieldSparseFieldset;
|
|
754
|
+
[k: string]: unknown;
|
|
755
|
+
};
|
|
756
|
+
[k: string]: unknown;
|
|
757
|
+
};
|
|
758
|
+
/**
|
|
759
|
+
* Attributes and relationships to return for each `fieldset` that this endpoint returns.
|
|
760
|
+
*
|
|
761
|
+
* This interface was referenced by `Fieldset`'s JSON-Schema
|
|
762
|
+
* via the `definition` "sparse_fieldset".
|
|
763
|
+
*/
|
|
764
|
+
export type FieldsetSparseFieldset = string;
|
|
631
765
|
/**
|
|
632
766
|
* This interface was referenced by `Fieldset`'s JSON-Schema
|
|
633
767
|
* via the `instances.targetSchema` link.
|
|
634
768
|
*/
|
|
635
769
|
export type FieldsetInstancesTargetSchema = Fieldset[];
|
|
770
|
+
/**
|
|
771
|
+
* This interface was referenced by `Fieldset`'s JSON-Schema
|
|
772
|
+
* via the `instances.hrefSchema` link.
|
|
773
|
+
*/
|
|
774
|
+
export type FieldsetInstancesHrefSchema = {
|
|
775
|
+
/**
|
|
776
|
+
* Sparse fieldsets: for each entity type, the attributes and the relationships to return, separated by commas. Each entity declares its attributes and its relationships in its own schema.
|
|
777
|
+
*/
|
|
778
|
+
fields?: {
|
|
779
|
+
fieldset?: FieldsetSparseFieldset;
|
|
780
|
+
[k: string]: unknown;
|
|
781
|
+
};
|
|
782
|
+
[k: string]: unknown;
|
|
783
|
+
};
|
|
784
|
+
/**
|
|
785
|
+
* This interface was referenced by `Fieldset`'s JSON-Schema
|
|
786
|
+
* via the `self.hrefSchema` link.
|
|
787
|
+
*/
|
|
788
|
+
export type FieldsetSelfHrefSchema = {
|
|
789
|
+
/**
|
|
790
|
+
* Sparse fieldsets: for each entity type, the attributes and the relationships to return, separated by commas. Each entity declares its attributes and its relationships in its own schema.
|
|
791
|
+
*/
|
|
792
|
+
fields?: {
|
|
793
|
+
fieldset?: FieldsetSparseFieldset;
|
|
794
|
+
[k: string]: unknown;
|
|
795
|
+
};
|
|
796
|
+
[k: string]: unknown;
|
|
797
|
+
};
|
|
636
798
|
/**
|
|
637
799
|
* This interface was referenced by `ItemType`'s JSON-Schema
|
|
638
800
|
* via the `reorder_fields_and_fieldsets.jobSchema` link.
|
|
@@ -879,6 +1041,13 @@ export type SearchIndexEventInstancesHrefSchema = {
|
|
|
879
1041
|
order_by?: 'search_index_id_asc' | 'search_index_id_desc' | 'created_at_asc' | 'created_at_desc' | 'event_type_asc' | 'event_type_desc';
|
|
880
1042
|
[k: string]: unknown;
|
|
881
1043
|
};
|
|
1044
|
+
/**
|
|
1045
|
+
* Attributes and relationships to return for each `item` that this endpoint returns.
|
|
1046
|
+
*
|
|
1047
|
+
* This interface was referenced by `Item`'s JSON-Schema
|
|
1048
|
+
* via the `definition` "sparse_fieldset".
|
|
1049
|
+
*/
|
|
1050
|
+
export type ItemSparseFieldset = string;
|
|
882
1051
|
/**
|
|
883
1052
|
* This interface was referenced by `Item`'s JSON-Schema
|
|
884
1053
|
* via the `instances.targetSchema` link.
|
|
@@ -1904,15 +2073,35 @@ export type SiteIdentity = string;
|
|
|
1904
2073
|
* via the `definition` "type".
|
|
1905
2074
|
*/
|
|
1906
2075
|
export type SiteType = 'site';
|
|
2076
|
+
/**
|
|
2077
|
+
* Attributes and relationships to return for each `site` that this endpoint returns.
|
|
2078
|
+
*
|
|
2079
|
+
* This interface was referenced by `Site`'s JSON-Schema
|
|
2080
|
+
* via the `definition` "sparse_fieldset".
|
|
2081
|
+
*/
|
|
2082
|
+
export type SiteSparseFieldset = string;
|
|
1907
2083
|
/**
|
|
1908
2084
|
* This interface was referenced by `Site`'s JSON-Schema
|
|
1909
2085
|
* via the `self.hrefSchema` link.
|
|
1910
2086
|
*/
|
|
1911
2087
|
export type SiteSelfHrefSchema = {
|
|
1912
2088
|
/**
|
|
1913
|
-
* Comma-separated list of [relationship paths](https://jsonapi.org/format/#fetching-includes). A relationship path is a dot-separated list of relationship names. Allowed relationship paths: `item_types`, `item_types.fields`, `item_types.fieldsets`, `item_types.singleton_item`, `account`.
|
|
2089
|
+
* Comma-separated list of [relationship paths](https://jsonapi.org/format/#fetching-includes). A relationship path is a dot-separated list of relationship names. Allowed relationship paths: `item_types`, `item_types.fields`, `item_types.fieldsets`, `item_types.singleton_item`, `account`, `owner`.
|
|
1914
2090
|
*/
|
|
1915
2091
|
include?: string;
|
|
2092
|
+
/**
|
|
2093
|
+
* Sparse fieldsets: for each entity type, the attributes and the relationships to return, separated by commas. Each entity declares its attributes and its relationships in its own schema.
|
|
2094
|
+
*/
|
|
2095
|
+
fields?: {
|
|
2096
|
+
site?: SiteSparseFieldset;
|
|
2097
|
+
item_type?: ItemTypeSparseFieldset;
|
|
2098
|
+
field?: FieldSparseFieldset;
|
|
2099
|
+
fieldset?: FieldsetSparseFieldset;
|
|
2100
|
+
item?: ItemSparseFieldset;
|
|
2101
|
+
account?: AccountSparseFieldset;
|
|
2102
|
+
organization?: OrganizationSparseFieldset;
|
|
2103
|
+
[k: string]: unknown;
|
|
2104
|
+
};
|
|
1916
2105
|
[k: string]: unknown;
|
|
1917
2106
|
};
|
|
1918
2107
|
/**
|
|
@@ -6788,7 +6977,7 @@ export type Plugin = {
|
|
|
6788
6977
|
*/
|
|
6789
6978
|
url: string;
|
|
6790
6979
|
/**
|
|
6791
|
-
* Global plugin configuration. Plugins can persist whatever information they want in this object to reuse it later. Refer to the CMA for details about technical limits.
|
|
6980
|
+
* Global plugin configuration. Plugins can persist whatever information they want in this object to reuse it later. Refer to the CMA for details about technical limits. Collaborators always receive it. API tokens and OAuth applications receive it only if they can edit the schema of the project, otherwise it returns `null`.
|
|
6792
6981
|
*/
|
|
6793
6982
|
parameters: null | {
|
|
6794
6983
|
[k: string]: unknown;
|
|
@@ -6872,7 +7061,7 @@ export type PluginAttributes = {
|
|
|
6872
7061
|
*/
|
|
6873
7062
|
url: string;
|
|
6874
7063
|
/**
|
|
6875
|
-
* Global plugin configuration. Plugins can persist whatever information they want in this object to reuse it later. Refer to the CMA for details about technical limits.
|
|
7064
|
+
* Global plugin configuration. Plugins can persist whatever information they want in this object to reuse it later. Refer to the CMA for details about technical limits. Collaborators always receive it. API tokens and OAuth applications receive it only if they can edit the schema of the project, otherwise it returns `null`.
|
|
6876
7065
|
*/
|
|
6877
7066
|
parameters: null | {
|
|
6878
7067
|
[k: string]: unknown;
|
|
@@ -7389,6 +7578,12 @@ export type ItemValidateExistingSchema<D extends ItemTypeDefinition = ItemTypeDe
|
|
|
7389
7578
|
type?: ItemType1;
|
|
7390
7579
|
item_type?: ItemTypeData<D>;
|
|
7391
7580
|
creator?: AccountData | AccessTokenData | UserData | SsoUserData | OrganizationData;
|
|
7581
|
+
/**
|
|
7582
|
+
* Accepted so you can validate the same payload you will send to update the record, but ignored
|
|
7583
|
+
*/
|
|
7584
|
+
meta?: {
|
|
7585
|
+
[k: string]: unknown;
|
|
7586
|
+
};
|
|
7392
7587
|
__itemTypeId?: D['itemTypeId'];
|
|
7393
7588
|
} & ToItemAttributesInRequest<D>;
|
|
7394
7589
|
/**
|
|
@@ -7396,9 +7591,16 @@ export type ItemValidateExistingSchema<D extends ItemTypeDefinition = ItemTypeDe
|
|
|
7396
7591
|
* via the `validate_new.schema` link.
|
|
7397
7592
|
*/
|
|
7398
7593
|
export type ItemValidateNewSchema<D extends ItemTypeDefinition = ItemTypeDefinition> = {
|
|
7594
|
+
id?: ItemIdentity;
|
|
7399
7595
|
type?: ItemType1;
|
|
7400
7596
|
item_type: ItemTypeData<D>;
|
|
7401
7597
|
creator?: AccountData | AccessTokenData | UserData | SsoUserData | OrganizationData;
|
|
7598
|
+
/**
|
|
7599
|
+
* Accepted so you can validate the same payload you will send to create the record, but ignored
|
|
7600
|
+
*/
|
|
7601
|
+
meta?: {
|
|
7602
|
+
[k: string]: unknown;
|
|
7603
|
+
};
|
|
7402
7604
|
__itemTypeId?: D['itemTypeId'];
|
|
7403
7605
|
} & ToItemAttributesInRequest<D>;
|
|
7404
7606
|
/**
|
|
@@ -59,7 +59,7 @@ export class Client {
|
|
|
59
59
|
...this.config,
|
|
60
60
|
...options,
|
|
61
61
|
logFn: this.config.logFn || console.log,
|
|
62
|
-
userAgent: '@datocms/cma-client v6.
|
|
62
|
+
userAgent: '@datocms/cma-client v6.8.0',
|
|
63
63
|
baseUrl: this.baseUrl,
|
|
64
64
|
preCallStack: new Error().stack,
|
|
65
65
|
extraHeaders: {
|