@datocms/cma-client
Advanced tools
Comparing version
@@ -134,3 +134,3 @@ "use strict"; | ||
var _this = this; | ||
return (0, rest_client_utils_1.request)(__assign(__assign(__assign({}, this.config), options), { logFn: this.config.logFn || console.log, userAgent: '@datocms/cma-client v3.3.8', baseUrl: this.baseUrl, preCallStack: new Error().stack, extraHeaders: __assign(__assign(__assign({}, (this.config.extraHeaders || {})), (this.config.environment | ||
return (0, rest_client_utils_1.request)(__assign(__assign(__assign({}, this.config), options), { logFn: this.config.logFn || console.log, userAgent: '@datocms/cma-client v3.3.9', baseUrl: this.baseUrl, preCallStack: new Error().stack, extraHeaders: __assign(__assign(__assign({}, (this.config.extraHeaders || {})), (this.config.environment | ||
? { 'X-Environment': this.config.environment } | ||
@@ -137,0 +137,0 @@ : {})), { 'X-API-Version': '3' }), fetchJobResult: function (jobId) { |
@@ -269,2 +269,19 @@ "use strict"; | ||
}; | ||
/** | ||
* Reorders a set of fields and fieldsets within the model | ||
* | ||
* Read more: https://www.datocms.com/docs/content-management-api/resources/item-type/reorder_fields_and_fieldsets | ||
* | ||
* @throws {ApiError} | ||
* @throws {TimeoutError} | ||
* | ||
* @deprecated This API call is to be considered private and might change without notice | ||
*/ | ||
ItemType.prototype.rawReorderFieldsAndFieldsets = function (body) { | ||
return this.client.request({ | ||
method: 'POST', | ||
url: '/item-types/reorder-fields-and-fieldsets', | ||
body: body, | ||
}); | ||
}; | ||
ItemType.TYPE = 'item_type'; | ||
@@ -271,0 +288,0 @@ return ItemType; |
@@ -198,2 +198,38 @@ "use strict"; | ||
}; | ||
/** | ||
* Reorders a set of menu items | ||
* | ||
* Read more: https://www.datocms.com/docs/content-management-api/resources/menu-item/reorder | ||
* | ||
* @throws {ApiError} | ||
* @throws {TimeoutError} | ||
* | ||
* @deprecated This API call is to be considered private and might change without notice | ||
*/ | ||
MenuItem.prototype.reorder = function (body) { | ||
return this.rawReorder(Utils.serializeRequestBody(body, { | ||
type: 'menu_item', | ||
attributes: [], | ||
relationships: [], | ||
})).then(function (body) { | ||
return Utils.deserializeResponseBody(body); | ||
}); | ||
}; | ||
/** | ||
* Reorders a set of menu items | ||
* | ||
* Read more: https://www.datocms.com/docs/content-management-api/resources/menu-item/reorder | ||
* | ||
* @throws {ApiError} | ||
* @throws {TimeoutError} | ||
* | ||
* @deprecated This API call is to be considered private and might change without notice | ||
*/ | ||
MenuItem.prototype.rawReorder = function (body) { | ||
return this.client.request({ | ||
method: 'POST', | ||
url: '/menu-items/reorder', | ||
body: body, | ||
}); | ||
}; | ||
MenuItem.TYPE = 'menu_item'; | ||
@@ -200,0 +236,0 @@ return MenuItem; |
@@ -198,2 +198,38 @@ "use strict"; | ||
}; | ||
/** | ||
* Reorders a set of schema menu items | ||
* | ||
* Read more: https://www.datocms.com/docs/content-management-api/resources/schema-menu_item/reorder | ||
* | ||
* @throws {ApiError} | ||
* @throws {TimeoutError} | ||
* | ||
* @deprecated This API call is to be considered private and might change without notice | ||
*/ | ||
SchemaMenuItem.prototype.reorder = function (body) { | ||
return this.rawReorder(Utils.serializeRequestBody(body, { | ||
type: 'schema_menu_item', | ||
attributes: [], | ||
relationships: [], | ||
})).then(function (body) { | ||
return Utils.deserializeResponseBody(body); | ||
}); | ||
}; | ||
/** | ||
* Reorders a set of schema menu items | ||
* | ||
* Read more: https://www.datocms.com/docs/content-management-api/resources/schema-menu_item/reorder | ||
* | ||
* @throws {ApiError} | ||
* @throws {TimeoutError} | ||
* | ||
* @deprecated This API call is to be considered private and might change without notice | ||
*/ | ||
SchemaMenuItem.prototype.rawReorder = function (body) { | ||
return this.client.request({ | ||
method: 'POST', | ||
url: '/schema-menu-items/reorder', | ||
body: body, | ||
}); | ||
}; | ||
SchemaMenuItem.TYPE = 'schema_menu_item'; | ||
@@ -200,0 +236,0 @@ return SchemaMenuItem; |
@@ -198,2 +198,38 @@ "use strict"; | ||
}; | ||
/** | ||
* Reorders a set of upload collections | ||
* | ||
* Read more: https://www.datocms.com/docs/content-management-api/resources/upload-collection/reorder | ||
* | ||
* @throws {ApiError} | ||
* @throws {TimeoutError} | ||
* | ||
* @deprecated This API call is to be considered private and might change without notice | ||
*/ | ||
UploadCollection.prototype.reorder = function (body) { | ||
return this.rawReorder(Utils.serializeRequestBody(body, { | ||
type: 'upload_collection', | ||
attributes: [], | ||
relationships: [], | ||
})).then(function (body) { | ||
return Utils.deserializeResponseBody(body); | ||
}); | ||
}; | ||
/** | ||
* Reorders a set of upload collections | ||
* | ||
* Read more: https://www.datocms.com/docs/content-management-api/resources/upload-collection/reorder | ||
* | ||
* @throws {ApiError} | ||
* @throws {TimeoutError} | ||
* | ||
* @deprecated This API call is to be considered private and might change without notice | ||
*/ | ||
UploadCollection.prototype.rawReorder = function (body) { | ||
return this.client.request({ | ||
method: 'POST', | ||
url: '/upload-collections/reorder', | ||
body: body, | ||
}); | ||
}; | ||
UploadCollection.TYPE = 'upload_collection'; | ||
@@ -200,0 +236,0 @@ return UploadCollection; |
@@ -247,4 +247,4 @@ "use strict"; | ||
*/ | ||
WebhookCall.prototype.resendWebhook = function (userId) { | ||
return this.rawResendWebhook(Utils.toId(userId)); | ||
WebhookCall.prototype.resendWebhook = function (webhookCallId) { | ||
return this.rawResendWebhook(Utils.toId(webhookCallId)); | ||
}; | ||
@@ -259,6 +259,6 @@ /** | ||
*/ | ||
WebhookCall.prototype.rawResendWebhook = function (userId) { | ||
WebhookCall.prototype.rawResendWebhook = function (webhookCallId) { | ||
return this.client.request({ | ||
method: 'POST', | ||
url: "/webhook_calls/".concat(userId, "/resend_webhook"), | ||
url: "/webhook_calls/".concat(webhookCallId, "/resend_webhook"), | ||
}); | ||
@@ -265,0 +265,0 @@ }; |
@@ -108,3 +108,3 @@ var __assign = (this && this.__assign) || function () { | ||
var _this = this; | ||
return request(__assign(__assign(__assign({}, this.config), options), { logFn: this.config.logFn || console.log, userAgent: '@datocms/cma-client v3.3.8', baseUrl: this.baseUrl, preCallStack: new Error().stack, extraHeaders: __assign(__assign(__assign({}, (this.config.extraHeaders || {})), (this.config.environment | ||
return request(__assign(__assign(__assign({}, this.config), options), { logFn: this.config.logFn || console.log, userAgent: '@datocms/cma-client v3.3.9', baseUrl: this.baseUrl, preCallStack: new Error().stack, extraHeaders: __assign(__assign(__assign({}, (this.config.extraHeaders || {})), (this.config.environment | ||
? { 'X-Environment': this.config.environment } | ||
@@ -111,0 +111,0 @@ : {})), { 'X-API-Version': '3' }), fetchJobResult: function (jobId) { |
@@ -114,2 +114,13 @@ import BaseResource from '../../BaseResource'; | ||
rawDestroy(itemTypeId: string, queryParams?: SchemaTypes.ItemTypeDestroyHrefSchema): Promise<SchemaTypes.ItemTypeDestroyJobSchema>; | ||
/** | ||
* Reorders a set of fields and fieldsets within the model | ||
* | ||
* Read more: https://www.datocms.com/docs/content-management-api/resources/item-type/reorder_fields_and_fieldsets | ||
* | ||
* @throws {ApiError} | ||
* @throws {TimeoutError} | ||
* | ||
* @deprecated This API call is to be considered private and might change without notice | ||
*/ | ||
rawReorderFieldsAndFieldsets(body: SchemaTypes.ItemTypeReorderFieldsAndFieldsetsSchema): Promise<SchemaTypes.ItemTypeReorderFieldsAndFieldsetsJobSchema>; | ||
} |
@@ -241,2 +241,19 @@ var __extends = (this && this.__extends) || (function () { | ||
}; | ||
/** | ||
* Reorders a set of fields and fieldsets within the model | ||
* | ||
* Read more: https://www.datocms.com/docs/content-management-api/resources/item-type/reorder_fields_and_fieldsets | ||
* | ||
* @throws {ApiError} | ||
* @throws {TimeoutError} | ||
* | ||
* @deprecated This API call is to be considered private and might change without notice | ||
*/ | ||
ItemType.prototype.rawReorderFieldsAndFieldsets = function (body) { | ||
return this.client.request({ | ||
method: 'POST', | ||
url: '/item-types/reorder-fields-and-fieldsets', | ||
body: body, | ||
}); | ||
}; | ||
ItemType.TYPE = 'item_type'; | ||
@@ -243,0 +260,0 @@ return ItemType; |
@@ -96,2 +96,24 @@ import BaseResource from '../../BaseResource'; | ||
rawDestroy(menuItemId: string): Promise<SchemaTypes.MenuItemDestroyTargetSchema>; | ||
/** | ||
* Reorders a set of menu items | ||
* | ||
* Read more: https://www.datocms.com/docs/content-management-api/resources/menu-item/reorder | ||
* | ||
* @throws {ApiError} | ||
* @throws {TimeoutError} | ||
* | ||
* @deprecated This API call is to be considered private and might change without notice | ||
*/ | ||
reorder(body: SimpleSchemaTypes.MenuItemReorderSchema): Promise<SimpleSchemaTypes.MenuItemReorderJobSchema>; | ||
/** | ||
* Reorders a set of menu items | ||
* | ||
* Read more: https://www.datocms.com/docs/content-management-api/resources/menu-item/reorder | ||
* | ||
* @throws {ApiError} | ||
* @throws {TimeoutError} | ||
* | ||
* @deprecated This API call is to be considered private and might change without notice | ||
*/ | ||
rawReorder(body: SchemaTypes.MenuItemReorderSchema): Promise<SchemaTypes.MenuItemReorderJobSchema>; | ||
} |
@@ -170,2 +170,38 @@ var __extends = (this && this.__extends) || (function () { | ||
}; | ||
/** | ||
* Reorders a set of menu items | ||
* | ||
* Read more: https://www.datocms.com/docs/content-management-api/resources/menu-item/reorder | ||
* | ||
* @throws {ApiError} | ||
* @throws {TimeoutError} | ||
* | ||
* @deprecated This API call is to be considered private and might change without notice | ||
*/ | ||
MenuItem.prototype.reorder = function (body) { | ||
return this.rawReorder(Utils.serializeRequestBody(body, { | ||
type: 'menu_item', | ||
attributes: [], | ||
relationships: [], | ||
})).then(function (body) { | ||
return Utils.deserializeResponseBody(body); | ||
}); | ||
}; | ||
/** | ||
* Reorders a set of menu items | ||
* | ||
* Read more: https://www.datocms.com/docs/content-management-api/resources/menu-item/reorder | ||
* | ||
* @throws {ApiError} | ||
* @throws {TimeoutError} | ||
* | ||
* @deprecated This API call is to be considered private and might change without notice | ||
*/ | ||
MenuItem.prototype.rawReorder = function (body) { | ||
return this.client.request({ | ||
method: 'POST', | ||
url: '/menu-items/reorder', | ||
body: body, | ||
}); | ||
}; | ||
MenuItem.TYPE = 'menu_item'; | ||
@@ -172,0 +208,0 @@ return MenuItem; |
@@ -96,2 +96,24 @@ import BaseResource from '../../BaseResource'; | ||
rawDestroy(schemaMenuItemId: string): Promise<SchemaTypes.SchemaMenuItemDestroyTargetSchema>; | ||
/** | ||
* Reorders a set of schema menu items | ||
* | ||
* Read more: https://www.datocms.com/docs/content-management-api/resources/schema-menu_item/reorder | ||
* | ||
* @throws {ApiError} | ||
* @throws {TimeoutError} | ||
* | ||
* @deprecated This API call is to be considered private and might change without notice | ||
*/ | ||
reorder(body: SimpleSchemaTypes.SchemaMenuItemReorderSchema): Promise<SimpleSchemaTypes.SchemaMenuItemReorderJobSchema>; | ||
/** | ||
* Reorders a set of schema menu items | ||
* | ||
* Read more: https://www.datocms.com/docs/content-management-api/resources/schema-menu_item/reorder | ||
* | ||
* @throws {ApiError} | ||
* @throws {TimeoutError} | ||
* | ||
* @deprecated This API call is to be considered private and might change without notice | ||
*/ | ||
rawReorder(body: SchemaTypes.SchemaMenuItemReorderSchema): Promise<SchemaTypes.SchemaMenuItemReorderJobSchema>; | ||
} |
@@ -170,2 +170,38 @@ var __extends = (this && this.__extends) || (function () { | ||
}; | ||
/** | ||
* Reorders a set of schema menu items | ||
* | ||
* Read more: https://www.datocms.com/docs/content-management-api/resources/schema-menu_item/reorder | ||
* | ||
* @throws {ApiError} | ||
* @throws {TimeoutError} | ||
* | ||
* @deprecated This API call is to be considered private and might change without notice | ||
*/ | ||
SchemaMenuItem.prototype.reorder = function (body) { | ||
return this.rawReorder(Utils.serializeRequestBody(body, { | ||
type: 'schema_menu_item', | ||
attributes: [], | ||
relationships: [], | ||
})).then(function (body) { | ||
return Utils.deserializeResponseBody(body); | ||
}); | ||
}; | ||
/** | ||
* Reorders a set of schema menu items | ||
* | ||
* Read more: https://www.datocms.com/docs/content-management-api/resources/schema-menu_item/reorder | ||
* | ||
* @throws {ApiError} | ||
* @throws {TimeoutError} | ||
* | ||
* @deprecated This API call is to be considered private and might change without notice | ||
*/ | ||
SchemaMenuItem.prototype.rawReorder = function (body) { | ||
return this.client.request({ | ||
method: 'POST', | ||
url: '/schema-menu-items/reorder', | ||
body: body, | ||
}); | ||
}; | ||
SchemaMenuItem.TYPE = 'schema_menu_item'; | ||
@@ -172,0 +208,0 @@ return SchemaMenuItem; |
@@ -96,2 +96,24 @@ import BaseResource from '../../BaseResource'; | ||
rawDestroy(uploadCollectionId: string): Promise<SchemaTypes.UploadCollectionDestroyTargetSchema>; | ||
/** | ||
* Reorders a set of upload collections | ||
* | ||
* Read more: https://www.datocms.com/docs/content-management-api/resources/upload-collection/reorder | ||
* | ||
* @throws {ApiError} | ||
* @throws {TimeoutError} | ||
* | ||
* @deprecated This API call is to be considered private and might change without notice | ||
*/ | ||
reorder(body: SimpleSchemaTypes.UploadCollectionReorderSchema): Promise<SimpleSchemaTypes.UploadCollectionReorderJobSchema>; | ||
/** | ||
* Reorders a set of upload collections | ||
* | ||
* Read more: https://www.datocms.com/docs/content-management-api/resources/upload-collection/reorder | ||
* | ||
* @throws {ApiError} | ||
* @throws {TimeoutError} | ||
* | ||
* @deprecated This API call is to be considered private and might change without notice | ||
*/ | ||
rawReorder(body: SchemaTypes.UploadCollectionReorderSchema): Promise<SchemaTypes.UploadCollectionReorderJobSchema>; | ||
} |
@@ -170,2 +170,38 @@ var __extends = (this && this.__extends) || (function () { | ||
}; | ||
/** | ||
* Reorders a set of upload collections | ||
* | ||
* Read more: https://www.datocms.com/docs/content-management-api/resources/upload-collection/reorder | ||
* | ||
* @throws {ApiError} | ||
* @throws {TimeoutError} | ||
* | ||
* @deprecated This API call is to be considered private and might change without notice | ||
*/ | ||
UploadCollection.prototype.reorder = function (body) { | ||
return this.rawReorder(Utils.serializeRequestBody(body, { | ||
type: 'upload_collection', | ||
attributes: [], | ||
relationships: [], | ||
})).then(function (body) { | ||
return Utils.deserializeResponseBody(body); | ||
}); | ||
}; | ||
/** | ||
* Reorders a set of upload collections | ||
* | ||
* Read more: https://www.datocms.com/docs/content-management-api/resources/upload-collection/reorder | ||
* | ||
* @throws {ApiError} | ||
* @throws {TimeoutError} | ||
* | ||
* @deprecated This API call is to be considered private and might change without notice | ||
*/ | ||
UploadCollection.prototype.rawReorder = function (body) { | ||
return this.client.request({ | ||
method: 'POST', | ||
url: '/upload-collections/reorder', | ||
body: body, | ||
}); | ||
}; | ||
UploadCollection.TYPE = 'upload_collection'; | ||
@@ -172,0 +208,0 @@ return UploadCollection; |
@@ -69,3 +69,3 @@ import * as Utils from '@datocms/rest-client-utils'; | ||
*/ | ||
resendWebhook(userId: string | SimpleSchemaTypes.UserData): Promise<void>; | ||
resendWebhook(webhookCallId: string | SimpleSchemaTypes.WebhookCallData): Promise<void>; | ||
/** | ||
@@ -79,3 +79,3 @@ * Re-send the webhook call | ||
*/ | ||
rawResendWebhook(userId: string): Promise<void>; | ||
rawResendWebhook(webhookCallId: string): Promise<void>; | ||
} |
@@ -219,4 +219,4 @@ var __extends = (this && this.__extends) || (function () { | ||
*/ | ||
WebhookCall.prototype.resendWebhook = function (userId) { | ||
return this.rawResendWebhook(Utils.toId(userId)); | ||
WebhookCall.prototype.resendWebhook = function (webhookCallId) { | ||
return this.rawResendWebhook(Utils.toId(webhookCallId)); | ||
}; | ||
@@ -231,6 +231,6 @@ /** | ||
*/ | ||
WebhookCall.prototype.rawResendWebhook = function (userId) { | ||
WebhookCall.prototype.rawResendWebhook = function (webhookCallId) { | ||
return this.client.request({ | ||
method: 'POST', | ||
url: "/webhook_calls/".concat(userId, "/resend_webhook"), | ||
url: "/webhook_calls/".concat(webhookCallId, "/resend_webhook"), | ||
}); | ||
@@ -237,0 +237,0 @@ }; |
@@ -114,2 +114,13 @@ import BaseResource from '../../BaseResource'; | ||
rawDestroy(itemTypeId: string, queryParams?: SchemaTypes.ItemTypeDestroyHrefSchema): Promise<SchemaTypes.ItemTypeDestroyJobSchema>; | ||
/** | ||
* Reorders a set of fields and fieldsets within the model | ||
* | ||
* Read more: https://www.datocms.com/docs/content-management-api/resources/item-type/reorder_fields_and_fieldsets | ||
* | ||
* @throws {ApiError} | ||
* @throws {TimeoutError} | ||
* | ||
* @deprecated This API call is to be considered private and might change without notice | ||
*/ | ||
rawReorderFieldsAndFieldsets(body: SchemaTypes.ItemTypeReorderFieldsAndFieldsetsSchema): Promise<SchemaTypes.ItemTypeReorderFieldsAndFieldsetsJobSchema>; | ||
} |
@@ -96,2 +96,24 @@ import BaseResource from '../../BaseResource'; | ||
rawDestroy(menuItemId: string): Promise<SchemaTypes.MenuItemDestroyTargetSchema>; | ||
/** | ||
* Reorders a set of menu items | ||
* | ||
* Read more: https://www.datocms.com/docs/content-management-api/resources/menu-item/reorder | ||
* | ||
* @throws {ApiError} | ||
* @throws {TimeoutError} | ||
* | ||
* @deprecated This API call is to be considered private and might change without notice | ||
*/ | ||
reorder(body: SimpleSchemaTypes.MenuItemReorderSchema): Promise<SimpleSchemaTypes.MenuItemReorderJobSchema>; | ||
/** | ||
* Reorders a set of menu items | ||
* | ||
* Read more: https://www.datocms.com/docs/content-management-api/resources/menu-item/reorder | ||
* | ||
* @throws {ApiError} | ||
* @throws {TimeoutError} | ||
* | ||
* @deprecated This API call is to be considered private and might change without notice | ||
*/ | ||
rawReorder(body: SchemaTypes.MenuItemReorderSchema): Promise<SchemaTypes.MenuItemReorderJobSchema>; | ||
} |
@@ -96,2 +96,24 @@ import BaseResource from '../../BaseResource'; | ||
rawDestroy(schemaMenuItemId: string): Promise<SchemaTypes.SchemaMenuItemDestroyTargetSchema>; | ||
/** | ||
* Reorders a set of schema menu items | ||
* | ||
* Read more: https://www.datocms.com/docs/content-management-api/resources/schema-menu_item/reorder | ||
* | ||
* @throws {ApiError} | ||
* @throws {TimeoutError} | ||
* | ||
* @deprecated This API call is to be considered private and might change without notice | ||
*/ | ||
reorder(body: SimpleSchemaTypes.SchemaMenuItemReorderSchema): Promise<SimpleSchemaTypes.SchemaMenuItemReorderJobSchema>; | ||
/** | ||
* Reorders a set of schema menu items | ||
* | ||
* Read more: https://www.datocms.com/docs/content-management-api/resources/schema-menu_item/reorder | ||
* | ||
* @throws {ApiError} | ||
* @throws {TimeoutError} | ||
* | ||
* @deprecated This API call is to be considered private and might change without notice | ||
*/ | ||
rawReorder(body: SchemaTypes.SchemaMenuItemReorderSchema): Promise<SchemaTypes.SchemaMenuItemReorderJobSchema>; | ||
} |
@@ -96,2 +96,24 @@ import BaseResource from '../../BaseResource'; | ||
rawDestroy(uploadCollectionId: string): Promise<SchemaTypes.UploadCollectionDestroyTargetSchema>; | ||
/** | ||
* Reorders a set of upload collections | ||
* | ||
* Read more: https://www.datocms.com/docs/content-management-api/resources/upload-collection/reorder | ||
* | ||
* @throws {ApiError} | ||
* @throws {TimeoutError} | ||
* | ||
* @deprecated This API call is to be considered private and might change without notice | ||
*/ | ||
reorder(body: SimpleSchemaTypes.UploadCollectionReorderSchema): Promise<SimpleSchemaTypes.UploadCollectionReorderJobSchema>; | ||
/** | ||
* Reorders a set of upload collections | ||
* | ||
* Read more: https://www.datocms.com/docs/content-management-api/resources/upload-collection/reorder | ||
* | ||
* @throws {ApiError} | ||
* @throws {TimeoutError} | ||
* | ||
* @deprecated This API call is to be considered private and might change without notice | ||
*/ | ||
rawReorder(body: SchemaTypes.UploadCollectionReorderSchema): Promise<SchemaTypes.UploadCollectionReorderJobSchema>; | ||
} |
@@ -69,3 +69,3 @@ import * as Utils from '@datocms/rest-client-utils'; | ||
*/ | ||
resendWebhook(userId: string | SimpleSchemaTypes.UserData): Promise<void>; | ||
resendWebhook(webhookCallId: string | SimpleSchemaTypes.WebhookCallData): Promise<void>; | ||
/** | ||
@@ -79,3 +79,3 @@ * Re-send the webhook call | ||
*/ | ||
rawResendWebhook(userId: string): Promise<void>; | ||
rawResendWebhook(webhookCallId: string): Promise<void>; | ||
} |
{ | ||
"name": "@datocms/cma-client", | ||
"version": "3.3.8", | ||
"version": "3.3.9", | ||
"description": "JS client for DatoCMS REST Content Management API", | ||
@@ -47,3 +47,3 @@ "keywords": [ | ||
}, | ||
"gitHead": "e46a0db6a551cfa9d6b3bb5d087c68ea09a15f7f" | ||
"gitHead": "0a74727e9f6008824496e8db450f1186bbad6a4a" | ||
} |
@@ -150,3 +150,3 @@ import { | ||
logFn: this.config.logFn || console.log, | ||
userAgent: '@datocms/cma-client v3.3.8', | ||
userAgent: '@datocms/cma-client v3.3.9', | ||
baseUrl: this.baseUrl, | ||
@@ -153,0 +153,0 @@ preCallStack: new Error().stack, |
@@ -276,2 +276,24 @@ import * as Utils from '@datocms/rest-client-utils'; | ||
} | ||
/** | ||
* Reorders a set of fields and fieldsets within the model | ||
* | ||
* Read more: https://www.datocms.com/docs/content-management-api/resources/item-type/reorder_fields_and_fieldsets | ||
* | ||
* @throws {ApiError} | ||
* @throws {TimeoutError} | ||
* | ||
* @deprecated This API call is to be considered private and might change without notice | ||
*/ | ||
rawReorderFieldsAndFieldsets( | ||
body: SchemaTypes.ItemTypeReorderFieldsAndFieldsetsSchema, | ||
): Promise<SchemaTypes.ItemTypeReorderFieldsAndFieldsetsJobSchema> { | ||
return this.client.request<SchemaTypes.ItemTypeReorderFieldsAndFieldsetsJobSchema>( | ||
{ | ||
method: 'POST', | ||
url: '/item-types/reorder-fields-and-fieldsets', | ||
body, | ||
}, | ||
); | ||
} | ||
} |
@@ -192,2 +192,46 @@ import * as Utils from '@datocms/rest-client-utils'; | ||
} | ||
/** | ||
* Reorders a set of menu items | ||
* | ||
* Read more: https://www.datocms.com/docs/content-management-api/resources/menu-item/reorder | ||
* | ||
* @throws {ApiError} | ||
* @throws {TimeoutError} | ||
* | ||
* @deprecated This API call is to be considered private and might change without notice | ||
*/ | ||
reorder(body: SimpleSchemaTypes.MenuItemReorderSchema) { | ||
return this.rawReorder( | ||
Utils.serializeRequestBody<SchemaTypes.MenuItemReorderSchema>(body, { | ||
type: 'menu_item', | ||
attributes: [], | ||
relationships: [], | ||
}), | ||
).then((body) => | ||
Utils.deserializeResponseBody<SimpleSchemaTypes.MenuItemReorderJobSchema>( | ||
body, | ||
), | ||
); | ||
} | ||
/** | ||
* Reorders a set of menu items | ||
* | ||
* Read more: https://www.datocms.com/docs/content-management-api/resources/menu-item/reorder | ||
* | ||
* @throws {ApiError} | ||
* @throws {TimeoutError} | ||
* | ||
* @deprecated This API call is to be considered private and might change without notice | ||
*/ | ||
rawReorder( | ||
body: SchemaTypes.MenuItemReorderSchema, | ||
): Promise<SchemaTypes.MenuItemReorderJobSchema> { | ||
return this.client.request<SchemaTypes.MenuItemReorderJobSchema>({ | ||
method: 'POST', | ||
url: '/menu-items/reorder', | ||
body, | ||
}); | ||
} | ||
} |
@@ -196,2 +196,49 @@ import * as Utils from '@datocms/rest-client-utils'; | ||
} | ||
/** | ||
* Reorders a set of schema menu items | ||
* | ||
* Read more: https://www.datocms.com/docs/content-management-api/resources/schema-menu_item/reorder | ||
* | ||
* @throws {ApiError} | ||
* @throws {TimeoutError} | ||
* | ||
* @deprecated This API call is to be considered private and might change without notice | ||
*/ | ||
reorder(body: SimpleSchemaTypes.SchemaMenuItemReorderSchema) { | ||
return this.rawReorder( | ||
Utils.serializeRequestBody<SchemaTypes.SchemaMenuItemReorderSchema>( | ||
body, | ||
{ | ||
type: 'schema_menu_item', | ||
attributes: [], | ||
relationships: [], | ||
}, | ||
), | ||
).then((body) => | ||
Utils.deserializeResponseBody<SimpleSchemaTypes.SchemaMenuItemReorderJobSchema>( | ||
body, | ||
), | ||
); | ||
} | ||
/** | ||
* Reorders a set of schema menu items | ||
* | ||
* Read more: https://www.datocms.com/docs/content-management-api/resources/schema-menu_item/reorder | ||
* | ||
* @throws {ApiError} | ||
* @throws {TimeoutError} | ||
* | ||
* @deprecated This API call is to be considered private and might change without notice | ||
*/ | ||
rawReorder( | ||
body: SchemaTypes.SchemaMenuItemReorderSchema, | ||
): Promise<SchemaTypes.SchemaMenuItemReorderJobSchema> { | ||
return this.client.request<SchemaTypes.SchemaMenuItemReorderJobSchema>({ | ||
method: 'POST', | ||
url: '/schema-menu-items/reorder', | ||
body, | ||
}); | ||
} | ||
} |
@@ -204,2 +204,49 @@ import * as Utils from '@datocms/rest-client-utils'; | ||
} | ||
/** | ||
* Reorders a set of upload collections | ||
* | ||
* Read more: https://www.datocms.com/docs/content-management-api/resources/upload-collection/reorder | ||
* | ||
* @throws {ApiError} | ||
* @throws {TimeoutError} | ||
* | ||
* @deprecated This API call is to be considered private and might change without notice | ||
*/ | ||
reorder(body: SimpleSchemaTypes.UploadCollectionReorderSchema) { | ||
return this.rawReorder( | ||
Utils.serializeRequestBody<SchemaTypes.UploadCollectionReorderSchema>( | ||
body, | ||
{ | ||
type: 'upload_collection', | ||
attributes: [], | ||
relationships: [], | ||
}, | ||
), | ||
).then((body) => | ||
Utils.deserializeResponseBody<SimpleSchemaTypes.UploadCollectionReorderJobSchema>( | ||
body, | ||
), | ||
); | ||
} | ||
/** | ||
* Reorders a set of upload collections | ||
* | ||
* Read more: https://www.datocms.com/docs/content-management-api/resources/upload-collection/reorder | ||
* | ||
* @throws {ApiError} | ||
* @throws {TimeoutError} | ||
* | ||
* @deprecated This API call is to be considered private and might change without notice | ||
*/ | ||
rawReorder( | ||
body: SchemaTypes.UploadCollectionReorderSchema, | ||
): Promise<SchemaTypes.UploadCollectionReorderJobSchema> { | ||
return this.client.request<SchemaTypes.UploadCollectionReorderJobSchema>({ | ||
method: 'POST', | ||
url: '/upload-collections/reorder', | ||
body, | ||
}); | ||
} | ||
} |
@@ -139,4 +139,4 @@ import * as Utils from '@datocms/rest-client-utils'; | ||
*/ | ||
resendWebhook(userId: string | SimpleSchemaTypes.UserData) { | ||
return this.rawResendWebhook(Utils.toId(userId)); | ||
resendWebhook(webhookCallId: string | SimpleSchemaTypes.WebhookCallData) { | ||
return this.rawResendWebhook(Utils.toId(webhookCallId)); | ||
} | ||
@@ -152,8 +152,8 @@ | ||
*/ | ||
rawResendWebhook(userId: string): Promise<void> { | ||
rawResendWebhook(webhookCallId: string): Promise<void> { | ||
return this.client.request<void>({ | ||
method: 'POST', | ||
url: `/webhook_calls/${userId}/resend_webhook`, | ||
url: `/webhook_calls/${webhookCallId}/resend_webhook`, | ||
}); | ||
} | ||
} |
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is too big to display
Sorry, the diff of this file is too big to display
Sorry, the diff of this file is too big to display
Sorry, the diff of this file is too big to display
Sorry, the diff of this file is too big to display
Sorry, the diff of this file is too big to display
Sorry, the diff of this file is too big to display
3620815
1.39%107146
1.39%