webflow-api 3.1.4 → 3.2.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/.mock/definition/__package__.yml +811 -148
- package/.mock/definition/accessGroups.yml +7 -1
- package/.mock/definition/api.yml +0 -2
- package/.mock/definition/assets.yml +38 -8
- package/.mock/definition/collections/fields.yml +15 -9
- package/.mock/definition/collections/items.yml +740 -266
- package/.mock/definition/collections.yml +140 -14
- package/.mock/definition/comments.yml +40 -0
- package/.mock/definition/components.yml +87 -26
- package/.mock/definition/ecommerce.yml +3 -1
- package/.mock/definition/forms.yml +65 -7
- package/.mock/definition/inventory.yml +44 -16
- package/.mock/definition/items.yml +111 -0
- package/.mock/definition/orders.yml +470 -86
- package/.mock/definition/pages/scripts.yml +27 -8
- package/.mock/definition/pages.yml +172 -63
- package/.mock/definition/products.yml +52 -33
- package/.mock/definition/scripts.yml +13 -3
- package/.mock/definition/sites/activityLogs.yml +6 -1
- package/.mock/definition/sites/comments.yml +39 -14
- package/.mock/definition/sites/plans.yml +3 -1
- package/.mock/definition/sites/redirects.yml +12 -4
- package/.mock/definition/sites/robotsTxt.yml +12 -4
- package/.mock/definition/sites/scripts.yml +35 -8
- package/.mock/definition/sites/wellKnown.yml +20 -4
- package/.mock/definition/sites.yml +56 -14
- package/.mock/definition/token.yml +3 -2
- package/.mock/definition/users.yml +231 -33
- package/.mock/definition/webhooks.yml +0 -4
- package/.mock/definition/workspaces/auditLogs.yml +9 -3
- package/.mock/fern.config.json +1 -1
- package/Client.d.ts +22 -18
- package/Client.js +44 -2
- package/api/errors/BadRequestError.d.ts +2 -1
- package/api/errors/BadRequestError.js +19 -8
- package/api/errors/ConflictError.d.ts +2 -1
- package/api/errors/ConflictError.js +19 -8
- package/api/errors/ForbiddenError.d.ts +2 -1
- package/api/errors/ForbiddenError.js +19 -8
- package/api/errors/InternalServerError.d.ts +2 -1
- package/api/errors/InternalServerError.js +19 -8
- package/api/errors/NotFoundError.d.ts +2 -1
- package/api/errors/NotFoundError.js +19 -8
- package/api/errors/TooManyRequestsError.d.ts +2 -1
- package/api/errors/TooManyRequestsError.js +19 -8
- package/api/errors/UnauthorizedError.d.ts +2 -1
- package/api/errors/UnauthorizedError.js +19 -8
- package/api/resources/accessGroups/client/Client.d.ts +15 -6
- package/api/resources/accessGroups/client/Client.js +62 -31
- package/api/resources/accessGroups/client/index.d.ts +1 -0
- package/api/resources/accessGroups/client/requests/AccessGroupsListRequest.d.ts +5 -1
- package/api/resources/accessGroups/types/AccessGroupsListRequestSort.d.ts +1 -1
- package/api/resources/assets/client/Client.d.ts +29 -13
- package/api/resources/assets/client/Client.js +232 -137
- package/api/resources/assets/client/index.d.ts +1 -0
- package/api/resources/assets/client/requests/AssetsListRequest.d.ts +20 -0
- package/api/resources/assets/client/requests/index.d.ts +1 -0
- package/api/resources/collections/client/Client.d.ts +23 -13
- package/api/resources/collections/client/Client.js +127 -79
- package/api/resources/collections/client/index.d.ts +1 -0
- package/api/resources/collections/resources/fields/client/Client.d.ts +20 -11
- package/api/resources/collections/resources/fields/client/Client.js +98 -56
- package/api/resources/collections/resources/fields/client/index.d.ts +1 -0
- package/api/resources/collections/resources/index.js +17 -7
- package/api/resources/collections/resources/items/client/Client.d.ts +174 -86
- package/api/resources/collections/resources/items/client/Client.js +631 -330
- package/api/resources/collections/resources/items/client/index.d.ts +1 -0
- package/api/resources/collections/resources/items/client/requests/CreateBulkCollectionItemRequestBody.d.ts +8 -0
- package/api/resources/collections/resources/items/client/requests/ItemsCreateItemLiveRequest.d.ts +47 -0
- package/api/resources/collections/resources/items/client/requests/ItemsCreateItemRequest.d.ts +47 -0
- package/api/resources/collections/resources/items/client/requests/ItemsDeleteItemLiveRequest.d.ts +3 -1
- package/api/resources/collections/resources/items/client/requests/ItemsDeleteItemRequest.d.ts +3 -1
- package/api/resources/collections/resources/items/client/requests/ItemsGetItemLiveRequest.d.ts +3 -1
- package/api/resources/collections/resources/items/client/requests/ItemsGetItemRequest.d.ts +3 -1
- package/api/resources/collections/resources/items/client/requests/ItemsListItemsLiveRequest.d.ts +13 -1
- package/api/resources/collections/resources/items/client/requests/ItemsListItemsRequest.d.ts +13 -1
- package/api/resources/collections/resources/items/client/requests/ItemsUpdateItemLiveRequest.d.ts +25 -0
- package/api/resources/collections/resources/items/client/requests/ItemsUpdateItemRequest.d.ts +25 -0
- package/api/resources/collections/resources/items/client/requests/ItemsUpdateItemsLiveRequest.d.ts +8 -0
- package/api/resources/collections/resources/items/client/requests/ItemsUpdateItemsRequest.d.ts +6 -66
- package/api/resources/collections/resources/items/client/requests/index.d.ts +4 -1
- package/api/resources/collections/resources/items/types/CreateBulkCollectionItemRequestBodyFieldData.d.ts +1 -1
- package/api/resources/collections/resources/items/types/ItemIDs.d.ts +9 -0
- package/api/resources/collections/resources/items/types/ItemIDsWithLocales.d.ts +10 -0
- package/{dist/api/resources/collections/resources/items/types/ItemsCreateItemLiveRequest.d.ts → api/resources/collections/resources/items/types/ItemsCreateItemLiveRequestBody.d.ts} +1 -1
- package/api/resources/collections/resources/items/types/{ItemsCreateItemLiveRequest.d.ts → ItemsCreateItemRequestBody.d.ts} +1 -1
- package/api/resources/collections/resources/items/types/ItemsListItemsLiveRequestSortBy.d.ts +1 -1
- package/api/resources/collections/resources/items/types/ItemsListItemsLiveRequestSortOrder.d.ts +1 -1
- package/api/resources/collections/resources/items/types/ItemsListItemsRequestSortBy.d.ts +1 -1
- package/api/resources/collections/resources/items/types/ItemsListItemsRequestSortOrder.d.ts +1 -1
- package/api/resources/collections/resources/items/types/ItemsPublishItemRequest.d.ts +11 -0
- package/api/resources/collections/resources/items/types/ItemsPublishItemRequestItemsItemsItem.d.ts +9 -0
- package/api/resources/collections/resources/items/types/{ItemsCreateItemRequest.d.ts → ItemsUpdateItemsResponse.d.ts} +1 -1
- package/api/resources/collections/resources/items/types/index.d.ts +7 -2
- package/api/resources/collections/resources/items/types/index.js +7 -2
- package/api/resources/components/client/Client.d.ts +39 -15
- package/api/resources/components/client/Client.js +194 -105
- package/api/resources/components/client/index.d.ts +1 -0
- package/api/resources/components/client/requests/ComponentDomWrite.d.ts +8 -1
- package/api/resources/components/client/requests/ComponentPropertiesWrite.d.ts +8 -1
- package/api/resources/components/client/requests/ComponentsGetContentRequest.d.ts +11 -2
- package/api/resources/components/client/requests/ComponentsGetPropertiesRequest.d.ts +11 -2
- package/api/resources/components/client/requests/ComponentsListRequest.d.ts +9 -1
- package/api/resources/components/types/ComponentDomWriteNodesItem.d.ts +1 -1
- package/api/resources/ecommerce/client/Client.d.ts +10 -5
- package/api/resources/ecommerce/client/Client.js +51 -28
- package/api/resources/forms/client/Client.d.ts +33 -14
- package/api/resources/forms/client/Client.js +215 -137
- package/api/resources/forms/client/index.d.ts +1 -0
- package/api/resources/forms/client/requests/FormsListRequest.d.ts +4 -1
- package/api/resources/forms/client/requests/FormsListSubmissionsBySiteRequest.d.ts +3 -1
- package/api/resources/forms/client/requests/FormsListSubmissionsRequest.d.ts +4 -1
- package/api/resources/index.js +17 -7
- package/api/resources/inventory/client/Client.d.ts +18 -12
- package/api/resources/inventory/client/Client.js +88 -55
- package/api/resources/inventory/client/index.d.ts +1 -0
- package/api/resources/inventory/types/EcommInventoryChangedPayload.d.ts +8 -0
- package/api/resources/inventory/types/InventoryUpdateRequestInventoryType.d.ts +1 -1
- package/api/resources/inventory/types/index.d.ts +1 -0
- package/api/resources/inventory/types/index.js +1 -0
- package/api/resources/orders/client/Client.d.ts +25 -11
- package/api/resources/orders/client/Client.js +201 -124
- package/api/resources/orders/client/index.d.ts +1 -0
- package/api/resources/orders/client/requests/OrdersListRequest.d.ts +5 -1
- package/api/resources/orders/types/OrdersListRequestStatus.d.ts +1 -1
- package/api/resources/orders/types/OrdersRefundRequestReason.d.ts +1 -1
- package/api/resources/pages/client/Client.d.ts +43 -47
- package/api/resources/pages/client/Client.js +185 -139
- package/api/resources/pages/client/index.d.ts +1 -0
- package/api/resources/pages/client/requests/PageMetadataWrite.d.ts +43 -0
- package/api/resources/pages/client/requests/PagesGetContentRequest.d.ts +6 -2
- package/api/resources/pages/client/requests/PagesGetMetadataRequest.d.ts +3 -1
- package/api/resources/pages/client/requests/PagesListRequest.d.ts +6 -2
- package/api/resources/pages/client/requests/index.d.ts +1 -1
- package/api/resources/pages/resources/index.js +17 -7
- package/api/resources/pages/resources/scripts/client/Client.d.ts +19 -10
- package/api/resources/pages/resources/scripts/client/Client.js +96 -56
- package/api/resources/pages/types/PageDomWriteNodesItem.d.ts +1 -1
- package/api/resources/pages/types/PageMetadataWriteOpenGraph.d.ts +16 -0
- package/api/resources/pages/types/PageMetadataWriteOpenGraph.js +5 -0
- package/api/resources/pages/types/PageMetadataWriteSeo.d.ts +12 -0
- package/api/resources/pages/types/PageMetadataWriteSeo.js +5 -0
- package/api/resources/pages/types/index.d.ts +2 -0
- package/api/resources/pages/types/index.js +2 -0
- package/api/resources/products/client/Client.d.ts +36 -13
- package/api/resources/products/client/Client.js +204 -120
- package/api/resources/products/client/index.d.ts +1 -0
- package/api/resources/products/client/requests/ProductSkuCreate.d.ts +2 -2
- package/api/resources/products/client/requests/ProductsCreateSkuRequest.d.ts +5 -0
- package/api/resources/products/client/requests/ProductsListRequest.d.ts +4 -1
- package/api/resources/products/client/requests/ProductsUpdateSkuRequest.d.ts +5 -0
- package/api/resources/products/types/ProductsCreateSkuResponse.d.ts +1 -1
- package/api/resources/scripts/client/Client.d.ts +14 -7
- package/api/resources/scripts/client/Client.js +99 -56
- package/api/resources/scripts/client/index.d.ts +1 -0
- package/api/resources/sites/client/Client.d.ts +43 -27
- package/api/resources/sites/client/Client.js +228 -149
- package/api/resources/sites/client/index.d.ts +1 -0
- package/api/resources/sites/client/requests/SitesPublishRequest.d.ts +4 -1
- package/api/resources/sites/resources/activityLogs/client/Client.d.ts +14 -6
- package/api/resources/sites/resources/activityLogs/client/Client.js +53 -27
- package/api/resources/sites/resources/activityLogs/client/index.d.ts +1 -0
- package/api/resources/sites/resources/activityLogs/client/requests/ActivityLogsListRequest.d.ts +4 -1
- package/api/resources/sites/resources/comments/client/Client.d.ts +29 -10
- package/api/resources/sites/resources/comments/client/Client.js +148 -73
- package/api/resources/sites/resources/comments/client/index.d.ts +1 -0
- package/api/resources/sites/resources/comments/client/requests/CommentsGetCommentThreadRequest.d.ts +8 -2
- package/api/resources/sites/resources/comments/client/requests/CommentsListCommentRepliesRequest.d.ts +8 -2
- package/api/resources/sites/resources/comments/client/requests/CommentsListCommentThreadsRequest.d.ts +8 -2
- package/api/resources/sites/resources/comments/types/CommentsGetCommentThreadRequestSortBy.d.ts +1 -1
- package/api/resources/sites/resources/comments/types/CommentsGetCommentThreadRequestSortOrder.d.ts +1 -1
- package/api/resources/sites/resources/comments/types/CommentsListCommentRepliesRequestSortBy.d.ts +1 -1
- package/api/resources/sites/resources/comments/types/CommentsListCommentRepliesRequestSortOrder.d.ts +1 -1
- package/api/resources/sites/resources/comments/types/CommentsListCommentThreadsRequestSortBy.d.ts +1 -1
- package/api/resources/sites/resources/comments/types/CommentsListCommentThreadsRequestSortOrder.d.ts +1 -1
- package/api/resources/sites/resources/index.js +17 -7
- package/api/resources/sites/resources/plans/client/Client.d.ts +10 -5
- package/api/resources/sites/resources/plans/client/Client.js +49 -26
- package/api/resources/sites/resources/redirects/client/Client.d.ts +16 -8
- package/api/resources/sites/resources/redirects/client/Client.js +124 -73
- package/api/resources/sites/resources/robotsTxt/client/Client.d.ts +16 -8
- package/api/resources/sites/resources/robotsTxt/client/Client.js +124 -71
- package/api/resources/sites/resources/scripts/client/Client.d.ts +26 -11
- package/api/resources/sites/resources/scripts/client/Client.js +126 -73
- package/api/resources/sites/resources/scripts/client/index.d.ts +1 -0
- package/api/resources/sites/resources/scripts/client/requests/ScriptsListCustomCodeBlocksRequest.d.ts +4 -1
- package/api/resources/sites/resources/wellKnown/client/Client.d.ts +15 -8
- package/api/resources/sites/resources/wellKnown/client/Client.js +60 -30
- package/api/resources/sites/resources/wellKnown/client/index.d.ts +1 -0
- package/api/resources/sites/resources/wellKnown/client/requests/WellKnownFile.d.ts +3 -2
- package/api/resources/sites/resources/wellKnown/types/WellKnownFileContentType.d.ts +1 -1
- package/api/resources/token/client/Client.d.ts +12 -6
- package/api/resources/token/client/Client.js +67 -36
- package/api/resources/users/client/Client.d.ts +36 -18
- package/api/resources/users/client/Client.js +173 -104
- package/api/resources/users/client/index.d.ts +1 -0
- package/api/resources/users/client/requests/UsersInviteRequest.d.ts +1 -1
- package/api/resources/users/client/requests/UsersListRequest.d.ts +5 -1
- package/api/resources/users/client/requests/index.d.ts +0 -1
- package/api/resources/users/types/UserAccountAddedPayload.d.ts +8 -0
- package/api/resources/users/types/UserAccountAddedPayload.js +5 -0
- package/api/resources/users/types/UserAccountAddedPayloadPayload.d.ts +23 -0
- package/api/resources/users/types/UserAccountAddedPayloadPayload.js +5 -0
- package/api/resources/users/types/UserAccountAddedPayloadPayloadData.d.ts +12 -0
- package/api/resources/users/types/UserAccountAddedPayloadPayloadData.js +5 -0
- package/api/resources/users/types/UserAccountDeletedPayload.d.ts +8 -0
- package/api/resources/users/types/UserAccountDeletedPayload.js +5 -0
- package/api/resources/users/types/UserAccountDeletedPayloadPayload.d.ts +23 -0
- package/api/resources/users/types/UserAccountDeletedPayloadPayload.js +5 -0
- package/api/resources/users/types/UserAccountDeletedPayloadPayloadData.d.ts +12 -0
- package/api/resources/users/types/UserAccountDeletedPayloadPayloadData.js +5 -0
- package/api/resources/users/types/UserAccountUpdatedPayload.d.ts +8 -0
- package/api/resources/users/types/UserAccountUpdatedPayload.js +5 -0
- package/api/resources/users/types/UserAccountUpdatedPayloadPayload.d.ts +23 -0
- package/api/resources/users/types/UserAccountUpdatedPayloadPayload.js +5 -0
- package/api/resources/users/types/UserAccountUpdatedPayloadPayloadData.d.ts +12 -0
- package/api/resources/users/types/UserAccountUpdatedPayloadPayloadData.js +5 -0
- package/api/resources/users/types/UsersListRequestSort.d.ts +1 -1
- package/api/resources/users/types/index.d.ts +9 -1
- package/api/resources/users/types/index.js +9 -1
- package/api/resources/webhooks/client/Client.d.ts +18 -10
- package/api/resources/webhooks/client/Client.js +117 -71
- package/api/resources/workspaces/client/Client.d.ts +6 -12
- package/api/resources/workspaces/client/Client.js +1 -1
- package/api/resources/workspaces/resources/auditLogs/client/Client.d.ts +16 -7
- package/api/resources/workspaces/resources/auditLogs/client/Client.js +69 -32
- package/api/resources/workspaces/resources/auditLogs/client/index.d.ts +1 -0
- package/api/resources/workspaces/resources/auditLogs/client/requests/AuditLogsGetWorkspaceAuditLogsRequest.d.ts +6 -2
- package/api/resources/workspaces/resources/auditLogs/types/AuditLogsGetWorkspaceAuditLogsRequestEventType.d.ts +1 -1
- package/api/resources/workspaces/resources/auditLogs/types/AuditLogsGetWorkspaceAuditLogsRequestSortOrder.d.ts +1 -1
- package/api/resources/workspaces/resources/index.js +17 -7
- package/api/types/Application.d.ts +10 -1
- package/api/types/Asset.d.ts +2 -2
- package/api/types/AssetVariant.d.ts +6 -6
- package/api/types/Authorization.d.ts +1 -1
- package/api/types/BadRequestErrorBody.d.ts +1 -1
- package/api/types/BulkCollectionItem.d.ts +1 -1
- package/api/types/Collection.d.ts +2 -2
- package/api/types/CollectionItemChanged.d.ts +12 -0
- package/api/types/CollectionItemChanged.js +5 -0
- package/api/types/CollectionItemCreated.d.ts +12 -0
- package/api/types/CollectionItemCreated.js +5 -0
- package/api/types/CollectionItemPublished.d.ts +9 -0
- package/api/types/CollectionItemPublished.js +5 -0
- package/api/types/CollectionItemRemoved.d.ts +10 -0
- package/api/types/CollectionItemRemoved.js +5 -0
- package/api/types/CollectionItemRemovedPayload.d.ts +25 -0
- package/api/types/CollectionItemRemovedPayload.js +5 -0
- package/api/types/CollectionItemRemovedPayloadFieldData.d.ts +9 -0
- package/api/types/CollectionItemRemovedPayloadFieldData.js +5 -0
- package/api/types/CollectionItemUnpublished.d.ts +10 -0
- package/api/types/CollectionItemUnpublished.js +5 -0
- package/api/types/CollectionItemUnpublishedPayload.d.ts +25 -0
- package/api/types/CollectionItemUnpublishedPayload.js +5 -0
- package/api/types/CollectionItemUnpublishedPayloadFieldData.d.ts +9 -0
- package/api/types/CollectionItemUnpublishedPayloadFieldData.js +5 -0
- package/api/types/Comment.d.ts +12 -0
- package/api/types/Comment.js +5 -0
- package/api/types/CommentPayload.d.ts +38 -0
- package/api/types/CommentPayload.js +5 -0
- package/api/types/CommentPayloadAuthor.d.ts +11 -0
- package/api/types/CommentPayloadAuthor.js +5 -0
- package/api/types/CommentPayloadMentionedUsersItem.d.ts +11 -0
- package/api/types/CommentPayloadMentionedUsersItem.js +5 -0
- package/api/types/CommentReply.d.ts +2 -2
- package/api/types/ComponentNode.d.ts +3 -3
- package/api/types/ComponentPropertyType.d.ts +1 -1
- package/api/types/Conflict.d.ts +1 -1
- package/api/types/ConflictErrorBody.d.ts +1 -1
- package/api/types/CustomCodeBlockType.d.ts +1 -1
- package/api/types/CustomRoleAuditLogItemEventSubType.d.ts +1 -1
- package/api/types/Dom.d.ts +2 -0
- package/api/types/DuplicateUserEmail.d.ts +1 -1
- package/api/types/ErrorCode.d.ts +1 -1
- package/api/types/Field.d.ts +2 -0
- package/api/types/FieldCreate.d.ts +1 -1
- package/api/types/FieldType.d.ts +1 -1
- package/api/types/FieldValidations.d.ts +10 -0
- package/api/types/FieldValidations.js +5 -0
- package/api/types/FieldValidationsAdditionalProperties.d.ts +5 -0
- package/api/types/FieldValidationsAdditionalProperties.js +5 -0
- package/api/types/FieldValidationsAdditionalPropertiesAdditionalProperties.d.ts +6 -0
- package/api/types/FieldValidationsAdditionalPropertiesAdditionalProperties.js +5 -0
- package/api/types/ForbiddenErrorBody.d.ts +1 -1
- package/api/types/FormField.d.ts +1 -1
- package/api/types/FormFieldValueType.d.ts +1 -1
- package/api/types/FormSubmissionTrigger.d.ts +13 -0
- package/api/types/FormSubmissionTrigger.js +5 -0
- package/api/types/FormSubmissionTriggerPayload.d.ts +25 -0
- package/api/types/FormSubmissionTriggerPayload.js +5 -0
- package/api/types/FormSubmissionTriggerPayloadSchemaItem.d.ts +12 -0
- package/api/types/FormSubmissionTriggerPayloadSchemaItem.js +5 -0
- package/api/types/FormSubmissionTriggerPayloadSchemaItemFieldType.d.ts +14 -0
- package/api/types/FormSubmissionTriggerPayloadSchemaItemFieldType.js +13 -0
- package/api/types/ImageNode.d.ts +2 -2
- package/api/types/InvalidDomain.d.ts +1 -1
- package/api/types/InvalidScopes.d.ts +1 -1
- package/api/types/InventoryItemInventoryType.d.ts +1 -1
- package/api/types/ItemsListItemsLiveRequestLastPublished.d.ts +9 -0
- package/api/types/ItemsListItemsLiveRequestLastPublished.js +5 -0
- package/api/types/ItemsListItemsRequestLastPublished.d.ts +9 -0
- package/api/types/ItemsListItemsRequestLastPublished.js +5 -0
- package/api/types/NewOrder.d.ts +12 -0
- package/api/types/NewOrder.js +5 -0
- package/api/types/NoDomains.d.ts +1 -1
- package/api/types/Node.d.ts +1 -1
- package/api/types/NotEnterprisePlanSite.d.ts +1 -1
- package/api/types/NotEnterprisePlanWorkspace.d.ts +1 -1
- package/api/types/OAuthScope.d.ts +1 -1
- package/api/types/Order.d.ts +2 -2
- package/api/types/OrderAddressJapanType.d.ts +1 -1
- package/api/types/OrderAddressType.d.ts +1 -1
- package/api/types/OrderBillingAddress.d.ts +27 -0
- package/api/types/OrderBillingAddress.js +5 -0
- package/api/types/OrderBillingAddressJapanType.d.ts +11 -0
- package/api/types/OrderBillingAddressJapanType.js +10 -0
- package/api/types/OrderBillingAddressType.d.ts +11 -0
- package/api/types/OrderBillingAddressType.js +10 -0
- package/api/types/OrderDisputeLastStatus.d.ts +1 -1
- package/api/types/OrderShippingAddress.d.ts +27 -0
- package/api/types/OrderShippingAddress.js +5 -0
- package/api/types/OrderShippingAddressJapanType.d.ts +11 -0
- package/api/types/OrderShippingAddressJapanType.js +10 -0
- package/api/types/OrderShippingAddressType.d.ts +11 -0
- package/api/types/OrderShippingAddressType.js +10 -0
- package/api/types/OrderStatus.d.ts +1 -1
- package/api/types/OrderTotalsExtrasItemType.d.ts +1 -1
- package/api/types/Page.d.ts +3 -1
- package/api/types/PageCreatedWebhook.d.ts +13 -0
- package/api/types/PageCreatedWebhook.js +5 -0
- package/api/types/PageCreatedWebhookPayload.d.ts +13 -0
- package/api/types/PageCreatedWebhookPayload.js +5 -0
- package/api/types/PageDeletedWebhook.d.ts +13 -0
- package/api/types/PageDeletedWebhook.js +5 -0
- package/api/types/PageDeletedWebhookPayload.d.ts +13 -0
- package/api/types/PageDeletedWebhookPayload.js +5 -0
- package/api/types/PageMetadataUpdatedWebhook.d.ts +13 -0
- package/api/types/PageMetadataUpdatedWebhook.js +5 -0
- package/api/types/PageMetadataUpdatedWebhookPayload.d.ts +13 -0
- package/api/types/PageMetadataUpdatedWebhookPayload.js +5 -0
- package/api/types/Payload.d.ts +25 -0
- package/api/types/Payload.js +5 -0
- package/api/types/PayloadFieldData.d.ts +9 -0
- package/api/types/PayloadFieldData.js +5 -0
- package/api/types/ProductFieldData.d.ts +2 -2
- package/api/types/ProductFieldDataEcProductType.d.ts +1 -1
- package/api/types/ProductFieldDataTaxCategory.d.ts +1 -1
- package/api/types/PublishStatus.d.ts +1 -1
- package/api/types/ReferenceFieldType.d.ts +1 -1
- package/api/types/RegisteredScriptList.d.ts +1 -0
- package/api/types/ScriptApplyLocation.d.ts +1 -1
- package/api/types/Scripts.d.ts +1 -1
- package/{dist/api/types/SelectNodeWrite.d.ts → api/types/Select.d.ts} +1 -1
- package/api/types/Select.js +5 -0
- package/api/types/SingleLocaleCreatedPayload.d.ts +22 -0
- package/api/types/SingleLocaleCreatedPayload.js +5 -0
- package/api/types/SingleLocaleCreatedPayloadFieldData.d.ts +9 -0
- package/api/types/SingleLocaleCreatedPayloadFieldData.js +5 -0
- package/api/types/SiteActivityLogItemEvent.d.ts +1 -1
- package/api/types/SiteActivityLogItemResourceOperation.d.ts +1 -1
- package/api/types/SiteDataCollectionType.d.ts +1 -1
- package/api/types/SiteMembership.d.ts +1 -0
- package/api/types/SiteMembershipAuditLogItemEventSubType.d.ts +2 -1
- package/api/types/SiteMembershipAuditLogItemEventSubType.js +1 -0
- package/api/types/SitePlanId.d.ts +1 -1
- package/api/types/SitePlanName.d.ts +1 -1
- package/api/types/SitePublish.d.ts +13 -0
- package/api/types/SitePublish.js +5 -0
- package/api/types/SitePublishPayload.d.ts +16 -0
- package/api/types/SitePublishPayload.js +5 -0
- package/api/types/SkuFieldData.d.ts +0 -4
- package/api/types/SkuFieldDataEcSkuBillingMethod.d.ts +1 -1
- package/api/types/SkuFieldDataEcSkuSubscriptionPlanInterval.d.ts +1 -1
- package/api/types/SkuFieldDataEcSkuSubscriptionPlanPlansItemStatus.d.ts +1 -1
- package/api/types/SkuValueList.d.ts +1 -1
- package/api/types/StaticFieldType.d.ts +1 -1
- package/api/types/StripeCardBrand.d.ts +1 -1
- package/api/types/TextNode.d.ts +2 -2
- package/api/types/TriggerType.d.ts +2 -1
- package/api/types/TriggerType.js +1 -0
- package/api/types/UpdatedOrder.d.ts +12 -0
- package/api/types/UpdatedOrder.js +5 -0
- package/api/types/User.d.ts +0 -1
- package/api/types/UserAccessAuditLogItemEventSubType.d.ts +1 -1
- package/api/types/UserAccessGroupsItemType.d.ts +1 -1
- package/api/types/UserLimitReached.d.ts +1 -1
- package/api/types/UserStatus.d.ts +1 -1
- package/api/types/UsersNotEnabled.d.ts +1 -1
- package/api/types/WorkspaceAuditLogItem.d.ts +1 -1
- package/api/types/WorkspaceAuditLogItemPayloadSiteMembershipGranularAccess.d.ts +9 -0
- package/api/types/WorkspaceAuditLogItemPayloadSiteMembershipGranularAccess.js +5 -0
- package/api/types/WorkspaceAuditLogItemPayloadSiteMembershipMethod.d.ts +2 -1
- package/api/types/WorkspaceAuditLogItemPayloadSiteMembershipMethod.js +1 -0
- package/api/types/WorkspaceAuditLogItemPayloadSiteMembershipUserType.d.ts +1 -1
- package/api/types/WorkspaceAuditLogItemPayloadUserAccessMethod.d.ts +1 -1
- package/api/types/WorkspaceAuditLogItemPayloadWorkspaceInvitationMethod.d.ts +1 -1
- package/api/types/WorkspaceAuditLogItemPayloadWorkspaceInvitationTargetUsersItem.d.ts +7 -0
- package/api/types/WorkspaceAuditLogItemPayloadWorkspaceInvitationTargetUsersItem.js +5 -0
- package/api/types/WorkspaceAuditLogItemPayloadWorkspaceInvitationUserType.d.ts +1 -1
- package/api/types/WorkspaceAuditLogItemPayloadWorkspaceMembershipMethod.d.ts +2 -1
- package/api/types/WorkspaceAuditLogItemPayloadWorkspaceMembershipMethod.js +1 -0
- package/api/types/WorkspaceAuditLogItemPayloadWorkspaceMembershipUserType.d.ts +1 -1
- package/api/types/WorkspaceInvitation.d.ts +1 -0
- package/api/types/WorkspaceInvitationAuditLogItemEventSubType.d.ts +2 -1
- package/api/types/WorkspaceInvitationAuditLogItemEventSubType.js +1 -0
- package/api/types/WorkspaceMembershipAuditLogItemEventSubType.d.ts +1 -1
- package/api/types/index.d.ts +47 -3
- package/api/types/index.js +47 -3
- package/core/auth/BearerToken.d.ts +1 -1
- package/core/fetcher/APIResponse.d.ts +11 -1
- package/core/fetcher/Fetcher.d.ts +4 -3
- package/core/fetcher/Fetcher.js +35 -14
- package/core/fetcher/Headers.d.ts +2 -0
- package/core/fetcher/Headers.js +84 -0
- package/core/fetcher/HttpResponsePromise.d.ts +58 -0
- package/core/fetcher/HttpResponsePromise.js +103 -0
- package/core/fetcher/RawResponse.d.ts +29 -0
- package/core/fetcher/RawResponse.js +44 -0
- package/core/fetcher/Supplier.d.ts +1 -1
- package/core/fetcher/createRequestUrl.d.ts +1 -1
- package/core/fetcher/createRequestUrl.js +1 -2
- package/core/fetcher/getFetchFn.js +18 -9
- package/core/fetcher/getHeader.js +1 -2
- package/core/fetcher/getRequestBody.js +5 -5
- package/core/fetcher/getResponseBody.js +1 -2
- package/core/fetcher/index.d.ts +3 -0
- package/core/fetcher/index.js +7 -1
- package/core/fetcher/makeRequest.d.ts +1 -1
- package/core/fetcher/requestWithRetries.js +4 -5
- package/core/fetcher/signals.d.ts +0 -1
- package/core/fetcher/signals.js +2 -3
- package/core/fetcher/stream-wrappers/NodePre18StreamWrapper.d.ts +0 -1
- package/core/fetcher/stream-wrappers/NodePre18StreamWrapper.js +6 -4
- package/core/fetcher/stream-wrappers/UndiciStreamWrapper.d.ts +1 -1
- package/core/fetcher/stream-wrappers/chooseStreamWrapper.d.ts +1 -1
- package/core/fetcher/stream-wrappers/chooseStreamWrapper.js +18 -9
- package/core/headers.d.ts +3 -0
- package/core/headers.js +29 -0
- package/core/index.d.ts +1 -1
- package/core/index.js +18 -8
- package/core/json.d.ts +15 -0
- package/core/json.js +24 -0
- package/core/runtime/runtime.d.ts +1 -1
- package/core/runtime/runtime.js +50 -41
- package/core/schemas/Schema.d.ts +7 -5
- package/core/schemas/Schema.js +2 -0
- package/core/schemas/builders/bigint/bigint.d.ts +1 -1
- package/core/schemas/builders/bigint/bigint.js +22 -19
- package/core/schemas/builders/date/date.js +1 -2
- package/core/schemas/builders/enum/enum.js +1 -2
- package/core/schemas/builders/lazy/lazy.d.ts +1 -1
- package/core/schemas/builders/lazy/lazy.js +3 -4
- package/core/schemas/builders/lazy/lazyObject.js +1 -2
- package/core/schemas/builders/list/list.js +1 -2
- package/core/schemas/builders/literals/booleanLiteral.js +1 -2
- package/core/schemas/builders/literals/stringLiteral.js +1 -2
- package/core/schemas/builders/object/object.d.ts +1 -1
- package/core/schemas/builders/object/object.js +3 -3
- package/core/schemas/builders/object/objectWithoutOptionalProperties.d.ts +3 -3
- package/core/schemas/builders/object/objectWithoutOptionalProperties.js +1 -2
- package/core/schemas/builders/object/property.js +2 -3
- package/core/schemas/builders/object/types.d.ts +11 -11
- package/core/schemas/builders/object-like/getObjectLikeUtils.js +2 -3
- package/core/schemas/builders/object-like/types.d.ts +1 -1
- package/core/schemas/builders/record/record.js +2 -4
- package/core/schemas/builders/record/types.d.ts +2 -2
- package/core/schemas/builders/schema-utils/getSchemaUtils.d.ts +4 -0
- package/core/schemas/builders/schema-utils/getSchemaUtils.js +67 -4
- package/core/schemas/builders/schema-utils/stringifyValidationErrors.js +1 -2
- package/core/schemas/builders/set/set.js +1 -2
- package/core/schemas/builders/undiscriminated-union/types.d.ts +4 -4
- package/core/schemas/builders/undiscriminated-union/undiscriminatedUnion.js +1 -2
- package/core/schemas/builders/union/discriminant.js +1 -2
- package/core/schemas/builders/union/types.d.ts +6 -6
- package/core/schemas/builders/union/union.d.ts +1 -1
- package/core/schemas/builders/union/union.js +1 -2
- package/core/schemas/utils/MaybePromise.d.ts +1 -1
- package/core/schemas/utils/addQuestionMarksToNullableProperties.d.ts +4 -4
- package/core/schemas/utils/createIdentitySchemaCreator.js +1 -2
- package/core/schemas/utils/entries.d.ts +1 -1
- package/core/schemas/utils/entries.js +1 -2
- package/core/schemas/utils/filterObject.d.ts +1 -1
- package/core/schemas/utils/filterObject.js +1 -2
- package/core/schemas/utils/getErrorMessageForIncorrectType.js +1 -2
- package/core/schemas/utils/isPlainObject.js +1 -2
- package/core/schemas/utils/keys.d.ts +1 -1
- package/core/schemas/utils/keys.js +1 -2
- package/core/schemas/utils/maybeSkipValidation.js +1 -2
- package/core/schemas/utils/partition.js +1 -2
- package/dist/Client.d.ts +22 -18
- package/dist/Client.js +44 -2
- package/dist/api/errors/BadRequestError.d.ts +2 -1
- package/dist/api/errors/BadRequestError.js +19 -8
- package/dist/api/errors/ConflictError.d.ts +2 -1
- package/dist/api/errors/ConflictError.js +19 -8
- package/dist/api/errors/ForbiddenError.d.ts +2 -1
- package/dist/api/errors/ForbiddenError.js +19 -8
- package/dist/api/errors/InternalServerError.d.ts +2 -1
- package/dist/api/errors/InternalServerError.js +19 -8
- package/dist/api/errors/NotFoundError.d.ts +2 -1
- package/dist/api/errors/NotFoundError.js +19 -8
- package/dist/api/errors/TooManyRequestsError.d.ts +2 -1
- package/dist/api/errors/TooManyRequestsError.js +19 -8
- package/dist/api/errors/UnauthorizedError.d.ts +2 -1
- package/dist/api/errors/UnauthorizedError.js +19 -8
- package/dist/api/resources/accessGroups/client/Client.d.ts +15 -6
- package/dist/api/resources/accessGroups/client/Client.js +62 -31
- package/dist/api/resources/accessGroups/client/index.d.ts +1 -0
- package/dist/api/resources/accessGroups/client/requests/AccessGroupsListRequest.d.ts +5 -1
- package/dist/api/resources/accessGroups/types/AccessGroupsListRequestSort.d.ts +1 -1
- package/dist/api/resources/assets/client/Client.d.ts +29 -13
- package/dist/api/resources/assets/client/Client.js +232 -137
- package/dist/api/resources/assets/client/index.d.ts +1 -0
- package/dist/api/resources/assets/client/requests/AssetsListRequest.d.ts +20 -0
- package/dist/api/resources/assets/client/requests/AssetsListRequest.js +5 -0
- package/dist/api/resources/assets/client/requests/index.d.ts +1 -0
- package/dist/api/resources/collections/client/Client.d.ts +23 -13
- package/dist/api/resources/collections/client/Client.js +127 -79
- package/dist/api/resources/collections/client/index.d.ts +1 -0
- package/dist/api/resources/collections/resources/fields/client/Client.d.ts +20 -11
- package/dist/api/resources/collections/resources/fields/client/Client.js +98 -56
- package/dist/api/resources/collections/resources/fields/client/index.d.ts +1 -0
- package/dist/api/resources/collections/resources/index.js +17 -7
- package/dist/api/resources/collections/resources/items/client/Client.d.ts +174 -86
- package/dist/api/resources/collections/resources/items/client/Client.js +631 -330
- package/dist/api/resources/collections/resources/items/client/index.d.ts +1 -0
- package/dist/api/resources/collections/resources/items/client/requests/CreateBulkCollectionItemRequestBody.d.ts +8 -0
- package/dist/api/resources/collections/resources/items/client/requests/ItemsCreateItemLiveRequest.d.ts +47 -0
- package/dist/api/resources/collections/resources/items/client/requests/ItemsCreateItemLiveRequest.js +5 -0
- package/dist/api/resources/collections/resources/items/client/requests/ItemsCreateItemRequest.d.ts +47 -0
- package/dist/api/resources/collections/resources/items/client/requests/ItemsCreateItemRequest.js +5 -0
- package/dist/api/resources/collections/resources/items/client/requests/ItemsDeleteItemLiveRequest.d.ts +3 -1
- package/dist/api/resources/collections/resources/items/client/requests/ItemsDeleteItemRequest.d.ts +3 -1
- package/dist/api/resources/collections/resources/items/client/requests/ItemsGetItemLiveRequest.d.ts +3 -1
- package/dist/api/resources/collections/resources/items/client/requests/ItemsGetItemRequest.d.ts +3 -1
- package/dist/api/resources/collections/resources/items/client/requests/ItemsListItemsLiveRequest.d.ts +13 -1
- package/dist/api/resources/collections/resources/items/client/requests/ItemsListItemsRequest.d.ts +13 -1
- package/dist/api/resources/collections/resources/items/client/requests/ItemsUpdateItemLiveRequest.d.ts +25 -0
- package/dist/api/resources/collections/resources/items/client/requests/ItemsUpdateItemLiveRequest.js +5 -0
- package/dist/api/resources/collections/resources/items/client/requests/ItemsUpdateItemRequest.d.ts +25 -0
- package/dist/api/resources/collections/resources/items/client/requests/ItemsUpdateItemRequest.js +5 -0
- package/dist/api/resources/collections/resources/items/client/requests/ItemsUpdateItemsLiveRequest.d.ts +8 -0
- package/dist/api/resources/collections/resources/items/client/requests/ItemsUpdateItemsRequest.d.ts +6 -66
- package/dist/api/resources/collections/resources/items/client/requests/index.d.ts +4 -1
- package/dist/api/resources/collections/resources/items/types/CreateBulkCollectionItemRequestBodyFieldData.d.ts +1 -1
- package/dist/api/resources/collections/resources/items/types/ItemIDs.d.ts +9 -0
- package/dist/api/resources/collections/resources/items/types/ItemIDs.js +5 -0
- package/dist/api/resources/collections/resources/items/types/ItemIDsWithLocales.d.ts +10 -0
- package/dist/api/resources/collections/resources/items/types/ItemIDsWithLocales.js +5 -0
- package/dist/api/resources/collections/resources/items/types/{ItemsCreateItemRequest.d.ts → ItemsCreateItemLiveRequestBody.d.ts} +1 -1
- package/dist/api/resources/collections/resources/items/types/ItemsCreateItemLiveRequestBody.js +5 -0
- package/dist/api/resources/collections/resources/items/types/ItemsCreateItemRequestBody.d.ts +5 -0
- package/dist/api/resources/collections/resources/items/types/ItemsCreateItemRequestBody.js +5 -0
- package/dist/api/resources/collections/resources/items/types/ItemsListItemsLiveRequestSortBy.d.ts +1 -1
- package/dist/api/resources/collections/resources/items/types/ItemsListItemsLiveRequestSortOrder.d.ts +1 -1
- package/dist/api/resources/collections/resources/items/types/ItemsListItemsRequestSortBy.d.ts +1 -1
- package/dist/api/resources/collections/resources/items/types/ItemsListItemsRequestSortOrder.d.ts +1 -1
- package/dist/api/resources/collections/resources/items/types/ItemsPublishItemRequest.d.ts +11 -0
- package/dist/api/resources/collections/resources/items/types/ItemsPublishItemRequest.js +5 -0
- package/dist/api/resources/collections/resources/items/types/ItemsPublishItemRequestItemsItemsItem.d.ts +9 -0
- package/dist/api/resources/collections/resources/items/types/ItemsPublishItemRequestItemsItemsItem.js +5 -0
- package/dist/api/resources/collections/resources/items/types/ItemsUpdateItemsResponse.d.ts +5 -0
- package/dist/api/resources/collections/resources/items/types/ItemsUpdateItemsResponse.js +5 -0
- package/dist/api/resources/collections/resources/items/types/index.d.ts +7 -2
- package/dist/api/resources/collections/resources/items/types/index.js +7 -2
- package/dist/api/resources/components/client/Client.d.ts +39 -15
- package/dist/api/resources/components/client/Client.js +194 -105
- package/dist/api/resources/components/client/index.d.ts +1 -0
- package/dist/api/resources/components/client/requests/ComponentDomWrite.d.ts +8 -1
- package/dist/api/resources/components/client/requests/ComponentPropertiesWrite.d.ts +8 -1
- package/dist/api/resources/components/client/requests/ComponentsGetContentRequest.d.ts +11 -2
- package/dist/api/resources/components/client/requests/ComponentsGetPropertiesRequest.d.ts +11 -2
- package/dist/api/resources/components/client/requests/ComponentsListRequest.d.ts +9 -1
- package/dist/api/resources/components/types/ComponentDomWriteNodesItem.d.ts +1 -1
- package/dist/api/resources/ecommerce/client/Client.d.ts +10 -5
- package/dist/api/resources/ecommerce/client/Client.js +51 -28
- package/dist/api/resources/forms/client/Client.d.ts +33 -14
- package/dist/api/resources/forms/client/Client.js +215 -137
- package/dist/api/resources/forms/client/index.d.ts +1 -0
- package/dist/api/resources/forms/client/requests/FormsListRequest.d.ts +4 -1
- package/dist/api/resources/forms/client/requests/FormsListSubmissionsBySiteRequest.d.ts +3 -1
- package/dist/api/resources/forms/client/requests/FormsListSubmissionsRequest.d.ts +4 -1
- package/dist/api/resources/index.js +17 -7
- package/dist/api/resources/inventory/client/Client.d.ts +18 -12
- package/dist/api/resources/inventory/client/Client.js +88 -55
- package/dist/api/resources/inventory/client/index.d.ts +1 -0
- package/dist/api/resources/inventory/types/EcommInventoryChangedPayload.d.ts +8 -0
- package/dist/api/resources/inventory/types/EcommInventoryChangedPayload.js +5 -0
- package/dist/api/resources/inventory/types/InventoryUpdateRequestInventoryType.d.ts +1 -1
- package/dist/api/resources/inventory/types/index.d.ts +1 -0
- package/dist/api/resources/inventory/types/index.js +1 -0
- package/dist/api/resources/orders/client/Client.d.ts +25 -11
- package/dist/api/resources/orders/client/Client.js +201 -124
- package/dist/api/resources/orders/client/index.d.ts +1 -0
- package/dist/api/resources/orders/client/requests/OrdersListRequest.d.ts +5 -1
- package/dist/api/resources/orders/types/OrdersListRequestStatus.d.ts +1 -1
- package/dist/api/resources/orders/types/OrdersRefundRequestReason.d.ts +1 -1
- package/dist/api/resources/pages/client/Client.d.ts +43 -47
- package/dist/api/resources/pages/client/Client.js +185 -139
- package/dist/api/resources/pages/client/index.d.ts +1 -0
- package/dist/api/resources/pages/client/requests/PageMetadataWrite.d.ts +43 -0
- package/dist/api/resources/pages/client/requests/PageMetadataWrite.js +5 -0
- package/dist/api/resources/pages/client/requests/PagesGetContentRequest.d.ts +6 -2
- package/dist/api/resources/pages/client/requests/PagesGetMetadataRequest.d.ts +3 -1
- package/dist/api/resources/pages/client/requests/PagesListRequest.d.ts +6 -2
- package/dist/api/resources/pages/client/requests/index.d.ts +1 -1
- package/dist/api/resources/pages/resources/index.js +17 -7
- package/dist/api/resources/pages/resources/scripts/client/Client.d.ts +19 -10
- package/dist/api/resources/pages/resources/scripts/client/Client.js +96 -56
- package/dist/api/resources/pages/types/PageDomWriteNodesItem.d.ts +1 -1
- package/dist/api/resources/pages/types/PageMetadataWriteOpenGraph.d.ts +16 -0
- package/dist/api/resources/pages/types/PageMetadataWriteOpenGraph.js +5 -0
- package/dist/api/resources/pages/types/PageMetadataWriteSeo.d.ts +12 -0
- package/dist/api/resources/pages/types/PageMetadataWriteSeo.js +5 -0
- package/dist/api/resources/pages/types/index.d.ts +2 -0
- package/dist/api/resources/pages/types/index.js +2 -0
- package/dist/api/resources/products/client/Client.d.ts +36 -13
- package/dist/api/resources/products/client/Client.js +204 -120
- package/dist/api/resources/products/client/index.d.ts +1 -0
- package/dist/api/resources/products/client/requests/ProductSkuCreate.d.ts +2 -2
- package/dist/api/resources/products/client/requests/ProductsCreateSkuRequest.d.ts +5 -0
- package/dist/api/resources/products/client/requests/ProductsListRequest.d.ts +4 -1
- package/dist/api/resources/products/client/requests/ProductsUpdateSkuRequest.d.ts +5 -0
- package/dist/api/resources/products/types/ProductsCreateSkuResponse.d.ts +1 -1
- package/dist/api/resources/scripts/client/Client.d.ts +14 -7
- package/dist/api/resources/scripts/client/Client.js +99 -56
- package/dist/api/resources/scripts/client/index.d.ts +1 -0
- package/dist/api/resources/sites/client/Client.d.ts +43 -27
- package/dist/api/resources/sites/client/Client.js +228 -149
- package/dist/api/resources/sites/client/index.d.ts +1 -0
- package/dist/api/resources/sites/client/requests/SitesPublishRequest.d.ts +4 -1
- package/dist/api/resources/sites/resources/activityLogs/client/Client.d.ts +14 -6
- package/dist/api/resources/sites/resources/activityLogs/client/Client.js +53 -27
- package/dist/api/resources/sites/resources/activityLogs/client/index.d.ts +1 -0
- package/dist/api/resources/sites/resources/activityLogs/client/requests/ActivityLogsListRequest.d.ts +4 -1
- package/dist/api/resources/sites/resources/comments/client/Client.d.ts +29 -10
- package/dist/api/resources/sites/resources/comments/client/Client.js +148 -73
- package/dist/api/resources/sites/resources/comments/client/index.d.ts +1 -0
- package/dist/api/resources/sites/resources/comments/client/requests/CommentsGetCommentThreadRequest.d.ts +8 -2
- package/dist/api/resources/sites/resources/comments/client/requests/CommentsListCommentRepliesRequest.d.ts +8 -2
- package/dist/api/resources/sites/resources/comments/client/requests/CommentsListCommentThreadsRequest.d.ts +8 -2
- package/dist/api/resources/sites/resources/comments/types/CommentsGetCommentThreadRequestSortBy.d.ts +1 -1
- package/dist/api/resources/sites/resources/comments/types/CommentsGetCommentThreadRequestSortOrder.d.ts +1 -1
- package/dist/api/resources/sites/resources/comments/types/CommentsListCommentRepliesRequestSortBy.d.ts +1 -1
- package/dist/api/resources/sites/resources/comments/types/CommentsListCommentRepliesRequestSortOrder.d.ts +1 -1
- package/dist/api/resources/sites/resources/comments/types/CommentsListCommentThreadsRequestSortBy.d.ts +1 -1
- package/dist/api/resources/sites/resources/comments/types/CommentsListCommentThreadsRequestSortOrder.d.ts +1 -1
- package/dist/api/resources/sites/resources/index.js +17 -7
- package/dist/api/resources/sites/resources/plans/client/Client.d.ts +10 -5
- package/dist/api/resources/sites/resources/plans/client/Client.js +49 -26
- package/dist/api/resources/sites/resources/redirects/client/Client.d.ts +16 -8
- package/dist/api/resources/sites/resources/redirects/client/Client.js +124 -73
- package/dist/api/resources/sites/resources/robotsTxt/client/Client.d.ts +16 -8
- package/dist/api/resources/sites/resources/robotsTxt/client/Client.js +124 -71
- package/dist/api/resources/sites/resources/scripts/client/Client.d.ts +26 -11
- package/dist/api/resources/sites/resources/scripts/client/Client.js +126 -73
- package/dist/api/resources/sites/resources/scripts/client/index.d.ts +1 -0
- package/dist/api/resources/sites/resources/scripts/client/requests/ScriptsListCustomCodeBlocksRequest.d.ts +4 -1
- package/dist/api/resources/sites/resources/wellKnown/client/Client.d.ts +15 -8
- package/dist/api/resources/sites/resources/wellKnown/client/Client.js +60 -30
- package/dist/api/resources/sites/resources/wellKnown/client/index.d.ts +1 -0
- package/dist/api/resources/sites/resources/wellKnown/client/requests/WellKnownFile.d.ts +3 -2
- package/dist/api/resources/sites/resources/wellKnown/types/WellKnownFileContentType.d.ts +1 -1
- package/dist/api/resources/token/client/Client.d.ts +12 -6
- package/dist/api/resources/token/client/Client.js +67 -36
- package/dist/api/resources/users/client/Client.d.ts +36 -18
- package/dist/api/resources/users/client/Client.js +173 -104
- package/dist/api/resources/users/client/index.d.ts +1 -0
- package/dist/api/resources/users/client/requests/UsersInviteRequest.d.ts +1 -1
- package/dist/api/resources/users/client/requests/UsersListRequest.d.ts +5 -1
- package/dist/api/resources/users/client/requests/index.d.ts +0 -1
- package/dist/api/resources/users/types/UserAccountAddedPayload.d.ts +8 -0
- package/dist/api/resources/users/types/UserAccountAddedPayload.js +5 -0
- package/dist/api/resources/users/types/UserAccountAddedPayloadPayload.d.ts +23 -0
- package/dist/api/resources/users/types/UserAccountAddedPayloadPayload.js +5 -0
- package/dist/api/resources/users/types/UserAccountAddedPayloadPayloadData.d.ts +12 -0
- package/dist/api/resources/users/types/UserAccountAddedPayloadPayloadData.js +5 -0
- package/dist/api/resources/users/types/UserAccountDeletedPayload.d.ts +8 -0
- package/dist/api/resources/users/types/UserAccountDeletedPayload.js +5 -0
- package/dist/api/resources/users/types/UserAccountDeletedPayloadPayload.d.ts +23 -0
- package/dist/api/resources/users/types/UserAccountDeletedPayloadPayload.js +5 -0
- package/dist/api/resources/users/types/UserAccountDeletedPayloadPayloadData.d.ts +12 -0
- package/dist/api/resources/users/types/UserAccountDeletedPayloadPayloadData.js +5 -0
- package/dist/api/resources/users/types/UserAccountUpdatedPayload.d.ts +8 -0
- package/dist/api/resources/users/types/UserAccountUpdatedPayload.js +5 -0
- package/dist/api/resources/users/types/UserAccountUpdatedPayloadPayload.d.ts +23 -0
- package/dist/api/resources/users/types/UserAccountUpdatedPayloadPayload.js +5 -0
- package/dist/api/resources/users/types/UserAccountUpdatedPayloadPayloadData.d.ts +12 -0
- package/dist/api/resources/users/types/UserAccountUpdatedPayloadPayloadData.js +5 -0
- package/dist/api/resources/users/types/UsersListRequestSort.d.ts +1 -1
- package/dist/api/resources/users/types/index.d.ts +9 -1
- package/dist/api/resources/users/types/index.js +9 -1
- package/dist/api/resources/webhooks/client/Client.d.ts +18 -10
- package/dist/api/resources/webhooks/client/Client.js +117 -71
- package/dist/api/resources/workspaces/client/Client.d.ts +6 -12
- package/dist/api/resources/workspaces/client/Client.js +1 -1
- package/dist/api/resources/workspaces/resources/auditLogs/client/Client.d.ts +16 -7
- package/dist/api/resources/workspaces/resources/auditLogs/client/Client.js +69 -32
- package/dist/api/resources/workspaces/resources/auditLogs/client/index.d.ts +1 -0
- package/dist/api/resources/workspaces/resources/auditLogs/client/requests/AuditLogsGetWorkspaceAuditLogsRequest.d.ts +6 -2
- package/dist/api/resources/workspaces/resources/auditLogs/types/AuditLogsGetWorkspaceAuditLogsRequestEventType.d.ts +1 -1
- package/dist/api/resources/workspaces/resources/auditLogs/types/AuditLogsGetWorkspaceAuditLogsRequestSortOrder.d.ts +1 -1
- package/dist/api/resources/workspaces/resources/index.js +17 -7
- package/dist/api/types/Application.d.ts +10 -1
- package/dist/api/types/Asset.d.ts +2 -2
- package/dist/api/types/AssetVariant.d.ts +6 -6
- package/dist/api/types/Authorization.d.ts +1 -1
- package/dist/api/types/BadRequestErrorBody.d.ts +1 -1
- package/dist/api/types/BulkCollectionItem.d.ts +1 -1
- package/dist/api/types/Collection.d.ts +2 -2
- package/dist/api/types/CollectionItemChanged.d.ts +12 -0
- package/dist/api/types/CollectionItemChanged.js +5 -0
- package/dist/api/types/CollectionItemCreated.d.ts +12 -0
- package/dist/api/types/CollectionItemCreated.js +5 -0
- package/dist/api/types/CollectionItemPublished.d.ts +9 -0
- package/dist/api/types/CollectionItemPublished.js +5 -0
- package/dist/api/types/CollectionItemRemoved.d.ts +10 -0
- package/dist/api/types/CollectionItemRemoved.js +5 -0
- package/dist/api/types/CollectionItemRemovedPayload.d.ts +25 -0
- package/dist/api/types/CollectionItemRemovedPayload.js +5 -0
- package/dist/api/types/CollectionItemRemovedPayloadFieldData.d.ts +9 -0
- package/dist/api/types/CollectionItemRemovedPayloadFieldData.js +5 -0
- package/dist/api/types/CollectionItemUnpublished.d.ts +10 -0
- package/dist/api/types/CollectionItemUnpublished.js +5 -0
- package/dist/api/types/CollectionItemUnpublishedPayload.d.ts +25 -0
- package/dist/api/types/CollectionItemUnpublishedPayload.js +5 -0
- package/dist/api/types/CollectionItemUnpublishedPayloadFieldData.d.ts +9 -0
- package/dist/api/types/CollectionItemUnpublishedPayloadFieldData.js +5 -0
- package/dist/api/types/Comment.d.ts +12 -0
- package/dist/api/types/Comment.js +5 -0
- package/dist/api/types/CommentPayload.d.ts +38 -0
- package/dist/api/types/CommentPayload.js +5 -0
- package/dist/api/types/CommentPayloadAuthor.d.ts +11 -0
- package/dist/api/types/CommentPayloadAuthor.js +5 -0
- package/dist/api/types/CommentPayloadMentionedUsersItem.d.ts +11 -0
- package/dist/api/types/CommentPayloadMentionedUsersItem.js +5 -0
- package/dist/api/types/CommentReply.d.ts +2 -2
- package/dist/api/types/ComponentNode.d.ts +3 -3
- package/dist/api/types/ComponentPropertyType.d.ts +1 -1
- package/dist/api/types/Conflict.d.ts +1 -1
- package/dist/api/types/ConflictErrorBody.d.ts +1 -1
- package/dist/api/types/CustomCodeBlockType.d.ts +1 -1
- package/dist/api/types/CustomRoleAuditLogItemEventSubType.d.ts +1 -1
- package/dist/api/types/Dom.d.ts +2 -0
- package/dist/api/types/DuplicateUserEmail.d.ts +1 -1
- package/dist/api/types/ErrorCode.d.ts +1 -1
- package/dist/api/types/Field.d.ts +2 -0
- package/dist/api/types/FieldCreate.d.ts +1 -1
- package/dist/api/types/FieldType.d.ts +1 -1
- package/dist/api/types/FieldValidations.d.ts +10 -0
- package/dist/api/types/FieldValidations.js +5 -0
- package/dist/api/types/FieldValidationsAdditionalProperties.d.ts +5 -0
- package/dist/api/types/FieldValidationsAdditionalProperties.js +5 -0
- package/dist/api/types/FieldValidationsAdditionalPropertiesAdditionalProperties.d.ts +6 -0
- package/dist/api/types/FieldValidationsAdditionalPropertiesAdditionalProperties.js +5 -0
- package/dist/api/types/ForbiddenErrorBody.d.ts +1 -1
- package/dist/api/types/FormField.d.ts +1 -1
- package/dist/api/types/FormFieldValueType.d.ts +1 -1
- package/dist/api/types/FormSubmissionTrigger.d.ts +13 -0
- package/dist/api/types/FormSubmissionTrigger.js +5 -0
- package/dist/api/types/FormSubmissionTriggerPayload.d.ts +25 -0
- package/dist/api/types/FormSubmissionTriggerPayload.js +5 -0
- package/dist/api/types/FormSubmissionTriggerPayloadSchemaItem.d.ts +12 -0
- package/dist/api/types/FormSubmissionTriggerPayloadSchemaItem.js +5 -0
- package/dist/api/types/FormSubmissionTriggerPayloadSchemaItemFieldType.d.ts +14 -0
- package/dist/api/types/FormSubmissionTriggerPayloadSchemaItemFieldType.js +13 -0
- package/dist/api/types/ImageNode.d.ts +2 -2
- package/dist/api/types/InvalidDomain.d.ts +1 -1
- package/dist/api/types/InvalidScopes.d.ts +1 -1
- package/dist/api/types/InventoryItemInventoryType.d.ts +1 -1
- package/dist/api/types/ItemsListItemsLiveRequestLastPublished.d.ts +9 -0
- package/dist/api/types/ItemsListItemsLiveRequestLastPublished.js +5 -0
- package/dist/api/types/ItemsListItemsRequestLastPublished.d.ts +9 -0
- package/dist/api/types/ItemsListItemsRequestLastPublished.js +5 -0
- package/dist/api/types/NewOrder.d.ts +12 -0
- package/dist/api/types/NewOrder.js +5 -0
- package/dist/api/types/NoDomains.d.ts +1 -1
- package/dist/api/types/Node.d.ts +1 -1
- package/dist/api/types/NotEnterprisePlanSite.d.ts +1 -1
- package/dist/api/types/NotEnterprisePlanWorkspace.d.ts +1 -1
- package/dist/api/types/OAuthScope.d.ts +1 -1
- package/dist/api/types/Order.d.ts +2 -2
- package/dist/api/types/OrderAddressJapanType.d.ts +1 -1
- package/dist/api/types/OrderAddressType.d.ts +1 -1
- package/dist/api/types/OrderBillingAddress.d.ts +27 -0
- package/dist/api/types/OrderBillingAddress.js +5 -0
- package/dist/api/types/OrderBillingAddressJapanType.d.ts +11 -0
- package/dist/api/types/OrderBillingAddressJapanType.js +10 -0
- package/dist/api/types/OrderBillingAddressType.d.ts +11 -0
- package/dist/api/types/OrderBillingAddressType.js +10 -0
- package/dist/api/types/OrderDisputeLastStatus.d.ts +1 -1
- package/dist/api/types/OrderShippingAddress.d.ts +27 -0
- package/dist/api/types/OrderShippingAddress.js +5 -0
- package/dist/api/types/OrderShippingAddressJapanType.d.ts +11 -0
- package/dist/api/types/OrderShippingAddressJapanType.js +10 -0
- package/dist/api/types/OrderShippingAddressType.d.ts +11 -0
- package/dist/api/types/OrderShippingAddressType.js +10 -0
- package/dist/api/types/OrderStatus.d.ts +1 -1
- package/dist/api/types/OrderTotalsExtrasItemType.d.ts +1 -1
- package/dist/api/types/Page.d.ts +3 -1
- package/dist/api/types/PageCreatedWebhook.d.ts +13 -0
- package/dist/api/types/PageCreatedWebhook.js +5 -0
- package/dist/api/types/PageCreatedWebhookPayload.d.ts +13 -0
- package/dist/api/types/PageCreatedWebhookPayload.js +5 -0
- package/dist/api/types/PageDeletedWebhook.d.ts +13 -0
- package/dist/api/types/PageDeletedWebhook.js +5 -0
- package/dist/api/types/PageDeletedWebhookPayload.d.ts +13 -0
- package/dist/api/types/PageDeletedWebhookPayload.js +5 -0
- package/dist/api/types/PageMetadataUpdatedWebhook.d.ts +13 -0
- package/dist/api/types/PageMetadataUpdatedWebhook.js +5 -0
- package/dist/api/types/PageMetadataUpdatedWebhookPayload.d.ts +13 -0
- package/dist/api/types/PageMetadataUpdatedWebhookPayload.js +5 -0
- package/dist/api/types/Payload.d.ts +25 -0
- package/dist/api/types/Payload.js +5 -0
- package/dist/api/types/PayloadFieldData.d.ts +9 -0
- package/dist/api/types/PayloadFieldData.js +5 -0
- package/dist/api/types/ProductFieldData.d.ts +2 -2
- package/dist/api/types/ProductFieldDataEcProductType.d.ts +1 -1
- package/dist/api/types/ProductFieldDataTaxCategory.d.ts +1 -1
- package/dist/api/types/PublishStatus.d.ts +1 -1
- package/dist/api/types/ReferenceFieldType.d.ts +1 -1
- package/dist/api/types/RegisteredScriptList.d.ts +1 -0
- package/dist/api/types/ScriptApplyLocation.d.ts +1 -1
- package/dist/api/types/Scripts.d.ts +1 -1
- package/{api/types/SelectNodeWrite.d.ts → dist/api/types/Select.d.ts} +1 -1
- package/dist/api/types/Select.js +5 -0
- package/dist/api/types/SingleLocaleCreatedPayload.d.ts +22 -0
- package/dist/api/types/SingleLocaleCreatedPayload.js +5 -0
- package/dist/api/types/SingleLocaleCreatedPayloadFieldData.d.ts +9 -0
- package/dist/api/types/SingleLocaleCreatedPayloadFieldData.js +5 -0
- package/dist/api/types/SiteActivityLogItemEvent.d.ts +1 -1
- package/dist/api/types/SiteActivityLogItemResourceOperation.d.ts +1 -1
- package/dist/api/types/SiteDataCollectionType.d.ts +1 -1
- package/dist/api/types/SiteMembership.d.ts +1 -0
- package/dist/api/types/SiteMembershipAuditLogItemEventSubType.d.ts +2 -1
- package/dist/api/types/SiteMembershipAuditLogItemEventSubType.js +1 -0
- package/dist/api/types/SitePlanId.d.ts +1 -1
- package/dist/api/types/SitePlanName.d.ts +1 -1
- package/dist/api/types/SitePublish.d.ts +13 -0
- package/dist/api/types/SitePublish.js +5 -0
- package/dist/api/types/SitePublishPayload.d.ts +16 -0
- package/dist/api/types/SitePublishPayload.js +5 -0
- package/dist/api/types/SkuFieldData.d.ts +0 -4
- package/dist/api/types/SkuFieldDataEcSkuBillingMethod.d.ts +1 -1
- package/dist/api/types/SkuFieldDataEcSkuSubscriptionPlanInterval.d.ts +1 -1
- package/dist/api/types/SkuFieldDataEcSkuSubscriptionPlanPlansItemStatus.d.ts +1 -1
- package/dist/api/types/SkuValueList.d.ts +1 -1
- package/dist/api/types/StaticFieldType.d.ts +1 -1
- package/dist/api/types/StripeCardBrand.d.ts +1 -1
- package/dist/api/types/TextNode.d.ts +2 -2
- package/dist/api/types/TriggerType.d.ts +2 -1
- package/dist/api/types/TriggerType.js +1 -0
- package/dist/api/types/UpdatedOrder.d.ts +12 -0
- package/dist/api/types/UpdatedOrder.js +5 -0
- package/dist/api/types/User.d.ts +0 -1
- package/dist/api/types/UserAccessAuditLogItemEventSubType.d.ts +1 -1
- package/dist/api/types/UserAccessGroupsItemType.d.ts +1 -1
- package/dist/api/types/UserLimitReached.d.ts +1 -1
- package/dist/api/types/UserStatus.d.ts +1 -1
- package/dist/api/types/UsersNotEnabled.d.ts +1 -1
- package/dist/api/types/WorkspaceAuditLogItem.d.ts +1 -1
- package/dist/api/types/WorkspaceAuditLogItemPayloadSiteMembershipGranularAccess.d.ts +9 -0
- package/dist/api/types/WorkspaceAuditLogItemPayloadSiteMembershipGranularAccess.js +5 -0
- package/dist/api/types/WorkspaceAuditLogItemPayloadSiteMembershipMethod.d.ts +2 -1
- package/dist/api/types/WorkspaceAuditLogItemPayloadSiteMembershipMethod.js +1 -0
- package/dist/api/types/WorkspaceAuditLogItemPayloadSiteMembershipUserType.d.ts +1 -1
- package/dist/api/types/WorkspaceAuditLogItemPayloadUserAccessMethod.d.ts +1 -1
- package/dist/api/types/WorkspaceAuditLogItemPayloadWorkspaceInvitationMethod.d.ts +1 -1
- package/dist/api/types/WorkspaceAuditLogItemPayloadWorkspaceInvitationTargetUsersItem.d.ts +7 -0
- package/dist/api/types/WorkspaceAuditLogItemPayloadWorkspaceInvitationTargetUsersItem.js +5 -0
- package/dist/api/types/WorkspaceAuditLogItemPayloadWorkspaceInvitationUserType.d.ts +1 -1
- package/dist/api/types/WorkspaceAuditLogItemPayloadWorkspaceMembershipMethod.d.ts +2 -1
- package/dist/api/types/WorkspaceAuditLogItemPayloadWorkspaceMembershipMethod.js +1 -0
- package/dist/api/types/WorkspaceAuditLogItemPayloadWorkspaceMembershipUserType.d.ts +1 -1
- package/dist/api/types/WorkspaceInvitation.d.ts +1 -0
- package/dist/api/types/WorkspaceInvitationAuditLogItemEventSubType.d.ts +2 -1
- package/dist/api/types/WorkspaceInvitationAuditLogItemEventSubType.js +1 -0
- package/dist/api/types/WorkspaceMembershipAuditLogItemEventSubType.d.ts +1 -1
- package/dist/api/types/index.d.ts +47 -3
- package/dist/api/types/index.js +47 -3
- package/dist/core/auth/BearerToken.d.ts +1 -1
- package/dist/core/fetcher/APIResponse.d.ts +11 -1
- package/dist/core/fetcher/Fetcher.d.ts +4 -3
- package/dist/core/fetcher/Fetcher.js +35 -14
- package/dist/core/fetcher/Headers.d.ts +2 -0
- package/dist/core/fetcher/Headers.js +84 -0
- package/dist/core/fetcher/HttpResponsePromise.d.ts +58 -0
- package/dist/core/fetcher/HttpResponsePromise.js +103 -0
- package/dist/core/fetcher/RawResponse.d.ts +29 -0
- package/dist/core/fetcher/RawResponse.js +44 -0
- package/dist/core/fetcher/Supplier.d.ts +1 -1
- package/dist/core/fetcher/createRequestUrl.d.ts +1 -1
- package/dist/core/fetcher/createRequestUrl.js +1 -2
- package/dist/core/fetcher/getFetchFn.js +18 -9
- package/dist/core/fetcher/getHeader.js +1 -2
- package/dist/core/fetcher/getRequestBody.js +5 -5
- package/dist/core/fetcher/getResponseBody.js +1 -2
- package/dist/core/fetcher/index.d.ts +3 -0
- package/dist/core/fetcher/index.js +7 -1
- package/dist/core/fetcher/makeRequest.d.ts +1 -1
- package/dist/core/fetcher/requestWithRetries.js +4 -5
- package/dist/core/fetcher/signals.d.ts +0 -1
- package/dist/core/fetcher/signals.js +2 -3
- package/dist/core/fetcher/stream-wrappers/NodePre18StreamWrapper.d.ts +0 -1
- package/dist/core/fetcher/stream-wrappers/NodePre18StreamWrapper.js +6 -4
- package/dist/core/fetcher/stream-wrappers/UndiciStreamWrapper.d.ts +1 -1
- package/dist/core/fetcher/stream-wrappers/chooseStreamWrapper.d.ts +1 -1
- package/dist/core/fetcher/stream-wrappers/chooseStreamWrapper.js +18 -9
- package/dist/core/headers.d.ts +3 -0
- package/dist/core/headers.js +29 -0
- package/dist/core/index.d.ts +1 -1
- package/dist/core/index.js +18 -8
- package/dist/core/json.d.ts +15 -0
- package/dist/core/json.js +24 -0
- package/dist/core/runtime/runtime.d.ts +1 -1
- package/dist/core/runtime/runtime.js +50 -41
- package/dist/core/schemas/Schema.d.ts +7 -5
- package/dist/core/schemas/Schema.js +2 -0
- package/dist/core/schemas/builders/bigint/bigint.d.ts +1 -1
- package/dist/core/schemas/builders/bigint/bigint.js +22 -19
- package/dist/core/schemas/builders/date/date.js +1 -2
- package/dist/core/schemas/builders/enum/enum.js +1 -2
- package/dist/core/schemas/builders/lazy/lazy.d.ts +1 -1
- package/dist/core/schemas/builders/lazy/lazy.js +3 -4
- package/dist/core/schemas/builders/lazy/lazyObject.js +1 -2
- package/dist/core/schemas/builders/list/list.js +1 -2
- package/dist/core/schemas/builders/literals/booleanLiteral.js +1 -2
- package/dist/core/schemas/builders/literals/stringLiteral.js +1 -2
- package/dist/core/schemas/builders/object/object.d.ts +1 -1
- package/dist/core/schemas/builders/object/object.js +3 -3
- package/dist/core/schemas/builders/object/objectWithoutOptionalProperties.d.ts +3 -3
- package/dist/core/schemas/builders/object/objectWithoutOptionalProperties.js +1 -2
- package/dist/core/schemas/builders/object/property.js +2 -3
- package/dist/core/schemas/builders/object/types.d.ts +11 -11
- package/dist/core/schemas/builders/object-like/getObjectLikeUtils.js +2 -3
- package/dist/core/schemas/builders/object-like/types.d.ts +1 -1
- package/dist/core/schemas/builders/record/record.js +2 -4
- package/dist/core/schemas/builders/record/types.d.ts +2 -2
- package/dist/core/schemas/builders/schema-utils/getSchemaUtils.d.ts +4 -0
- package/dist/core/schemas/builders/schema-utils/getSchemaUtils.js +67 -4
- package/dist/core/schemas/builders/schema-utils/stringifyValidationErrors.js +1 -2
- package/dist/core/schemas/builders/set/set.js +1 -2
- package/dist/core/schemas/builders/undiscriminated-union/types.d.ts +4 -4
- package/dist/core/schemas/builders/undiscriminated-union/undiscriminatedUnion.js +1 -2
- package/dist/core/schemas/builders/union/discriminant.js +1 -2
- package/dist/core/schemas/builders/union/types.d.ts +6 -6
- package/dist/core/schemas/builders/union/union.d.ts +1 -1
- package/dist/core/schemas/builders/union/union.js +1 -2
- package/dist/core/schemas/utils/MaybePromise.d.ts +1 -1
- package/dist/core/schemas/utils/addQuestionMarksToNullableProperties.d.ts +4 -4
- package/dist/core/schemas/utils/createIdentitySchemaCreator.js +1 -2
- package/dist/core/schemas/utils/entries.d.ts +1 -1
- package/dist/core/schemas/utils/entries.js +1 -2
- package/dist/core/schemas/utils/filterObject.d.ts +1 -1
- package/dist/core/schemas/utils/filterObject.js +1 -2
- package/dist/core/schemas/utils/getErrorMessageForIncorrectType.js +1 -2
- package/dist/core/schemas/utils/isPlainObject.js +1 -2
- package/dist/core/schemas/utils/keys.d.ts +1 -1
- package/dist/core/schemas/utils/keys.js +1 -2
- package/dist/core/schemas/utils/maybeSkipValidation.js +1 -2
- package/dist/core/schemas/utils/partition.js +1 -2
- package/dist/environments.d.ts +1 -5
- package/dist/environments.js +0 -2
- package/dist/errors/WebflowError.d.ts +4 -1
- package/dist/errors/WebflowError.js +6 -8
- package/dist/index.js +17 -7
- package/dist/serialization/resources/accessGroups/types/AccessGroupsListRequestSort.js +17 -7
- package/dist/serialization/resources/assets/client/requests/AssetsCreateFolderRequest.js +17 -7
- package/dist/serialization/resources/assets/client/requests/AssetsCreateRequest.js +17 -7
- package/dist/serialization/resources/assets/client/requests/AssetsUpdateRequest.js +17 -7
- package/dist/serialization/resources/collections/client/requests/CollectionsCreateRequest.js +17 -7
- package/dist/serialization/resources/collections/resources/fields/client/requests/FieldUpdate.js +17 -7
- package/dist/serialization/resources/collections/resources/index.js +17 -7
- package/dist/serialization/resources/collections/resources/items/client/requests/CreateBulkCollectionItemRequestBody.d.ts +1 -1
- package/dist/serialization/resources/collections/resources/items/client/requests/CreateBulkCollectionItemRequestBody.js +17 -7
- package/dist/serialization/resources/collections/resources/items/client/requests/ItemsDeleteItemsLiveRequest.js +17 -7
- package/dist/serialization/resources/collections/resources/items/client/requests/ItemsDeleteItemsRequest.js +17 -7
- package/dist/serialization/resources/collections/resources/items/client/requests/ItemsUpdateItemsLiveRequest.d.ts +1 -1
- package/dist/serialization/resources/collections/resources/items/client/requests/ItemsUpdateItemsLiveRequest.js +17 -7
- package/dist/serialization/resources/collections/resources/items/client/requests/ItemsUpdateItemsRequest.d.ts +1 -1
- package/dist/serialization/resources/collections/resources/items/client/requests/ItemsUpdateItemsRequest.js +17 -7
- package/dist/serialization/resources/collections/resources/items/client/requests/index.d.ts +0 -1
- package/dist/serialization/resources/collections/resources/items/client/requests/index.js +1 -3
- package/dist/serialization/resources/collections/resources/items/types/CreateBulkCollectionItemRequestBodyFieldData.js +17 -7
- package/dist/serialization/resources/collections/resources/items/types/CreateBulkCollectionItemRequestBodyFieldDataItem.js +17 -7
- package/dist/serialization/resources/collections/resources/items/types/ItemIDs.d.ts +12 -0
- package/{serialization/resources/collections/resources/items/client/requests/ItemsPublishItemRequest.js → dist/serialization/resources/collections/resources/items/types/ItemIDs.js} +21 -11
- package/dist/serialization/resources/collections/resources/items/types/ItemIDsWithLocales.d.ts +13 -0
- package/dist/serialization/resources/collections/resources/items/types/ItemIDsWithLocales.js +44 -0
- package/dist/serialization/resources/collections/resources/items/types/{ItemsCreateItemLiveRequest.d.ts → ItemsCreateItemLiveRequestBody.d.ts} +2 -2
- package/{serialization/resources/collections/resources/items/types/ItemsCreateItemLiveRequest.js → dist/serialization/resources/collections/resources/items/types/ItemsCreateItemLiveRequestBody.js} +19 -9
- package/dist/serialization/resources/collections/resources/items/types/{ItemsCreateItemRequest.d.ts → ItemsCreateItemRequestBody.d.ts} +2 -2
- package/dist/serialization/resources/collections/resources/items/types/{ItemsCreateItemRequest.js → ItemsCreateItemRequestBody.js} +19 -9
- package/dist/serialization/resources/collections/resources/items/types/ItemsDeleteItemsLiveRequestItemsItem.js +17 -7
- package/dist/serialization/resources/collections/resources/items/types/ItemsDeleteItemsRequestItemsItem.js +17 -7
- package/dist/serialization/resources/collections/resources/items/types/ItemsListItemsLiveRequestSortBy.js +17 -7
- package/dist/serialization/resources/collections/resources/items/types/ItemsListItemsLiveRequestSortOrder.js +17 -7
- package/dist/serialization/resources/collections/resources/items/types/ItemsListItemsRequestSortBy.js +17 -7
- package/dist/serialization/resources/collections/resources/items/types/ItemsListItemsRequestSortOrder.js +17 -7
- package/dist/serialization/resources/collections/resources/items/types/ItemsPublishItemRequest.d.ts +12 -0
- package/dist/serialization/resources/collections/resources/items/types/ItemsPublishItemRequest.js +43 -0
- package/dist/serialization/resources/collections/resources/items/types/ItemsPublishItemRequestItemsItemsItem.d.ts +13 -0
- package/dist/serialization/resources/collections/resources/items/types/ItemsPublishItemRequestItemsItemsItem.js +44 -0
- package/dist/serialization/resources/collections/resources/items/types/ItemsPublishItemResponse.js +17 -7
- package/dist/serialization/resources/collections/resources/items/types/ItemsUpdateItemsResponse.d.ts +12 -0
- package/dist/serialization/resources/collections/resources/items/types/ItemsUpdateItemsResponse.js +43 -0
- package/dist/serialization/resources/collections/resources/items/types/MultipleItems.js +17 -7
- package/dist/serialization/resources/collections/resources/items/types/MultipleLiveItems.js +17 -7
- package/dist/serialization/resources/collections/resources/items/types/SingleCmsItem.js +17 -7
- package/dist/serialization/resources/collections/resources/items/types/index.d.ts +7 -2
- package/dist/serialization/resources/collections/resources/items/types/index.js +7 -2
- package/dist/serialization/resources/components/client/requests/ComponentDomWrite.d.ts +1 -1
- package/dist/serialization/resources/components/client/requests/ComponentDomWrite.js +17 -7
- package/dist/serialization/resources/components/client/requests/ComponentPropertiesWrite.d.ts +1 -1
- package/dist/serialization/resources/components/client/requests/ComponentPropertiesWrite.js +17 -7
- package/dist/serialization/resources/components/types/ComponentDomWriteNodesItem.d.ts +2 -2
- package/dist/serialization/resources/components/types/ComponentDomWriteNodesItem.js +19 -9
- package/dist/serialization/resources/components/types/ComponentPropertiesWritePropertiesItem.js +17 -7
- package/dist/serialization/resources/components/types/ComponentsUpdateContentResponse.js +17 -7
- package/dist/serialization/resources/components/types/ComponentsUpdatePropertiesResponse.js +17 -7
- package/dist/serialization/resources/forms/client/requests/FormsUpdateSubmissionRequest.js +17 -7
- package/dist/serialization/resources/index.js +17 -7
- package/dist/serialization/resources/inventory/client/requests/InventoryUpdateRequest.js +17 -7
- package/dist/serialization/resources/inventory/types/EcommInventoryChangedPayload.d.ts +14 -0
- package/dist/serialization/resources/inventory/types/EcommInventoryChangedPayload.js +45 -0
- package/dist/serialization/resources/inventory/types/InventoryUpdateRequestInventoryType.js +17 -7
- package/dist/serialization/resources/inventory/types/index.d.ts +1 -0
- package/dist/serialization/resources/inventory/types/index.js +1 -0
- package/dist/serialization/resources/orders/client/requests/OrdersRefundRequest.js +17 -7
- package/dist/serialization/resources/orders/client/requests/OrdersUpdateFulfillRequest.js +17 -7
- package/dist/serialization/resources/orders/client/requests/OrdersUpdateRequest.js +17 -7
- package/dist/serialization/resources/orders/types/OrdersListRequestStatus.js +17 -7
- package/dist/serialization/resources/orders/types/OrdersRefundRequestReason.js +17 -7
- package/dist/serialization/resources/pages/client/requests/PageDomWrite.js +17 -7
- package/dist/serialization/resources/pages/client/requests/PageMetadataWrite.d.ts +17 -0
- package/dist/serialization/resources/pages/client/requests/PageMetadataWrite.js +48 -0
- package/dist/serialization/resources/pages/client/requests/index.d.ts +1 -0
- package/dist/serialization/resources/pages/client/requests/index.js +3 -1
- package/dist/serialization/resources/pages/types/PageDomWriteNodesItem.d.ts +2 -2
- package/dist/serialization/resources/pages/types/PageDomWriteNodesItem.js +19 -9
- package/dist/serialization/resources/pages/types/PageMetadataWriteOpenGraph.d.ts +15 -0
- package/dist/serialization/resources/pages/types/PageMetadataWriteOpenGraph.js +46 -0
- package/dist/serialization/resources/pages/types/PageMetadataWriteSeo.d.ts +13 -0
- package/dist/serialization/resources/pages/types/PageMetadataWriteSeo.js +44 -0
- package/dist/serialization/resources/pages/types/UpdateStaticContentResponse.js +17 -7
- package/dist/serialization/resources/pages/types/index.d.ts +2 -0
- package/dist/serialization/resources/pages/types/index.js +2 -0
- package/dist/serialization/resources/products/client/requests/ProductSkuCreate.js +17 -7
- package/dist/serialization/resources/products/client/requests/ProductSkuUpdate.js +17 -7
- package/dist/serialization/resources/products/client/requests/ProductsCreateSkuRequest.js +17 -7
- package/dist/serialization/resources/products/client/requests/ProductsUpdateSkuRequest.js +17 -7
- package/dist/serialization/resources/products/types/ProductSkuCreateProduct.js +17 -7
- package/dist/serialization/resources/products/types/ProductSkuCreateSku.js +17 -7
- package/dist/serialization/resources/products/types/ProductsCreateSkuResponse.d.ts +1 -1
- package/dist/serialization/resources/products/types/ProductsCreateSkuResponse.js +18 -8
- package/dist/serialization/resources/scripts/client/requests/CustomCodeHostedRequest.js +17 -7
- package/dist/serialization/resources/scripts/client/requests/CustomCodeInlineRequest.js +17 -7
- package/dist/serialization/resources/sites/client/requests/SitesCreateRequest.js +17 -7
- package/dist/serialization/resources/sites/client/requests/SitesPublishRequest.js +17 -7
- package/dist/serialization/resources/sites/client/requests/SitesUpdateRequest.js +17 -7
- package/dist/serialization/resources/sites/resources/comments/types/CommentsGetCommentThreadRequestSortBy.js +17 -7
- package/dist/serialization/resources/sites/resources/comments/types/CommentsGetCommentThreadRequestSortOrder.js +17 -7
- package/dist/serialization/resources/sites/resources/comments/types/CommentsListCommentRepliesRequestSortBy.js +17 -7
- package/dist/serialization/resources/sites/resources/comments/types/CommentsListCommentRepliesRequestSortOrder.js +17 -7
- package/dist/serialization/resources/sites/resources/comments/types/CommentsListCommentThreadsRequestSortBy.js +17 -7
- package/dist/serialization/resources/sites/resources/comments/types/CommentsListCommentThreadsRequestSortOrder.js +17 -7
- package/dist/serialization/resources/sites/resources/index.js +17 -7
- package/dist/serialization/resources/sites/resources/wellKnown/client/requests/WellKnownDeleteRequest.js +17 -7
- package/dist/serialization/resources/sites/resources/wellKnown/client/requests/WellKnownFile.js +17 -7
- package/dist/serialization/resources/sites/resources/wellKnown/types/WellKnownFileContentType.js +17 -7
- package/dist/serialization/resources/sites/types/SitesPublishResponse.js +17 -7
- package/dist/serialization/resources/users/client/requests/UsersInviteRequest.js +17 -7
- package/dist/serialization/resources/users/client/requests/index.d.ts +0 -1
- package/dist/serialization/resources/users/client/requests/index.js +1 -3
- package/dist/serialization/resources/users/types/UserAccountAddedPayload.d.ts +14 -0
- package/dist/serialization/resources/users/types/UserAccountAddedPayload.js +45 -0
- package/dist/serialization/resources/users/types/UserAccountAddedPayloadPayload.d.ts +23 -0
- package/dist/serialization/resources/users/types/UserAccountAddedPayloadPayload.js +54 -0
- package/dist/serialization/resources/users/types/UserAccountAddedPayloadPayloadData.d.ts +15 -0
- package/dist/serialization/resources/users/types/{UsersUpdateRequestData.js → UserAccountAddedPayloadPayloadData.js} +22 -11
- package/dist/serialization/resources/users/types/UserAccountDeletedPayload.d.ts +14 -0
- package/dist/serialization/resources/users/types/UserAccountDeletedPayload.js +45 -0
- package/dist/serialization/resources/users/types/UserAccountDeletedPayloadPayload.d.ts +23 -0
- package/dist/serialization/resources/users/types/UserAccountDeletedPayloadPayload.js +54 -0
- package/dist/serialization/resources/users/types/UserAccountDeletedPayloadPayloadData.d.ts +15 -0
- package/dist/serialization/resources/users/types/UserAccountDeletedPayloadPayloadData.js +46 -0
- package/dist/serialization/resources/users/types/UserAccountUpdatedPayload.d.ts +14 -0
- package/dist/serialization/resources/users/types/UserAccountUpdatedPayload.js +45 -0
- package/dist/serialization/resources/users/types/UserAccountUpdatedPayloadPayload.d.ts +23 -0
- package/dist/serialization/resources/users/types/UserAccountUpdatedPayloadPayload.js +54 -0
- package/dist/serialization/resources/users/types/UserAccountUpdatedPayloadPayloadData.d.ts +15 -0
- package/dist/serialization/resources/users/types/UserAccountUpdatedPayloadPayloadData.js +46 -0
- package/dist/serialization/resources/users/types/UsersListRequestSort.js +17 -7
- package/dist/serialization/resources/users/types/index.d.ts +9 -1
- package/dist/serialization/resources/users/types/index.js +9 -1
- package/dist/serialization/resources/workspaces/resources/auditLogs/types/AuditLogsGetWorkspaceAuditLogsRequestEventType.js +17 -7
- package/dist/serialization/resources/workspaces/resources/auditLogs/types/AuditLogsGetWorkspaceAuditLogsRequestSortOrder.js +17 -7
- package/dist/serialization/resources/workspaces/resources/index.js +17 -7
- package/dist/serialization/types/AccessGroup.js +17 -7
- package/dist/serialization/types/AccessGroupList.js +17 -7
- package/dist/serialization/types/Application.d.ts +7 -2
- package/dist/serialization/types/Application.js +23 -8
- package/dist/serialization/types/Asset.d.ts +2 -2
- package/dist/serialization/types/Asset.js +19 -9
- package/dist/serialization/types/AssetFolder.js +17 -7
- package/dist/serialization/types/AssetFolderList.js +17 -7
- package/dist/serialization/types/AssetUpload.js +17 -7
- package/dist/serialization/types/AssetUploadUploadDetails.js +17 -7
- package/dist/serialization/types/AssetVariant.d.ts +6 -6
- package/dist/serialization/types/AssetVariant.js +23 -13
- package/dist/serialization/types/Assets.js +17 -7
- package/dist/serialization/types/Authorization.d.ts +1 -1
- package/dist/serialization/types/Authorization.js +17 -7
- package/dist/serialization/types/AuthorizationAuthorization.js +17 -7
- package/dist/serialization/types/AuthorizationAuthorizationAuthorizedTo.js +17 -7
- package/dist/serialization/types/AuthorizedUser.js +17 -7
- package/dist/serialization/types/BadRequestErrorBody.js +17 -7
- package/dist/serialization/types/BulkCollectionItem.d.ts +1 -1
- package/dist/serialization/types/BulkCollectionItem.js +18 -8
- package/dist/serialization/types/BulkCollectionItemFieldData.js +17 -7
- package/dist/serialization/types/Collection.d.ts +2 -2
- package/dist/serialization/types/Collection.js +19 -9
- package/dist/serialization/types/CollectionItem.js +17 -7
- package/dist/serialization/types/CollectionItemChanged.d.ts +14 -0
- package/dist/serialization/types/CollectionItemChanged.js +45 -0
- package/dist/serialization/types/CollectionItemCreated.d.ts +14 -0
- package/dist/serialization/types/CollectionItemCreated.js +45 -0
- package/dist/serialization/types/CollectionItemFieldData.js +17 -7
- package/dist/serialization/types/CollectionItemList.js +17 -7
- package/dist/serialization/types/CollectionItemListNoPagination.js +17 -7
- package/dist/serialization/types/CollectionItemListPagination.js +17 -7
- package/dist/serialization/types/CollectionItemPatchSingle.js +17 -7
- package/dist/serialization/types/CollectionItemPatchSingleFieldData.js +17 -7
- package/dist/serialization/types/CollectionItemPostSingle.js +17 -7
- package/dist/serialization/types/CollectionItemPostSingleFieldData.js +17 -7
- package/dist/serialization/types/CollectionItemPublished.d.ts +14 -0
- package/dist/serialization/types/CollectionItemPublished.js +45 -0
- package/dist/serialization/types/CollectionItemRemoved.d.ts +14 -0
- package/dist/serialization/types/CollectionItemRemoved.js +45 -0
- package/dist/serialization/types/CollectionItemRemovedPayload.d.ts +23 -0
- package/dist/serialization/types/CollectionItemRemovedPayload.js +54 -0
- package/dist/serialization/types/CollectionItemRemovedPayloadFieldData.d.ts +14 -0
- package/dist/serialization/types/CollectionItemRemovedPayloadFieldData.js +46 -0
- package/dist/serialization/types/CollectionItemUnpublished.d.ts +14 -0
- package/dist/serialization/types/CollectionItemUnpublished.js +45 -0
- package/dist/serialization/types/CollectionItemUnpublishedPayload.d.ts +23 -0
- package/dist/serialization/types/CollectionItemUnpublishedPayload.js +54 -0
- package/dist/serialization/types/CollectionItemUnpublishedPayloadFieldData.d.ts +14 -0
- package/dist/serialization/types/CollectionItemUnpublishedPayloadFieldData.js +46 -0
- package/dist/serialization/types/CollectionItemWithIdInput.js +17 -7
- package/dist/serialization/types/CollectionItemWithIdInputFieldData.js +17 -7
- package/dist/serialization/types/CollectionList.js +17 -7
- package/dist/serialization/types/CollectionListArrayItem.js +17 -7
- package/dist/serialization/types/Comment.d.ts +14 -0
- package/dist/serialization/types/Comment.js +45 -0
- package/dist/serialization/types/CommentPayload.d.ts +28 -0
- package/dist/serialization/types/CommentPayload.js +59 -0
- package/dist/serialization/types/CommentPayloadAuthor.d.ts +14 -0
- package/dist/serialization/types/CommentPayloadAuthor.js +45 -0
- package/dist/serialization/types/CommentPayloadMentionedUsersItem.d.ts +14 -0
- package/dist/serialization/types/CommentPayloadMentionedUsersItem.js +45 -0
- package/dist/serialization/types/CommentReply.d.ts +2 -2
- package/dist/serialization/types/CommentReply.js +19 -9
- package/dist/serialization/types/CommentReplyAuthor.js +17 -7
- package/dist/serialization/types/CommentReplyList.js +17 -7
- package/dist/serialization/types/CommentReplyListPagination.js +17 -7
- package/dist/serialization/types/CommentReplyMentionedUsersItem.js +17 -7
- package/dist/serialization/types/CommentThread.js +17 -7
- package/dist/serialization/types/CommentThreadAuthor.js +17 -7
- package/dist/serialization/types/CommentThreadList.js +17 -7
- package/dist/serialization/types/CommentThreadListPagination.js +17 -7
- package/dist/serialization/types/CommentThreadMentionedUsersItem.js +17 -7
- package/dist/serialization/types/Component.js +17 -7
- package/dist/serialization/types/ComponentDom.js +17 -7
- package/dist/serialization/types/ComponentInstanceNodePropertyOverridesWrite.js +17 -7
- package/dist/serialization/types/ComponentInstanceNodePropertyOverridesWritePropertyOverridesItem.js +17 -7
- package/dist/serialization/types/ComponentList.js +17 -7
- package/dist/serialization/types/ComponentNode.d.ts +3 -3
- package/dist/serialization/types/ComponentNode.js +20 -10
- package/dist/serialization/types/ComponentProperties.js +17 -7
- package/dist/serialization/types/ComponentProperty.js +17 -7
- package/dist/serialization/types/ComponentPropertyType.js +17 -7
- package/dist/serialization/types/Conflict.js +17 -7
- package/dist/serialization/types/ConflictErrorBody.js +17 -7
- package/dist/serialization/types/CustomCodeBlock.js +17 -7
- package/dist/serialization/types/CustomCodeBlockType.js +17 -7
- package/dist/serialization/types/CustomCodeHostedResponse.js +17 -7
- package/dist/serialization/types/CustomCodeInlineResponse.js +17 -7
- package/dist/serialization/types/CustomRole.js +17 -7
- package/dist/serialization/types/CustomRoleAuditLogItem.js +17 -7
- package/dist/serialization/types/CustomRoleAuditLogItemEventSubType.js +17 -7
- package/dist/serialization/types/Dom.d.ts +1 -0
- package/dist/serialization/types/Dom.js +18 -7
- package/dist/serialization/types/Domain.js +17 -7
- package/dist/serialization/types/Domains.js +17 -7
- package/dist/serialization/types/DuplicateUserEmail.js +17 -7
- package/dist/serialization/types/EcommerceSettings.js +17 -7
- package/dist/serialization/types/ErrorCode.js +17 -7
- package/dist/serialization/types/Error_.js +17 -7
- package/dist/serialization/types/Field.d.ts +2 -0
- package/dist/serialization/types/Field.js +19 -7
- package/dist/serialization/types/FieldCreate.js +17 -7
- package/dist/serialization/types/FieldType.js +17 -7
- package/dist/serialization/types/FieldValidations.d.ts +13 -0
- package/dist/serialization/types/FieldValidations.js +44 -0
- package/dist/serialization/types/FieldValidationsAdditionalProperties.d.ts +11 -0
- package/dist/serialization/types/FieldValidationsAdditionalProperties.js +48 -0
- package/dist/serialization/types/FieldValidationsAdditionalPropertiesAdditionalProperties.d.ts +12 -0
- package/dist/serialization/types/FieldValidationsAdditionalPropertiesAdditionalProperties.js +43 -0
- package/dist/serialization/types/ForbiddenErrorBody.js +17 -7
- package/dist/serialization/types/Form.js +17 -7
- package/dist/serialization/types/FormField.js +17 -7
- package/dist/serialization/types/FormFieldValue.js +17 -7
- package/dist/serialization/types/FormFieldValueType.js +17 -7
- package/dist/serialization/types/FormList.js +17 -7
- package/dist/serialization/types/FormResponseSettings.js +17 -7
- package/dist/serialization/types/FormSubmission.js +17 -7
- package/dist/serialization/types/FormSubmissionList.js +17 -7
- package/dist/serialization/types/FormSubmissionTrigger.d.ts +14 -0
- package/dist/serialization/types/FormSubmissionTrigger.js +45 -0
- package/dist/serialization/types/FormSubmissionTriggerPayload.d.ts +20 -0
- package/dist/serialization/types/FormSubmissionTriggerPayload.js +51 -0
- package/dist/serialization/types/FormSubmissionTriggerPayloadSchemaItem.d.ts +15 -0
- package/dist/serialization/types/FormSubmissionTriggerPayloadSchemaItem.js +46 -0
- package/dist/serialization/types/FormSubmissionTriggerPayloadSchemaItemFieldType.d.ts +10 -0
- package/dist/serialization/types/FormSubmissionTriggerPayloadSchemaItemFieldType.js +47 -0
- package/dist/serialization/types/ImageNode.d.ts +2 -2
- package/dist/serialization/types/ImageNode.js +19 -9
- package/dist/serialization/types/ImageNodeImage.js +17 -7
- package/dist/serialization/types/InvalidDomain.js +17 -7
- package/dist/serialization/types/InvalidScopes.js +17 -7
- package/dist/serialization/types/InventoryItem.js +17 -7
- package/dist/serialization/types/InventoryItemInventoryType.js +17 -7
- package/dist/serialization/types/ItemsListItemsLiveRequestLastPublished.d.ts +13 -0
- package/dist/serialization/types/ItemsListItemsLiveRequestLastPublished.js +44 -0
- package/dist/serialization/types/ItemsListItemsRequestLastPublished.d.ts +13 -0
- package/dist/serialization/types/ItemsListItemsRequestLastPublished.js +44 -0
- package/dist/serialization/types/ListCustomCodeBlocks.js +17 -7
- package/dist/serialization/types/Locale.js +17 -7
- package/dist/serialization/types/Locales.js +17 -7
- package/dist/serialization/types/Metadata.js +17 -7
- package/dist/serialization/types/MetadataOptionsItem.js +17 -7
- package/dist/serialization/types/NewOrder.d.ts +14 -0
- package/dist/serialization/types/NewOrder.js +45 -0
- package/dist/serialization/types/NoDomains.js +17 -7
- package/dist/serialization/types/Node.js +17 -7
- package/dist/serialization/types/NotEnterprisePlanSite.js +17 -7
- package/dist/serialization/types/NotEnterprisePlanWorkspace.js +17 -7
- package/dist/serialization/types/OptionField.js +17 -7
- package/dist/serialization/types/Order.d.ts +4 -2
- package/dist/serialization/types/Order.js +21 -9
- package/dist/serialization/types/OrderAddress.js +17 -7
- package/dist/serialization/types/OrderAddressJapanType.js +17 -7
- package/dist/serialization/types/OrderAddressType.js +17 -7
- package/dist/serialization/types/OrderBillingAddress.d.ts +22 -0
- package/dist/serialization/types/OrderBillingAddress.js +53 -0
- package/dist/serialization/types/OrderBillingAddressJapanType.d.ts +10 -0
- package/dist/serialization/types/OrderBillingAddressJapanType.js +41 -0
- package/dist/serialization/types/OrderBillingAddressType.d.ts +10 -0
- package/dist/serialization/types/OrderBillingAddressType.js +41 -0
- package/dist/serialization/types/OrderCustomerInfo.js +17 -7
- package/dist/serialization/types/OrderDisputeLastStatus.js +17 -7
- package/dist/serialization/types/OrderDownloadFilesItem.js +17 -7
- package/dist/serialization/types/OrderList.js +17 -7
- package/dist/serialization/types/OrderMetadata.js +17 -7
- package/dist/serialization/types/OrderPrice.js +17 -7
- package/dist/serialization/types/OrderPurchasedItem.js +17 -7
- package/dist/serialization/types/OrderPurchasedItemVariantImage.js +17 -7
- package/dist/serialization/types/OrderPurchasedItemVariantImageFile.js +17 -7
- package/dist/serialization/types/OrderPurchasedItemVariantImageFileVariantsItem.js +17 -7
- package/dist/serialization/types/OrderShippingAddress.d.ts +22 -0
- package/dist/serialization/types/OrderShippingAddress.js +53 -0
- package/dist/serialization/types/OrderShippingAddressJapanType.d.ts +10 -0
- package/dist/serialization/types/OrderShippingAddressJapanType.js +41 -0
- package/dist/serialization/types/OrderShippingAddressType.d.ts +10 -0
- package/dist/serialization/types/OrderShippingAddressType.js +41 -0
- package/dist/serialization/types/OrderStatus.js +17 -7
- package/dist/serialization/types/OrderTotals.js +17 -7
- package/dist/serialization/types/OrderTotalsExtrasItem.js +17 -7
- package/dist/serialization/types/OrderTotalsExtrasItemType.js +17 -7
- package/dist/serialization/types/Page.d.ts +1 -0
- package/dist/serialization/types/Page.js +18 -7
- package/dist/serialization/types/PageCreatedWebhook.d.ts +14 -0
- package/dist/serialization/types/PageCreatedWebhook.js +45 -0
- package/dist/serialization/types/PageCreatedWebhookPayload.d.ts +16 -0
- package/dist/serialization/types/PageCreatedWebhookPayload.js +47 -0
- package/dist/serialization/types/PageDeletedWebhook.d.ts +14 -0
- package/dist/serialization/types/PageDeletedWebhook.js +45 -0
- package/dist/serialization/types/PageDeletedWebhookPayload.d.ts +16 -0
- package/dist/serialization/types/PageDeletedWebhookPayload.js +47 -0
- package/dist/serialization/types/PageList.js +17 -7
- package/dist/serialization/types/PageMetadataUpdatedWebhook.d.ts +14 -0
- package/dist/serialization/types/PageMetadataUpdatedWebhook.js +45 -0
- package/dist/serialization/types/PageMetadataUpdatedWebhookPayload.d.ts +16 -0
- package/dist/serialization/types/PageMetadataUpdatedWebhookPayload.js +47 -0
- package/dist/serialization/types/PageOpenGraph.js +17 -7
- package/dist/serialization/types/PageSeo.js +17 -7
- package/dist/serialization/types/Pagination.js +17 -7
- package/dist/serialization/types/Payload.d.ts +23 -0
- package/dist/serialization/types/Payload.js +54 -0
- package/dist/serialization/types/PayloadFieldData.d.ts +14 -0
- package/dist/serialization/types/PayloadFieldData.js +46 -0
- package/dist/serialization/types/PaypalDetails.js +17 -7
- package/dist/serialization/types/Product.js +17 -7
- package/dist/serialization/types/ProductAndSkUs.js +17 -7
- package/dist/serialization/types/ProductAndSkUsList.js +17 -7
- package/dist/serialization/types/ProductFieldData.d.ts +1 -1
- package/dist/serialization/types/ProductFieldData.js +18 -8
- package/dist/serialization/types/ProductFieldDataEcProductType.js +17 -7
- package/dist/serialization/types/ProductFieldDataTaxCategory.js +17 -7
- package/dist/serialization/types/PublishStatus.js +17 -7
- package/dist/serialization/types/Redirect.js +17 -7
- package/dist/serialization/types/Redirects.js +17 -7
- package/dist/serialization/types/ReferenceField.js +17 -7
- package/dist/serialization/types/ReferenceFieldMetadata.js +17 -7
- package/dist/serialization/types/ReferenceFieldType.js +17 -7
- package/dist/serialization/types/RegisteredScriptList.d.ts +2 -0
- package/dist/serialization/types/RegisteredScriptList.js +19 -7
- package/dist/serialization/types/Robots.js +17 -7
- package/dist/serialization/types/RobotsRulesItem.js +17 -7
- package/dist/serialization/types/ScriptApply.js +17 -7
- package/dist/serialization/types/ScriptApplyList.js +17 -7
- package/dist/serialization/types/ScriptApplyLocation.js +17 -7
- package/dist/serialization/types/Scripts.js +17 -7
- package/dist/serialization/types/SearchButtonNode.js +17 -7
- package/dist/serialization/types/SearchButtonNodeWrite.js +17 -7
- package/{serialization/types/SelectNodeWrite.d.ts → dist/serialization/types/Select.d.ts} +2 -2
- package/{serialization/types/SelectNodeWrite.js → dist/serialization/types/Select.js} +19 -9
- package/dist/serialization/types/SelectNode.js +17 -7
- package/dist/serialization/types/SelectNodeChoicesItem.js +17 -7
- package/dist/serialization/types/SelectNodeWriteChoicesItem.js +17 -7
- package/dist/serialization/types/SingleLocaleCreatedPayload.d.ts +23 -0
- package/dist/serialization/types/SingleLocaleCreatedPayload.js +54 -0
- package/dist/serialization/types/SingleLocaleCreatedPayloadFieldData.d.ts +14 -0
- package/dist/serialization/types/SingleLocaleCreatedPayloadFieldData.js +46 -0
- package/dist/serialization/types/Site.js +17 -7
- package/dist/serialization/types/SiteActivityLogItem.js +17 -7
- package/dist/serialization/types/SiteActivityLogItemEvent.js +17 -7
- package/dist/serialization/types/SiteActivityLogItemResourceOperation.js +17 -7
- package/dist/serialization/types/SiteActivityLogItemUser.js +17 -7
- package/dist/serialization/types/SiteActivityLogResponse.js +17 -7
- package/dist/serialization/types/SiteDataCollectionType.js +17 -7
- package/dist/serialization/types/SiteMembership.d.ts +2 -0
- package/dist/serialization/types/SiteMembership.js +19 -7
- package/dist/serialization/types/SiteMembershipAuditLogItem.js +17 -7
- package/dist/serialization/types/SiteMembershipAuditLogItemEventSubType.d.ts +1 -1
- package/dist/serialization/types/SiteMembershipAuditLogItemEventSubType.js +18 -8
- package/dist/serialization/types/SitePlan.js +17 -7
- package/dist/serialization/types/SitePlanId.js +17 -7
- package/dist/serialization/types/SitePlanName.js +17 -7
- package/dist/serialization/types/SitePublish.d.ts +14 -0
- package/dist/serialization/types/SitePublish.js +45 -0
- package/dist/serialization/types/SitePublishPayload.d.ts +15 -0
- package/dist/serialization/types/SitePublishPayload.js +46 -0
- package/dist/serialization/types/Sites.js +17 -7
- package/dist/serialization/types/Sku.js +17 -7
- package/dist/serialization/types/SkuFieldData.d.ts +0 -2
- package/dist/serialization/types/SkuFieldData.js +17 -9
- package/dist/serialization/types/SkuFieldDataCompareAtPrice.js +17 -7
- package/dist/serialization/types/SkuFieldDataEcSkuBillingMethod.js +17 -7
- package/dist/serialization/types/SkuFieldDataEcSkuSubscriptionPlan.js +17 -7
- package/dist/serialization/types/SkuFieldDataEcSkuSubscriptionPlanInterval.js +17 -7
- package/dist/serialization/types/SkuFieldDataEcSkuSubscriptionPlanPlansItem.js +17 -7
- package/dist/serialization/types/SkuFieldDataEcSkuSubscriptionPlanPlansItemStatus.js +17 -7
- package/dist/serialization/types/SkuFieldDataPrice.js +17 -7
- package/dist/serialization/types/SkuPropertyList.js +17 -7
- package/dist/serialization/types/SkuPropertyListEnumItem.js +17 -7
- package/dist/serialization/types/SkuValueList.js +17 -7
- package/dist/serialization/types/StaticField.js +17 -7
- package/dist/serialization/types/StaticFieldType.js +17 -7
- package/dist/serialization/types/StripeCard.js +17 -7
- package/dist/serialization/types/StripeCardBrand.js +17 -7
- package/dist/serialization/types/StripeCardExpires.js +17 -7
- package/dist/serialization/types/StripeDetails.js +17 -7
- package/dist/serialization/types/SubmitButtonNode.js +17 -7
- package/dist/serialization/types/SubmitButtonNodeWrite.js +17 -7
- package/dist/serialization/types/Text.js +17 -7
- package/dist/serialization/types/TextInputNode.js +17 -7
- package/dist/serialization/types/TextInputNodeWrite.js +17 -7
- package/dist/serialization/types/TextNode.d.ts +2 -2
- package/dist/serialization/types/TextNode.js +19 -9
- package/dist/serialization/types/TextNodeText.js +17 -7
- package/dist/serialization/types/TextNodeWrite.js +17 -7
- package/dist/serialization/types/TriggerType.d.ts +1 -1
- package/dist/serialization/types/TriggerType.js +18 -7
- package/dist/serialization/types/UpdatedOrder.d.ts +14 -0
- package/dist/serialization/types/UpdatedOrder.js +45 -0
- package/dist/serialization/types/User.js +17 -7
- package/dist/serialization/types/UserAccess.js +17 -7
- package/dist/serialization/types/UserAccessAuditLogItem.js +17 -7
- package/dist/serialization/types/UserAccessAuditLogItemEventSubType.js +17 -7
- package/dist/serialization/types/UserAccessGroupsItem.js +17 -7
- package/dist/serialization/types/UserAccessGroupsItemType.js +17 -7
- package/dist/serialization/types/UserData.js +17 -7
- package/dist/serialization/types/UserDataData.js +17 -7
- package/dist/serialization/types/UserLimitReached.js +17 -7
- package/dist/serialization/types/UserList.js +17 -7
- package/dist/serialization/types/UserStatus.js +17 -7
- package/dist/serialization/types/UsersNotEnabled.js +17 -7
- package/dist/serialization/types/Webhook.js +17 -7
- package/dist/serialization/types/WebhookFilter.js +17 -7
- package/dist/serialization/types/WebhookList.js +17 -7
- package/dist/serialization/types/WorkspaceAuditLogItem.js +17 -7
- package/dist/serialization/types/WorkspaceAuditLogItemActor.js +17 -7
- package/dist/serialization/types/WorkspaceAuditLogItemPayloadSiteMembershipGranularAccess.d.ts +15 -0
- package/dist/serialization/types/WorkspaceAuditLogItemPayloadSiteMembershipGranularAccess.js +46 -0
- package/dist/serialization/types/WorkspaceAuditLogItemPayloadSiteMembershipMethod.d.ts +1 -1
- package/dist/serialization/types/WorkspaceAuditLogItemPayloadSiteMembershipMethod.js +18 -8
- package/dist/serialization/types/WorkspaceAuditLogItemPayloadSiteMembershipSite.js +17 -7
- package/dist/serialization/types/WorkspaceAuditLogItemPayloadSiteMembershipTargetUser.js +17 -7
- package/dist/serialization/types/WorkspaceAuditLogItemPayloadSiteMembershipUserType.js +17 -7
- package/dist/serialization/types/WorkspaceAuditLogItemPayloadUserAccessMethod.js +17 -7
- package/dist/serialization/types/WorkspaceAuditLogItemPayloadWorkspaceInvitationMethod.js +17 -7
- package/dist/serialization/types/WorkspaceAuditLogItemPayloadWorkspaceInvitationTargetUser.js +17 -7
- package/dist/serialization/types/WorkspaceAuditLogItemPayloadWorkspaceInvitationTargetUsersItem.d.ts +13 -0
- package/dist/serialization/types/WorkspaceAuditLogItemPayloadWorkspaceInvitationTargetUsersItem.js +44 -0
- package/dist/serialization/types/WorkspaceAuditLogItemPayloadWorkspaceInvitationUserType.js +17 -7
- package/dist/serialization/types/WorkspaceAuditLogItemPayloadWorkspaceMembershipMethod.d.ts +1 -1
- package/dist/serialization/types/WorkspaceAuditLogItemPayloadWorkspaceMembershipMethod.js +18 -8
- package/dist/serialization/types/WorkspaceAuditLogItemPayloadWorkspaceMembershipTargetUser.js +17 -7
- package/dist/serialization/types/WorkspaceAuditLogItemPayloadWorkspaceMembershipUserType.js +17 -7
- package/dist/serialization/types/WorkspaceAuditLogItemWorkspace.js +17 -7
- package/dist/serialization/types/WorkspaceAuditLogResponse.js +17 -7
- package/dist/serialization/types/WorkspaceInvitation.d.ts +2 -0
- package/dist/serialization/types/WorkspaceInvitation.js +19 -7
- package/dist/serialization/types/WorkspaceInvitationAuditLogItem.js +17 -7
- package/dist/serialization/types/WorkspaceInvitationAuditLogItemEventSubType.d.ts +1 -1
- package/dist/serialization/types/WorkspaceInvitationAuditLogItemEventSubType.js +18 -7
- package/dist/serialization/types/WorkspaceMembership.js +17 -7
- package/dist/serialization/types/WorkspaceMembershipAuditLogItem.js +17 -7
- package/dist/serialization/types/WorkspaceMembershipAuditLogItemEventSubType.js +17 -7
- package/dist/serialization/types/index.d.ts +47 -3
- package/dist/serialization/types/index.js +47 -3
- package/dist/version.d.ts +1 -1
- package/dist/version.js +1 -1
- package/dist/wrapper/AssetsClient.d.ts +24 -0
- package/dist/wrapper/AssetsClient.js +42 -0
- package/dist/wrapper/AssetsUtilitiesClient.d.ts +1 -1
- package/dist/wrapper/CollectionsClient.d.ts +11 -0
- package/dist/wrapper/CollectionsClient.js +18 -0
- package/dist/wrapper/ItemsClient.d.ts +167 -0
- package/dist/wrapper/ItemsClient.js +630 -0
- package/dist/wrapper/PagesClient.d.ts +49 -0
- package/dist/wrapper/PagesClient.js +214 -0
- package/dist/wrapper/WebflowClient.d.ts +6 -0
- package/dist/wrapper/WebflowClient.js +29 -9
- package/dist/wrapper/WebhooksClient.d.ts +0 -1
- package/dist/wrapper/WebhooksClient.js +2 -5
- package/dist/wrapper/schemas/ItemsCreateItemLiveRequest.d.ts +4 -0
- package/dist/wrapper/schemas/ItemsCreateItemLiveRequest.js +2 -0
- package/dist/wrapper/schemas/ItemsCreateItemRequest.d.ts +4 -0
- package/dist/wrapper/schemas/ItemsCreateItemRequest.js +2 -0
- package/dist/wrapper/schemas/ItemsUpdateItemLiveRequest.d.ts +4 -0
- package/dist/wrapper/schemas/ItemsUpdateItemLiveRequest.js +2 -0
- package/dist/wrapper/schemas/ItemsUpdateItemRequest.d.ts +4 -0
- package/dist/wrapper/schemas/ItemsUpdateItemRequest.js +2 -0
- package/{api/resources/pages/client/requests/UpdatePageSettingsRequest.d.ts → dist/wrapper/schemas/PageMetadataWrite.d.ts} +13 -17
- package/dist/wrapper/schemas/PageMetadataWrite.js +2 -0
- package/dist/wrapper/schemas/index.d.ts +5 -0
- package/dist/wrapper/schemas/index.js +21 -0
- package/environments.d.ts +1 -5
- package/environments.js +0 -2
- package/errors/WebflowError.d.ts +4 -1
- package/errors/WebflowError.js +6 -8
- package/index.js +17 -7
- package/jest.config.mjs +9 -0
- package/package.json +25 -20
- package/reference.md +259 -131
- package/scripts/rename-to-esm-files.js +123 -0
- package/serialization/resources/accessGroups/types/AccessGroupsListRequestSort.js +17 -7
- package/serialization/resources/assets/client/requests/AssetsCreateFolderRequest.js +17 -7
- package/serialization/resources/assets/client/requests/AssetsCreateRequest.js +17 -7
- package/serialization/resources/assets/client/requests/AssetsUpdateRequest.js +17 -7
- package/serialization/resources/collections/client/requests/CollectionsCreateRequest.js +17 -7
- package/serialization/resources/collections/resources/fields/client/requests/FieldUpdate.js +17 -7
- package/serialization/resources/collections/resources/index.js +17 -7
- package/serialization/resources/collections/resources/items/client/requests/CreateBulkCollectionItemRequestBody.d.ts +1 -1
- package/serialization/resources/collections/resources/items/client/requests/CreateBulkCollectionItemRequestBody.js +17 -7
- package/serialization/resources/collections/resources/items/client/requests/ItemsDeleteItemsLiveRequest.js +17 -7
- package/serialization/resources/collections/resources/items/client/requests/ItemsDeleteItemsRequest.js +17 -7
- package/serialization/resources/collections/resources/items/client/requests/ItemsUpdateItemsLiveRequest.d.ts +1 -1
- package/serialization/resources/collections/resources/items/client/requests/ItemsUpdateItemsLiveRequest.js +17 -7
- package/serialization/resources/collections/resources/items/client/requests/ItemsUpdateItemsRequest.d.ts +1 -1
- package/serialization/resources/collections/resources/items/client/requests/ItemsUpdateItemsRequest.js +17 -7
- package/serialization/resources/collections/resources/items/client/requests/index.d.ts +0 -1
- package/serialization/resources/collections/resources/items/client/requests/index.js +1 -3
- package/serialization/resources/collections/resources/items/types/CreateBulkCollectionItemRequestBodyFieldData.js +17 -7
- package/serialization/resources/collections/resources/items/types/CreateBulkCollectionItemRequestBodyFieldDataItem.js +17 -7
- package/serialization/resources/collections/resources/items/types/ItemIDs.d.ts +12 -0
- package/{dist/serialization/resources/collections/resources/items/client/requests/ItemsPublishItemRequest.js → serialization/resources/collections/resources/items/types/ItemIDs.js} +21 -11
- package/serialization/resources/collections/resources/items/types/ItemIDsWithLocales.d.ts +13 -0
- package/serialization/resources/collections/resources/items/types/ItemIDsWithLocales.js +44 -0
- package/serialization/resources/collections/resources/items/types/{ItemsCreateItemLiveRequest.d.ts → ItemsCreateItemLiveRequestBody.d.ts} +2 -2
- package/{dist/serialization/resources/collections/resources/items/types/ItemsCreateItemLiveRequest.js → serialization/resources/collections/resources/items/types/ItemsCreateItemLiveRequestBody.js} +19 -9
- package/serialization/resources/collections/resources/items/types/{ItemsCreateItemRequest.d.ts → ItemsCreateItemRequestBody.d.ts} +2 -2
- package/serialization/resources/collections/resources/items/types/{ItemsCreateItemRequest.js → ItemsCreateItemRequestBody.js} +19 -9
- package/serialization/resources/collections/resources/items/types/ItemsDeleteItemsLiveRequestItemsItem.js +17 -7
- package/serialization/resources/collections/resources/items/types/ItemsDeleteItemsRequestItemsItem.js +17 -7
- package/serialization/resources/collections/resources/items/types/ItemsListItemsLiveRequestSortBy.js +17 -7
- package/serialization/resources/collections/resources/items/types/ItemsListItemsLiveRequestSortOrder.js +17 -7
- package/serialization/resources/collections/resources/items/types/ItemsListItemsRequestSortBy.js +17 -7
- package/serialization/resources/collections/resources/items/types/ItemsListItemsRequestSortOrder.js +17 -7
- package/serialization/resources/collections/resources/items/types/ItemsPublishItemRequest.d.ts +12 -0
- package/serialization/resources/collections/resources/items/types/ItemsPublishItemRequest.js +43 -0
- package/serialization/resources/collections/resources/items/types/ItemsPublishItemRequestItemsItemsItem.d.ts +13 -0
- package/serialization/resources/collections/resources/items/types/ItemsPublishItemRequestItemsItemsItem.js +44 -0
- package/serialization/resources/collections/resources/items/types/ItemsPublishItemResponse.js +17 -7
- package/serialization/resources/collections/resources/items/types/ItemsUpdateItemsResponse.d.ts +12 -0
- package/serialization/resources/collections/resources/items/types/ItemsUpdateItemsResponse.js +43 -0
- package/serialization/resources/collections/resources/items/types/MultipleItems.js +17 -7
- package/serialization/resources/collections/resources/items/types/MultipleLiveItems.js +17 -7
- package/serialization/resources/collections/resources/items/types/SingleCmsItem.js +17 -7
- package/serialization/resources/collections/resources/items/types/index.d.ts +7 -2
- package/serialization/resources/collections/resources/items/types/index.js +7 -2
- package/serialization/resources/components/client/requests/ComponentDomWrite.d.ts +1 -1
- package/serialization/resources/components/client/requests/ComponentDomWrite.js +17 -7
- package/serialization/resources/components/client/requests/ComponentPropertiesWrite.d.ts +1 -1
- package/serialization/resources/components/client/requests/ComponentPropertiesWrite.js +17 -7
- package/serialization/resources/components/types/ComponentDomWriteNodesItem.d.ts +2 -2
- package/serialization/resources/components/types/ComponentDomWriteNodesItem.js +19 -9
- package/serialization/resources/components/types/ComponentPropertiesWritePropertiesItem.js +17 -7
- package/serialization/resources/components/types/ComponentsUpdateContentResponse.js +17 -7
- package/serialization/resources/components/types/ComponentsUpdatePropertiesResponse.js +17 -7
- package/serialization/resources/forms/client/requests/FormsUpdateSubmissionRequest.js +17 -7
- package/serialization/resources/index.js +17 -7
- package/serialization/resources/inventory/client/requests/InventoryUpdateRequest.js +17 -7
- package/serialization/resources/inventory/types/EcommInventoryChangedPayload.d.ts +14 -0
- package/serialization/resources/inventory/types/EcommInventoryChangedPayload.js +45 -0
- package/serialization/resources/inventory/types/InventoryUpdateRequestInventoryType.js +17 -7
- package/serialization/resources/inventory/types/index.d.ts +1 -0
- package/serialization/resources/inventory/types/index.js +1 -0
- package/serialization/resources/orders/client/requests/OrdersRefundRequest.js +17 -7
- package/serialization/resources/orders/client/requests/OrdersUpdateFulfillRequest.js +17 -7
- package/serialization/resources/orders/client/requests/OrdersUpdateRequest.js +17 -7
- package/serialization/resources/orders/types/OrdersListRequestStatus.js +17 -7
- package/serialization/resources/orders/types/OrdersRefundRequestReason.js +17 -7
- package/serialization/resources/pages/client/requests/PageDomWrite.js +17 -7
- package/serialization/resources/pages/client/requests/PageMetadataWrite.d.ts +17 -0
- package/serialization/resources/pages/client/requests/PageMetadataWrite.js +48 -0
- package/serialization/resources/pages/client/requests/index.d.ts +1 -0
- package/serialization/resources/pages/client/requests/index.js +3 -1
- package/serialization/resources/pages/types/PageDomWriteNodesItem.d.ts +2 -2
- package/serialization/resources/pages/types/PageDomWriteNodesItem.js +19 -9
- package/serialization/resources/pages/types/PageMetadataWriteOpenGraph.d.ts +15 -0
- package/serialization/resources/pages/types/PageMetadataWriteOpenGraph.js +46 -0
- package/serialization/resources/pages/types/PageMetadataWriteSeo.d.ts +13 -0
- package/serialization/resources/pages/types/PageMetadataWriteSeo.js +44 -0
- package/serialization/resources/pages/types/UpdateStaticContentResponse.js +17 -7
- package/serialization/resources/pages/types/index.d.ts +2 -0
- package/serialization/resources/pages/types/index.js +2 -0
- package/serialization/resources/products/client/requests/ProductSkuCreate.js +17 -7
- package/serialization/resources/products/client/requests/ProductSkuUpdate.js +17 -7
- package/serialization/resources/products/client/requests/ProductsCreateSkuRequest.js +17 -7
- package/serialization/resources/products/client/requests/ProductsUpdateSkuRequest.js +17 -7
- package/serialization/resources/products/types/ProductSkuCreateProduct.js +17 -7
- package/serialization/resources/products/types/ProductSkuCreateSku.js +17 -7
- package/serialization/resources/products/types/ProductsCreateSkuResponse.d.ts +1 -1
- package/serialization/resources/products/types/ProductsCreateSkuResponse.js +18 -8
- package/serialization/resources/scripts/client/requests/CustomCodeHostedRequest.js +17 -7
- package/serialization/resources/scripts/client/requests/CustomCodeInlineRequest.js +17 -7
- package/serialization/resources/sites/client/requests/SitesCreateRequest.js +17 -7
- package/serialization/resources/sites/client/requests/SitesPublishRequest.js +17 -7
- package/serialization/resources/sites/client/requests/SitesUpdateRequest.js +17 -7
- package/serialization/resources/sites/resources/comments/types/CommentsGetCommentThreadRequestSortBy.js +17 -7
- package/serialization/resources/sites/resources/comments/types/CommentsGetCommentThreadRequestSortOrder.js +17 -7
- package/serialization/resources/sites/resources/comments/types/CommentsListCommentRepliesRequestSortBy.js +17 -7
- package/serialization/resources/sites/resources/comments/types/CommentsListCommentRepliesRequestSortOrder.js +17 -7
- package/serialization/resources/sites/resources/comments/types/CommentsListCommentThreadsRequestSortBy.js +17 -7
- package/serialization/resources/sites/resources/comments/types/CommentsListCommentThreadsRequestSortOrder.js +17 -7
- package/serialization/resources/sites/resources/index.js +17 -7
- package/serialization/resources/sites/resources/wellKnown/client/requests/WellKnownDeleteRequest.js +17 -7
- package/serialization/resources/sites/resources/wellKnown/client/requests/WellKnownFile.js +17 -7
- package/serialization/resources/sites/resources/wellKnown/types/WellKnownFileContentType.js +17 -7
- package/serialization/resources/sites/types/SitesPublishResponse.js +17 -7
- package/serialization/resources/users/client/requests/UsersInviteRequest.js +17 -7
- package/serialization/resources/users/client/requests/index.d.ts +0 -1
- package/serialization/resources/users/client/requests/index.js +1 -3
- package/serialization/resources/users/types/UserAccountAddedPayload.d.ts +14 -0
- package/serialization/resources/users/types/UserAccountAddedPayload.js +45 -0
- package/serialization/resources/users/types/UserAccountAddedPayloadPayload.d.ts +23 -0
- package/serialization/resources/users/types/UserAccountAddedPayloadPayload.js +54 -0
- package/serialization/resources/users/types/UserAccountAddedPayloadPayloadData.d.ts +15 -0
- package/serialization/resources/users/types/{UsersUpdateRequestData.js → UserAccountAddedPayloadPayloadData.js} +22 -11
- package/serialization/resources/users/types/UserAccountDeletedPayload.d.ts +14 -0
- package/serialization/resources/users/types/UserAccountDeletedPayload.js +45 -0
- package/serialization/resources/users/types/UserAccountDeletedPayloadPayload.d.ts +23 -0
- package/serialization/resources/users/types/UserAccountDeletedPayloadPayload.js +54 -0
- package/serialization/resources/users/types/UserAccountDeletedPayloadPayloadData.d.ts +15 -0
- package/serialization/resources/users/types/UserAccountDeletedPayloadPayloadData.js +46 -0
- package/serialization/resources/users/types/UserAccountUpdatedPayload.d.ts +14 -0
- package/serialization/resources/users/types/UserAccountUpdatedPayload.js +45 -0
- package/serialization/resources/users/types/UserAccountUpdatedPayloadPayload.d.ts +23 -0
- package/serialization/resources/users/types/UserAccountUpdatedPayloadPayload.js +54 -0
- package/serialization/resources/users/types/UserAccountUpdatedPayloadPayloadData.d.ts +15 -0
- package/serialization/resources/users/types/UserAccountUpdatedPayloadPayloadData.js +46 -0
- package/serialization/resources/users/types/UsersListRequestSort.js +17 -7
- package/serialization/resources/users/types/index.d.ts +9 -1
- package/serialization/resources/users/types/index.js +9 -1
- package/serialization/resources/workspaces/resources/auditLogs/types/AuditLogsGetWorkspaceAuditLogsRequestEventType.js +17 -7
- package/serialization/resources/workspaces/resources/auditLogs/types/AuditLogsGetWorkspaceAuditLogsRequestSortOrder.js +17 -7
- package/serialization/resources/workspaces/resources/index.js +17 -7
- package/serialization/types/AccessGroup.js +17 -7
- package/serialization/types/AccessGroupList.js +17 -7
- package/serialization/types/Application.d.ts +7 -2
- package/serialization/types/Application.js +23 -8
- package/serialization/types/Asset.d.ts +2 -2
- package/serialization/types/Asset.js +19 -9
- package/serialization/types/AssetFolder.js +17 -7
- package/serialization/types/AssetFolderList.js +17 -7
- package/serialization/types/AssetUpload.js +17 -7
- package/serialization/types/AssetUploadUploadDetails.js +17 -7
- package/serialization/types/AssetVariant.d.ts +6 -6
- package/serialization/types/AssetVariant.js +23 -13
- package/serialization/types/Assets.js +17 -7
- package/serialization/types/Authorization.d.ts +1 -1
- package/serialization/types/Authorization.js +17 -7
- package/serialization/types/AuthorizationAuthorization.js +17 -7
- package/serialization/types/AuthorizationAuthorizationAuthorizedTo.js +17 -7
- package/serialization/types/AuthorizedUser.js +17 -7
- package/serialization/types/BadRequestErrorBody.js +17 -7
- package/serialization/types/BulkCollectionItem.d.ts +1 -1
- package/serialization/types/BulkCollectionItem.js +18 -8
- package/serialization/types/BulkCollectionItemFieldData.js +17 -7
- package/serialization/types/Collection.d.ts +2 -2
- package/serialization/types/Collection.js +19 -9
- package/serialization/types/CollectionItem.js +17 -7
- package/serialization/types/CollectionItemChanged.d.ts +14 -0
- package/serialization/types/CollectionItemChanged.js +45 -0
- package/serialization/types/CollectionItemCreated.d.ts +14 -0
- package/serialization/types/CollectionItemCreated.js +45 -0
- package/serialization/types/CollectionItemFieldData.js +17 -7
- package/serialization/types/CollectionItemList.js +17 -7
- package/serialization/types/CollectionItemListNoPagination.js +17 -7
- package/serialization/types/CollectionItemListPagination.js +17 -7
- package/serialization/types/CollectionItemPatchSingle.js +17 -7
- package/serialization/types/CollectionItemPatchSingleFieldData.js +17 -7
- package/serialization/types/CollectionItemPostSingle.js +17 -7
- package/serialization/types/CollectionItemPostSingleFieldData.js +17 -7
- package/serialization/types/CollectionItemPublished.d.ts +14 -0
- package/serialization/types/CollectionItemPublished.js +45 -0
- package/serialization/types/CollectionItemRemoved.d.ts +14 -0
- package/serialization/types/CollectionItemRemoved.js +45 -0
- package/serialization/types/CollectionItemRemovedPayload.d.ts +23 -0
- package/serialization/types/CollectionItemRemovedPayload.js +54 -0
- package/serialization/types/CollectionItemRemovedPayloadFieldData.d.ts +14 -0
- package/serialization/types/CollectionItemRemovedPayloadFieldData.js +46 -0
- package/serialization/types/CollectionItemUnpublished.d.ts +14 -0
- package/serialization/types/CollectionItemUnpublished.js +45 -0
- package/serialization/types/CollectionItemUnpublishedPayload.d.ts +23 -0
- package/serialization/types/CollectionItemUnpublishedPayload.js +54 -0
- package/serialization/types/CollectionItemUnpublishedPayloadFieldData.d.ts +14 -0
- package/serialization/types/CollectionItemUnpublishedPayloadFieldData.js +46 -0
- package/serialization/types/CollectionItemWithIdInput.js +17 -7
- package/serialization/types/CollectionItemWithIdInputFieldData.js +17 -7
- package/serialization/types/CollectionList.js +17 -7
- package/serialization/types/CollectionListArrayItem.js +17 -7
- package/serialization/types/Comment.d.ts +14 -0
- package/serialization/types/Comment.js +45 -0
- package/serialization/types/CommentPayload.d.ts +28 -0
- package/serialization/types/CommentPayload.js +59 -0
- package/serialization/types/CommentPayloadAuthor.d.ts +14 -0
- package/serialization/types/CommentPayloadAuthor.js +45 -0
- package/serialization/types/CommentPayloadMentionedUsersItem.d.ts +14 -0
- package/serialization/types/CommentPayloadMentionedUsersItem.js +45 -0
- package/serialization/types/CommentReply.d.ts +2 -2
- package/serialization/types/CommentReply.js +19 -9
- package/serialization/types/CommentReplyAuthor.js +17 -7
- package/serialization/types/CommentReplyList.js +17 -7
- package/serialization/types/CommentReplyListPagination.js +17 -7
- package/serialization/types/CommentReplyMentionedUsersItem.js +17 -7
- package/serialization/types/CommentThread.js +17 -7
- package/serialization/types/CommentThreadAuthor.js +17 -7
- package/serialization/types/CommentThreadList.js +17 -7
- package/serialization/types/CommentThreadListPagination.js +17 -7
- package/serialization/types/CommentThreadMentionedUsersItem.js +17 -7
- package/serialization/types/Component.js +17 -7
- package/serialization/types/ComponentDom.js +17 -7
- package/serialization/types/ComponentInstanceNodePropertyOverridesWrite.js +17 -7
- package/serialization/types/ComponentInstanceNodePropertyOverridesWritePropertyOverridesItem.js +17 -7
- package/serialization/types/ComponentList.js +17 -7
- package/serialization/types/ComponentNode.d.ts +3 -3
- package/serialization/types/ComponentNode.js +20 -10
- package/serialization/types/ComponentProperties.js +17 -7
- package/serialization/types/ComponentProperty.js +17 -7
- package/serialization/types/ComponentPropertyType.js +17 -7
- package/serialization/types/Conflict.js +17 -7
- package/serialization/types/ConflictErrorBody.js +17 -7
- package/serialization/types/CustomCodeBlock.js +17 -7
- package/serialization/types/CustomCodeBlockType.js +17 -7
- package/serialization/types/CustomCodeHostedResponse.js +17 -7
- package/serialization/types/CustomCodeInlineResponse.js +17 -7
- package/serialization/types/CustomRole.js +17 -7
- package/serialization/types/CustomRoleAuditLogItem.js +17 -7
- package/serialization/types/CustomRoleAuditLogItemEventSubType.js +17 -7
- package/serialization/types/Dom.d.ts +1 -0
- package/serialization/types/Dom.js +18 -7
- package/serialization/types/Domain.js +17 -7
- package/serialization/types/Domains.js +17 -7
- package/serialization/types/DuplicateUserEmail.js +17 -7
- package/serialization/types/EcommerceSettings.js +17 -7
- package/serialization/types/ErrorCode.js +17 -7
- package/serialization/types/Error_.js +17 -7
- package/serialization/types/Field.d.ts +2 -0
- package/serialization/types/Field.js +19 -7
- package/serialization/types/FieldCreate.js +17 -7
- package/serialization/types/FieldType.js +17 -7
- package/serialization/types/FieldValidations.d.ts +13 -0
- package/serialization/types/FieldValidations.js +44 -0
- package/serialization/types/FieldValidationsAdditionalProperties.d.ts +11 -0
- package/serialization/types/FieldValidationsAdditionalProperties.js +48 -0
- package/serialization/types/FieldValidationsAdditionalPropertiesAdditionalProperties.d.ts +12 -0
- package/serialization/types/FieldValidationsAdditionalPropertiesAdditionalProperties.js +43 -0
- package/serialization/types/ForbiddenErrorBody.js +17 -7
- package/serialization/types/Form.js +17 -7
- package/serialization/types/FormField.js +17 -7
- package/serialization/types/FormFieldValue.js +17 -7
- package/serialization/types/FormFieldValueType.js +17 -7
- package/serialization/types/FormList.js +17 -7
- package/serialization/types/FormResponseSettings.js +17 -7
- package/serialization/types/FormSubmission.js +17 -7
- package/serialization/types/FormSubmissionList.js +17 -7
- package/serialization/types/FormSubmissionTrigger.d.ts +14 -0
- package/serialization/types/FormSubmissionTrigger.js +45 -0
- package/serialization/types/FormSubmissionTriggerPayload.d.ts +20 -0
- package/serialization/types/FormSubmissionTriggerPayload.js +51 -0
- package/serialization/types/FormSubmissionTriggerPayloadSchemaItem.d.ts +15 -0
- package/serialization/types/FormSubmissionTriggerPayloadSchemaItem.js +46 -0
- package/serialization/types/FormSubmissionTriggerPayloadSchemaItemFieldType.d.ts +10 -0
- package/serialization/types/FormSubmissionTriggerPayloadSchemaItemFieldType.js +47 -0
- package/serialization/types/ImageNode.d.ts +2 -2
- package/serialization/types/ImageNode.js +19 -9
- package/serialization/types/ImageNodeImage.js +17 -7
- package/serialization/types/InvalidDomain.js +17 -7
- package/serialization/types/InvalidScopes.js +17 -7
- package/serialization/types/InventoryItem.js +17 -7
- package/serialization/types/InventoryItemInventoryType.js +17 -7
- package/serialization/types/ItemsListItemsLiveRequestLastPublished.d.ts +13 -0
- package/serialization/types/ItemsListItemsLiveRequestLastPublished.js +44 -0
- package/serialization/types/ItemsListItemsRequestLastPublished.d.ts +13 -0
- package/serialization/types/ItemsListItemsRequestLastPublished.js +44 -0
- package/serialization/types/ListCustomCodeBlocks.js +17 -7
- package/serialization/types/Locale.js +17 -7
- package/serialization/types/Locales.js +17 -7
- package/serialization/types/Metadata.js +17 -7
- package/serialization/types/MetadataOptionsItem.js +17 -7
- package/serialization/types/NewOrder.d.ts +14 -0
- package/serialization/types/NewOrder.js +45 -0
- package/serialization/types/NoDomains.js +17 -7
- package/serialization/types/Node.js +17 -7
- package/serialization/types/NotEnterprisePlanSite.js +17 -7
- package/serialization/types/NotEnterprisePlanWorkspace.js +17 -7
- package/serialization/types/OptionField.js +17 -7
- package/serialization/types/Order.d.ts +4 -2
- package/serialization/types/Order.js +21 -9
- package/serialization/types/OrderAddress.js +17 -7
- package/serialization/types/OrderAddressJapanType.js +17 -7
- package/serialization/types/OrderAddressType.js +17 -7
- package/serialization/types/OrderBillingAddress.d.ts +22 -0
- package/serialization/types/OrderBillingAddress.js +53 -0
- package/serialization/types/OrderBillingAddressJapanType.d.ts +10 -0
- package/serialization/types/OrderBillingAddressJapanType.js +41 -0
- package/serialization/types/OrderBillingAddressType.d.ts +10 -0
- package/serialization/types/OrderBillingAddressType.js +41 -0
- package/serialization/types/OrderCustomerInfo.js +17 -7
- package/serialization/types/OrderDisputeLastStatus.js +17 -7
- package/serialization/types/OrderDownloadFilesItem.js +17 -7
- package/serialization/types/OrderList.js +17 -7
- package/serialization/types/OrderMetadata.js +17 -7
- package/serialization/types/OrderPrice.js +17 -7
- package/serialization/types/OrderPurchasedItem.js +17 -7
- package/serialization/types/OrderPurchasedItemVariantImage.js +17 -7
- package/serialization/types/OrderPurchasedItemVariantImageFile.js +17 -7
- package/serialization/types/OrderPurchasedItemVariantImageFileVariantsItem.js +17 -7
- package/serialization/types/OrderShippingAddress.d.ts +22 -0
- package/serialization/types/OrderShippingAddress.js +53 -0
- package/serialization/types/OrderShippingAddressJapanType.d.ts +10 -0
- package/serialization/types/OrderShippingAddressJapanType.js +41 -0
- package/serialization/types/OrderShippingAddressType.d.ts +10 -0
- package/serialization/types/OrderShippingAddressType.js +41 -0
- package/serialization/types/OrderStatus.js +17 -7
- package/serialization/types/OrderTotals.js +17 -7
- package/serialization/types/OrderTotalsExtrasItem.js +17 -7
- package/serialization/types/OrderTotalsExtrasItemType.js +17 -7
- package/serialization/types/Page.d.ts +1 -0
- package/serialization/types/Page.js +18 -7
- package/serialization/types/PageCreatedWebhook.d.ts +14 -0
- package/serialization/types/PageCreatedWebhook.js +45 -0
- package/serialization/types/PageCreatedWebhookPayload.d.ts +16 -0
- package/serialization/types/PageCreatedWebhookPayload.js +47 -0
- package/serialization/types/PageDeletedWebhook.d.ts +14 -0
- package/serialization/types/PageDeletedWebhook.js +45 -0
- package/serialization/types/PageDeletedWebhookPayload.d.ts +16 -0
- package/serialization/types/PageDeletedWebhookPayload.js +47 -0
- package/serialization/types/PageList.js +17 -7
- package/serialization/types/PageMetadataUpdatedWebhook.d.ts +14 -0
- package/serialization/types/PageMetadataUpdatedWebhook.js +45 -0
- package/serialization/types/PageMetadataUpdatedWebhookPayload.d.ts +16 -0
- package/serialization/types/PageMetadataUpdatedWebhookPayload.js +47 -0
- package/serialization/types/PageOpenGraph.js +17 -7
- package/serialization/types/PageSeo.js +17 -7
- package/serialization/types/Pagination.js +17 -7
- package/serialization/types/Payload.d.ts +23 -0
- package/serialization/types/Payload.js +54 -0
- package/serialization/types/PayloadFieldData.d.ts +14 -0
- package/serialization/types/PayloadFieldData.js +46 -0
- package/serialization/types/PaypalDetails.js +17 -7
- package/serialization/types/Product.js +17 -7
- package/serialization/types/ProductAndSkUs.js +17 -7
- package/serialization/types/ProductAndSkUsList.js +17 -7
- package/serialization/types/ProductFieldData.d.ts +1 -1
- package/serialization/types/ProductFieldData.js +18 -8
- package/serialization/types/ProductFieldDataEcProductType.js +17 -7
- package/serialization/types/ProductFieldDataTaxCategory.js +17 -7
- package/serialization/types/PublishStatus.js +17 -7
- package/serialization/types/Redirect.js +17 -7
- package/serialization/types/Redirects.js +17 -7
- package/serialization/types/ReferenceField.js +17 -7
- package/serialization/types/ReferenceFieldMetadata.js +17 -7
- package/serialization/types/ReferenceFieldType.js +17 -7
- package/serialization/types/RegisteredScriptList.d.ts +2 -0
- package/serialization/types/RegisteredScriptList.js +19 -7
- package/serialization/types/Robots.js +17 -7
- package/serialization/types/RobotsRulesItem.js +17 -7
- package/serialization/types/ScriptApply.js +17 -7
- package/serialization/types/ScriptApplyList.js +17 -7
- package/serialization/types/ScriptApplyLocation.js +17 -7
- package/serialization/types/Scripts.js +17 -7
- package/serialization/types/SearchButtonNode.js +17 -7
- package/serialization/types/SearchButtonNodeWrite.js +17 -7
- package/{dist/serialization/types/SelectNodeWrite.d.ts → serialization/types/Select.d.ts} +2 -2
- package/{dist/serialization/types/SelectNodeWrite.js → serialization/types/Select.js} +19 -9
- package/serialization/types/SelectNode.js +17 -7
- package/serialization/types/SelectNodeChoicesItem.js +17 -7
- package/serialization/types/SelectNodeWriteChoicesItem.js +17 -7
- package/serialization/types/SingleLocaleCreatedPayload.d.ts +23 -0
- package/serialization/types/SingleLocaleCreatedPayload.js +54 -0
- package/serialization/types/SingleLocaleCreatedPayloadFieldData.d.ts +14 -0
- package/serialization/types/SingleLocaleCreatedPayloadFieldData.js +46 -0
- package/serialization/types/Site.js +17 -7
- package/serialization/types/SiteActivityLogItem.js +17 -7
- package/serialization/types/SiteActivityLogItemEvent.js +17 -7
- package/serialization/types/SiteActivityLogItemResourceOperation.js +17 -7
- package/serialization/types/SiteActivityLogItemUser.js +17 -7
- package/serialization/types/SiteActivityLogResponse.js +17 -7
- package/serialization/types/SiteDataCollectionType.js +17 -7
- package/serialization/types/SiteMembership.d.ts +2 -0
- package/serialization/types/SiteMembership.js +19 -7
- package/serialization/types/SiteMembershipAuditLogItem.js +17 -7
- package/serialization/types/SiteMembershipAuditLogItemEventSubType.d.ts +1 -1
- package/serialization/types/SiteMembershipAuditLogItemEventSubType.js +18 -8
- package/serialization/types/SitePlan.js +17 -7
- package/serialization/types/SitePlanId.js +17 -7
- package/serialization/types/SitePlanName.js +17 -7
- package/serialization/types/SitePublish.d.ts +14 -0
- package/serialization/types/SitePublish.js +45 -0
- package/serialization/types/SitePublishPayload.d.ts +15 -0
- package/serialization/types/SitePublishPayload.js +46 -0
- package/serialization/types/Sites.js +17 -7
- package/serialization/types/Sku.js +17 -7
- package/serialization/types/SkuFieldData.d.ts +0 -2
- package/serialization/types/SkuFieldData.js +17 -9
- package/serialization/types/SkuFieldDataCompareAtPrice.js +17 -7
- package/serialization/types/SkuFieldDataEcSkuBillingMethod.js +17 -7
- package/serialization/types/SkuFieldDataEcSkuSubscriptionPlan.js +17 -7
- package/serialization/types/SkuFieldDataEcSkuSubscriptionPlanInterval.js +17 -7
- package/serialization/types/SkuFieldDataEcSkuSubscriptionPlanPlansItem.js +17 -7
- package/serialization/types/SkuFieldDataEcSkuSubscriptionPlanPlansItemStatus.js +17 -7
- package/serialization/types/SkuFieldDataPrice.js +17 -7
- package/serialization/types/SkuPropertyList.js +17 -7
- package/serialization/types/SkuPropertyListEnumItem.js +17 -7
- package/serialization/types/SkuValueList.js +17 -7
- package/serialization/types/StaticField.js +17 -7
- package/serialization/types/StaticFieldType.js +17 -7
- package/serialization/types/StripeCard.js +17 -7
- package/serialization/types/StripeCardBrand.js +17 -7
- package/serialization/types/StripeCardExpires.js +17 -7
- package/serialization/types/StripeDetails.js +17 -7
- package/serialization/types/SubmitButtonNode.js +17 -7
- package/serialization/types/SubmitButtonNodeWrite.js +17 -7
- package/serialization/types/Text.js +17 -7
- package/serialization/types/TextInputNode.js +17 -7
- package/serialization/types/TextInputNodeWrite.js +17 -7
- package/serialization/types/TextNode.d.ts +2 -2
- package/serialization/types/TextNode.js +19 -9
- package/serialization/types/TextNodeText.js +17 -7
- package/serialization/types/TextNodeWrite.js +17 -7
- package/serialization/types/TriggerType.d.ts +1 -1
- package/serialization/types/TriggerType.js +18 -7
- package/serialization/types/UpdatedOrder.d.ts +14 -0
- package/serialization/types/UpdatedOrder.js +45 -0
- package/serialization/types/User.js +17 -7
- package/serialization/types/UserAccess.js +17 -7
- package/serialization/types/UserAccessAuditLogItem.js +17 -7
- package/serialization/types/UserAccessAuditLogItemEventSubType.js +17 -7
- package/serialization/types/UserAccessGroupsItem.js +17 -7
- package/serialization/types/UserAccessGroupsItemType.js +17 -7
- package/serialization/types/UserData.js +17 -7
- package/serialization/types/UserDataData.js +17 -7
- package/serialization/types/UserLimitReached.js +17 -7
- package/serialization/types/UserList.js +17 -7
- package/serialization/types/UserStatus.js +17 -7
- package/serialization/types/UsersNotEnabled.js +17 -7
- package/serialization/types/Webhook.js +17 -7
- package/serialization/types/WebhookFilter.js +17 -7
- package/serialization/types/WebhookList.js +17 -7
- package/serialization/types/WorkspaceAuditLogItem.js +17 -7
- package/serialization/types/WorkspaceAuditLogItemActor.js +17 -7
- package/serialization/types/WorkspaceAuditLogItemPayloadSiteMembershipGranularAccess.d.ts +15 -0
- package/serialization/types/WorkspaceAuditLogItemPayloadSiteMembershipGranularAccess.js +46 -0
- package/serialization/types/WorkspaceAuditLogItemPayloadSiteMembershipMethod.d.ts +1 -1
- package/serialization/types/WorkspaceAuditLogItemPayloadSiteMembershipMethod.js +18 -8
- package/serialization/types/WorkspaceAuditLogItemPayloadSiteMembershipSite.js +17 -7
- package/serialization/types/WorkspaceAuditLogItemPayloadSiteMembershipTargetUser.js +17 -7
- package/serialization/types/WorkspaceAuditLogItemPayloadSiteMembershipUserType.js +17 -7
- package/serialization/types/WorkspaceAuditLogItemPayloadUserAccessMethod.js +17 -7
- package/serialization/types/WorkspaceAuditLogItemPayloadWorkspaceInvitationMethod.js +17 -7
- package/serialization/types/WorkspaceAuditLogItemPayloadWorkspaceInvitationTargetUser.js +17 -7
- package/serialization/types/WorkspaceAuditLogItemPayloadWorkspaceInvitationTargetUsersItem.d.ts +13 -0
- package/serialization/types/WorkspaceAuditLogItemPayloadWorkspaceInvitationTargetUsersItem.js +44 -0
- package/serialization/types/WorkspaceAuditLogItemPayloadWorkspaceInvitationUserType.js +17 -7
- package/serialization/types/WorkspaceAuditLogItemPayloadWorkspaceMembershipMethod.d.ts +1 -1
- package/serialization/types/WorkspaceAuditLogItemPayloadWorkspaceMembershipMethod.js +18 -8
- package/serialization/types/WorkspaceAuditLogItemPayloadWorkspaceMembershipTargetUser.js +17 -7
- package/serialization/types/WorkspaceAuditLogItemPayloadWorkspaceMembershipUserType.js +17 -7
- package/serialization/types/WorkspaceAuditLogItemWorkspace.js +17 -7
- package/serialization/types/WorkspaceAuditLogResponse.js +17 -7
- package/serialization/types/WorkspaceInvitation.d.ts +2 -0
- package/serialization/types/WorkspaceInvitation.js +19 -7
- package/serialization/types/WorkspaceInvitationAuditLogItem.js +17 -7
- package/serialization/types/WorkspaceInvitationAuditLogItemEventSubType.d.ts +1 -1
- package/serialization/types/WorkspaceInvitationAuditLogItemEventSubType.js +18 -7
- package/serialization/types/WorkspaceMembership.js +17 -7
- package/serialization/types/WorkspaceMembershipAuditLogItem.js +17 -7
- package/serialization/types/WorkspaceMembershipAuditLogItemEventSubType.js +17 -7
- package/serialization/types/index.d.ts +47 -3
- package/serialization/types/index.js +47 -3
- package/version.d.ts +1 -1
- package/version.js +1 -1
- package/wrapper/AssetsClient.d.ts +24 -0
- package/wrapper/AssetsClient.js +42 -0
- package/wrapper/AssetsUtilitiesClient.d.ts +1 -1
- package/wrapper/CollectionsClient.d.ts +11 -0
- package/wrapper/CollectionsClient.js +18 -0
- package/wrapper/ItemsClient.d.ts +167 -0
- package/wrapper/ItemsClient.js +630 -0
- package/wrapper/PagesClient.d.ts +49 -0
- package/wrapper/PagesClient.js +214 -0
- package/wrapper/WebflowClient.d.ts +6 -0
- package/wrapper/WebflowClient.js +29 -9
- package/wrapper/WebhooksClient.d.ts +0 -1
- package/wrapper/WebhooksClient.js +2 -5
- package/wrapper/schemas/ItemsCreateItemLiveRequest.d.ts +4 -0
- package/wrapper/schemas/ItemsCreateItemLiveRequest.js +2 -0
- package/wrapper/schemas/ItemsCreateItemRequest.d.ts +4 -0
- package/wrapper/schemas/ItemsCreateItemRequest.js +2 -0
- package/wrapper/schemas/ItemsUpdateItemLiveRequest.d.ts +4 -0
- package/wrapper/schemas/ItemsUpdateItemLiveRequest.js +2 -0
- package/wrapper/schemas/ItemsUpdateItemRequest.d.ts +4 -0
- package/wrapper/schemas/ItemsUpdateItemRequest.js +2 -0
- package/{dist/api/resources/pages/client/requests/UpdatePageSettingsRequest.d.ts → wrapper/schemas/PageMetadataWrite.d.ts} +13 -17
- package/wrapper/schemas/PageMetadataWrite.js +2 -0
- package/wrapper/schemas/index.d.ts +5 -0
- package/wrapper/schemas/index.js +21 -0
- package/api/resources/collections/resources/items/client/requests/ItemsPublishItemRequest.d.ts +0 -12
- package/api/resources/users/client/requests/UsersUpdateRequest.d.ts +0 -20
- package/api/resources/users/types/UsersUpdateRequestData.d.ts +0 -11
- package/dist/api/resources/collections/resources/items/client/requests/ItemsPublishItemRequest.d.ts +0 -12
- package/dist/api/resources/users/client/requests/UsersUpdateRequest.d.ts +0 -20
- package/dist/api/resources/users/types/UsersUpdateRequestData.d.ts +0 -11
- package/dist/serialization/resources/collections/resources/items/client/requests/ItemsPublishItemRequest.d.ts +0 -12
- package/dist/serialization/resources/users/client/requests/UsersUpdateRequest.d.ts +0 -14
- package/dist/serialization/resources/users/client/requests/UsersUpdateRequest.js +0 -35
- package/dist/serialization/resources/users/types/UsersUpdateRequestData.d.ts +0 -14
- package/jest.config.js +0 -5
- package/serialization/resources/collections/resources/items/client/requests/ItemsPublishItemRequest.d.ts +0 -12
- package/serialization/resources/users/client/requests/UsersUpdateRequest.d.ts +0 -14
- package/serialization/resources/users/client/requests/UsersUpdateRequest.js +0 -35
- package/serialization/resources/users/types/UsersUpdateRequestData.d.ts +0 -14
- /package/api/resources/{collections/resources/items/client/requests/ItemsPublishItemRequest.js → assets/client/requests/AssetsListRequest.js} +0 -0
- /package/api/resources/collections/resources/items/{types → client/requests}/ItemsCreateItemLiveRequest.js +0 -0
- /package/api/resources/collections/resources/items/{types → client/requests}/ItemsCreateItemRequest.js +0 -0
- /package/api/resources/{pages/client/requests/UpdatePageSettingsRequest.js → collections/resources/items/client/requests/ItemsUpdateItemLiveRequest.js} +0 -0
- /package/api/resources/{users/client/requests/UsersUpdateRequest.js → collections/resources/items/client/requests/ItemsUpdateItemRequest.js} +0 -0
- /package/api/resources/{users/types/UsersUpdateRequestData.js → collections/resources/items/types/ItemIDs.js} +0 -0
- /package/api/{types/SelectNodeWrite.js → resources/collections/resources/items/types/ItemIDsWithLocales.js} +0 -0
- /package/{dist/api/resources/collections/resources/items/client/requests/ItemsPublishItemRequest.js → api/resources/collections/resources/items/types/ItemsCreateItemLiveRequestBody.js} +0 -0
- /package/{dist/api/resources/collections/resources/items/types/ItemsCreateItemLiveRequest.js → api/resources/collections/resources/items/types/ItemsCreateItemRequestBody.js} +0 -0
- /package/{dist/api/resources/collections/resources/items/types/ItemsCreateItemRequest.js → api/resources/collections/resources/items/types/ItemsPublishItemRequest.js} +0 -0
- /package/{dist/api/resources/pages/client/requests/UpdatePageSettingsRequest.js → api/resources/collections/resources/items/types/ItemsPublishItemRequestItemsItemsItem.js} +0 -0
- /package/{dist/api/resources/users/client/requests/UsersUpdateRequest.js → api/resources/collections/resources/items/types/ItemsUpdateItemsResponse.js} +0 -0
- /package/{dist/api/resources/users/types/UsersUpdateRequestData.js → api/resources/inventory/types/EcommInventoryChangedPayload.js} +0 -0
- /package/{dist/api/types/SelectNodeWrite.js → api/resources/pages/client/requests/PageMetadataWrite.js} +0 -0
|
@@ -18,13 +18,23 @@ var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (
|
|
|
18
18
|
}) : function(o, v) {
|
|
19
19
|
o["default"] = v;
|
|
20
20
|
});
|
|
21
|
-
var __importStar = (this && this.__importStar) || function (
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
};
|
|
21
|
+
var __importStar = (this && this.__importStar) || (function () {
|
|
22
|
+
var ownKeys = function(o) {
|
|
23
|
+
ownKeys = Object.getOwnPropertyNames || function (o) {
|
|
24
|
+
var ar = [];
|
|
25
|
+
for (var k in o) if (Object.prototype.hasOwnProperty.call(o, k)) ar[ar.length] = k;
|
|
26
|
+
return ar;
|
|
27
|
+
};
|
|
28
|
+
return ownKeys(o);
|
|
29
|
+
};
|
|
30
|
+
return function (mod) {
|
|
31
|
+
if (mod && mod.__esModule) return mod;
|
|
32
|
+
var result = {};
|
|
33
|
+
if (mod != null) for (var k = ownKeys(mod), i = 0; i < k.length; i++) if (k[i] !== "default") __createBinding(result, mod, k[i]);
|
|
34
|
+
__setModuleDefault(result, mod);
|
|
35
|
+
return result;
|
|
36
|
+
};
|
|
37
|
+
})();
|
|
28
38
|
var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {
|
|
29
39
|
function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }
|
|
30
40
|
return new (P || (P = Promise))(function (resolve, reject) {
|
|
@@ -34,6 +44,17 @@ var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, ge
|
|
|
34
44
|
step((generator = generator.apply(thisArg, _arguments || [])).next());
|
|
35
45
|
});
|
|
36
46
|
};
|
|
47
|
+
var __rest = (this && this.__rest) || function (s, e) {
|
|
48
|
+
var t = {};
|
|
49
|
+
for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p) && e.indexOf(p) < 0)
|
|
50
|
+
t[p] = s[p];
|
|
51
|
+
if (s != null && typeof Object.getOwnPropertySymbols === "function")
|
|
52
|
+
for (var i = 0, p = Object.getOwnPropertySymbols(s); i < p.length; i++) {
|
|
53
|
+
if (e.indexOf(p[i]) < 0 && Object.prototype.propertyIsEnumerable.call(s, p[i]))
|
|
54
|
+
t[p[i]] = s[p[i]];
|
|
55
|
+
}
|
|
56
|
+
return t;
|
|
57
|
+
};
|
|
37
58
|
var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
38
59
|
return (mod && mod.__esModule) ? mod : { "default": mod };
|
|
39
60
|
};
|
|
@@ -42,11 +63,12 @@ exports.Items = void 0;
|
|
|
42
63
|
const environments = __importStar(require("../../../../../../environments"));
|
|
43
64
|
const core = __importStar(require("../../../../../../core"));
|
|
44
65
|
const Webflow = __importStar(require("../../../../../index"));
|
|
45
|
-
const url_join_1 = __importDefault(require("url-join"));
|
|
46
66
|
const serializers = __importStar(require("../../../../../../serialization/index"));
|
|
67
|
+
const headers_js_1 = require("../../../../../../core/headers.js");
|
|
68
|
+
const url_join_1 = __importDefault(require("url-join"));
|
|
47
69
|
const errors = __importStar(require("../../../../../../errors/index"));
|
|
48
70
|
class Items {
|
|
49
|
-
constructor(_options) {
|
|
71
|
+
constructor(_options = {}) {
|
|
50
72
|
this._options = _options;
|
|
51
73
|
}
|
|
52
74
|
/**
|
|
@@ -65,12 +87,23 @@ class Items {
|
|
|
65
87
|
* @throws {@link Webflow.InternalServerError}
|
|
66
88
|
*
|
|
67
89
|
* @example
|
|
68
|
-
* await client.collections.items.listItems("580e63fc8c9a982ac9b8b745"
|
|
90
|
+
* await client.collections.items.listItems("580e63fc8c9a982ac9b8b745", {
|
|
91
|
+
* cmsLocaleId: "cmsLocaleId",
|
|
92
|
+
* offset: 1.1,
|
|
93
|
+
* limit: 1.1,
|
|
94
|
+
* name: "name",
|
|
95
|
+
* slug: "slug",
|
|
96
|
+
* sortBy: "lastPublished",
|
|
97
|
+
* sortOrder: "asc"
|
|
98
|
+
* })
|
|
69
99
|
*/
|
|
70
100
|
listItems(collectionId, request = {}, requestOptions) {
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
|
|
101
|
+
return core.HttpResponsePromise.fromPromise(this.__listItems(collectionId, request, requestOptions));
|
|
102
|
+
}
|
|
103
|
+
__listItems(collectionId_1) {
|
|
104
|
+
return __awaiter(this, arguments, void 0, function* (collectionId, request = {}, requestOptions) {
|
|
105
|
+
var _a, _b, _c;
|
|
106
|
+
const { cmsLocaleId, offset, limit, name, slug, lastPublished, sortBy, sortOrder } = request;
|
|
74
107
|
const _queryParams = {};
|
|
75
108
|
if (cmsLocaleId != null) {
|
|
76
109
|
_queryParams["cmsLocaleId"] = cmsLocaleId;
|
|
@@ -87,36 +120,54 @@ class Items {
|
|
|
87
120
|
if (slug != null) {
|
|
88
121
|
_queryParams["slug"] = slug;
|
|
89
122
|
}
|
|
123
|
+
if (lastPublished != null) {
|
|
124
|
+
_queryParams["lastPublished"] = serializers.ItemsListItemsRequestLastPublished.jsonOrThrow(lastPublished, {
|
|
125
|
+
unrecognizedObjectKeys: "passthrough",
|
|
126
|
+
allowUnrecognizedUnionMembers: true,
|
|
127
|
+
allowUnrecognizedEnumValues: true,
|
|
128
|
+
breadcrumbsPrefix: ["request", "lastPublished"],
|
|
129
|
+
});
|
|
130
|
+
}
|
|
90
131
|
if (sortBy != null) {
|
|
91
|
-
_queryParams["sortBy"] = sortBy
|
|
132
|
+
_queryParams["sortBy"] = serializers.collections.ItemsListItemsRequestSortBy.jsonOrThrow(sortBy, {
|
|
133
|
+
unrecognizedObjectKeys: "passthrough",
|
|
134
|
+
allowUnrecognizedUnionMembers: true,
|
|
135
|
+
allowUnrecognizedEnumValues: true,
|
|
136
|
+
});
|
|
92
137
|
}
|
|
93
138
|
if (sortOrder != null) {
|
|
94
|
-
_queryParams["sortOrder"] = sortOrder
|
|
139
|
+
_queryParams["sortOrder"] = serializers.collections.ItemsListItemsRequestSortOrder.jsonOrThrow(sortOrder, {
|
|
140
|
+
unrecognizedObjectKeys: "passthrough",
|
|
141
|
+
allowUnrecognizedUnionMembers: true,
|
|
142
|
+
allowUnrecognizedEnumValues: true,
|
|
143
|
+
});
|
|
95
144
|
}
|
|
96
145
|
const _response = yield core.fetcher({
|
|
97
|
-
url: (0, url_join_1.default)((
|
|
146
|
+
url: (0, url_join_1.default)((_a = (yield core.Supplier.get(this._options.baseUrl))) !== null && _a !== void 0 ? _a : ((_b = (yield core.Supplier.get(this._options.environment))) !== null && _b !== void 0 ? _b : environments.WebflowEnvironment.DataApi)
|
|
147
|
+
.base, `collections/${encodeURIComponent(collectionId)}/items`),
|
|
98
148
|
method: "GET",
|
|
99
|
-
headers:
|
|
100
|
-
contentType: "application/json",
|
|
149
|
+
headers: (0, headers_js_1.mergeHeaders)((_c = this._options) === null || _c === void 0 ? void 0 : _c.headers, (0, headers_js_1.mergeOnlyDefinedHeaders)({ Authorization: yield this._getAuthorizationHeader() }), requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers),
|
|
101
150
|
queryParameters: _queryParams,
|
|
102
|
-
requestType: "json",
|
|
103
151
|
timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
|
|
104
152
|
maxRetries: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries,
|
|
105
153
|
abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
|
|
106
154
|
});
|
|
107
155
|
if (_response.ok) {
|
|
108
|
-
return
|
|
109
|
-
|
|
110
|
-
|
|
111
|
-
|
|
112
|
-
|
|
113
|
-
|
|
114
|
-
|
|
156
|
+
return {
|
|
157
|
+
data: serializers.CollectionItemList.parseOrThrow(_response.body, {
|
|
158
|
+
unrecognizedObjectKeys: "passthrough",
|
|
159
|
+
allowUnrecognizedUnionMembers: true,
|
|
160
|
+
allowUnrecognizedEnumValues: true,
|
|
161
|
+
skipValidation: true,
|
|
162
|
+
breadcrumbsPrefix: ["response"],
|
|
163
|
+
}),
|
|
164
|
+
rawResponse: _response.rawResponse,
|
|
165
|
+
};
|
|
115
166
|
}
|
|
116
167
|
if (_response.error.reason === "status-code") {
|
|
117
168
|
switch (_response.error.statusCode) {
|
|
118
169
|
case 400:
|
|
119
|
-
throw new Webflow.BadRequestError(_response.error.body);
|
|
170
|
+
throw new Webflow.BadRequestError(_response.error.body, _response.rawResponse);
|
|
120
171
|
case 401:
|
|
121
172
|
throw new Webflow.UnauthorizedError(serializers.Error_.parseOrThrow(_response.error.body, {
|
|
122
173
|
unrecognizedObjectKeys: "passthrough",
|
|
@@ -124,7 +175,7 @@ class Items {
|
|
|
124
175
|
allowUnrecognizedEnumValues: true,
|
|
125
176
|
skipValidation: true,
|
|
126
177
|
breadcrumbsPrefix: ["response"],
|
|
127
|
-
}));
|
|
178
|
+
}), _response.rawResponse);
|
|
128
179
|
case 404:
|
|
129
180
|
throw new Webflow.NotFoundError(serializers.Error_.parseOrThrow(_response.error.body, {
|
|
130
181
|
unrecognizedObjectKeys: "passthrough",
|
|
@@ -132,7 +183,7 @@ class Items {
|
|
|
132
183
|
allowUnrecognizedEnumValues: true,
|
|
133
184
|
skipValidation: true,
|
|
134
185
|
breadcrumbsPrefix: ["response"],
|
|
135
|
-
}));
|
|
186
|
+
}), _response.rawResponse);
|
|
136
187
|
case 429:
|
|
137
188
|
throw new Webflow.TooManyRequestsError(serializers.Error_.parseOrThrow(_response.error.body, {
|
|
138
189
|
unrecognizedObjectKeys: "passthrough",
|
|
@@ -140,7 +191,7 @@ class Items {
|
|
|
140
191
|
allowUnrecognizedEnumValues: true,
|
|
141
192
|
skipValidation: true,
|
|
142
193
|
breadcrumbsPrefix: ["response"],
|
|
143
|
-
}));
|
|
194
|
+
}), _response.rawResponse);
|
|
144
195
|
case 500:
|
|
145
196
|
throw new Webflow.InternalServerError(serializers.Error_.parseOrThrow(_response.error.body, {
|
|
146
197
|
unrecognizedObjectKeys: "passthrough",
|
|
@@ -148,11 +199,12 @@ class Items {
|
|
|
148
199
|
allowUnrecognizedEnumValues: true,
|
|
149
200
|
skipValidation: true,
|
|
150
201
|
breadcrumbsPrefix: ["response"],
|
|
151
|
-
}));
|
|
202
|
+
}), _response.rawResponse);
|
|
152
203
|
default:
|
|
153
204
|
throw new errors.WebflowError({
|
|
154
205
|
statusCode: _response.error.statusCode,
|
|
155
206
|
body: _response.error.body,
|
|
207
|
+
rawResponse: _response.rawResponse,
|
|
156
208
|
});
|
|
157
209
|
}
|
|
158
210
|
}
|
|
@@ -161,12 +213,14 @@ class Items {
|
|
|
161
213
|
throw new errors.WebflowError({
|
|
162
214
|
statusCode: _response.error.statusCode,
|
|
163
215
|
body: _response.error.rawBody,
|
|
216
|
+
rawResponse: _response.rawResponse,
|
|
164
217
|
});
|
|
165
218
|
case "timeout":
|
|
166
219
|
throw new errors.WebflowTimeoutError("Timeout exceeded when calling GET /collections/{collection_id}/items.");
|
|
167
220
|
case "unknown":
|
|
168
221
|
throw new errors.WebflowError({
|
|
169
222
|
message: _response.error.errorMessage,
|
|
223
|
+
rawResponse: _response.rawResponse,
|
|
170
224
|
});
|
|
171
225
|
}
|
|
172
226
|
});
|
|
@@ -175,7 +229,7 @@ class Items {
|
|
|
175
229
|
* Create Item(s) in a Collection.
|
|
176
230
|
*
|
|
177
231
|
*
|
|
178
|
-
* To create items across multiple locales, please use [this endpoint.](/
|
|
232
|
+
* To create items across multiple locales, please use [this endpoint.](/data/reference/cms/collection-items/staged-items/create-items)
|
|
179
233
|
*
|
|
180
234
|
* Required scope | `CMS:write`
|
|
181
235
|
*
|
|
@@ -191,43 +245,59 @@ class Items {
|
|
|
191
245
|
*
|
|
192
246
|
* @example
|
|
193
247
|
* await client.collections.items.createItem("580e63fc8c9a982ac9b8b745", {
|
|
194
|
-
*
|
|
195
|
-
*
|
|
196
|
-
*
|
|
197
|
-
*
|
|
198
|
-
*
|
|
248
|
+
* skipInvalidFiles: true,
|
|
249
|
+
* body: {
|
|
250
|
+
* isArchived: false,
|
|
251
|
+
* isDraft: false,
|
|
252
|
+
* fieldData: {
|
|
253
|
+
* name: "The Hitchhiker's Guide to the Galaxy",
|
|
254
|
+
* slug: "hitchhikers-guide-to-the-galaxy"
|
|
255
|
+
* }
|
|
199
256
|
* }
|
|
200
257
|
* })
|
|
201
258
|
*
|
|
202
259
|
* @example
|
|
203
260
|
* await client.collections.items.createItem("580e63fc8c9a982ac9b8b745", {
|
|
204
|
-
*
|
|
205
|
-
*
|
|
206
|
-
*
|
|
207
|
-
*
|
|
208
|
-
*
|
|
209
|
-
*
|
|
210
|
-
*
|
|
211
|
-
*
|
|
212
|
-
*
|
|
213
|
-
*
|
|
214
|
-
*
|
|
215
|
-
*
|
|
216
|
-
*
|
|
217
|
-
*
|
|
218
|
-
*
|
|
261
|
+
* skipInvalidFiles: true,
|
|
262
|
+
* body: {
|
|
263
|
+
* items: [{
|
|
264
|
+
* isArchived: false,
|
|
265
|
+
* isDraft: false,
|
|
266
|
+
* fieldData: {
|
|
267
|
+
* name: "Senior Data Analyst",
|
|
268
|
+
* slug: "senior-data-analyst"
|
|
269
|
+
* }
|
|
270
|
+
* }, {
|
|
271
|
+
* isArchived: false,
|
|
272
|
+
* isDraft: false,
|
|
273
|
+
* fieldData: {
|
|
274
|
+
* name: "Product Manager",
|
|
275
|
+
* slug: "product-manager"
|
|
276
|
+
* }
|
|
277
|
+
* }]
|
|
278
|
+
* }
|
|
219
279
|
* })
|
|
220
280
|
*/
|
|
221
281
|
createItem(collectionId, request, requestOptions) {
|
|
222
|
-
|
|
282
|
+
return core.HttpResponsePromise.fromPromise(this.__createItem(collectionId, request, requestOptions));
|
|
283
|
+
}
|
|
284
|
+
__createItem(collectionId, request, requestOptions) {
|
|
223
285
|
return __awaiter(this, void 0, void 0, function* () {
|
|
286
|
+
var _a, _b, _c;
|
|
287
|
+
const { skipInvalidFiles, body: _body } = request;
|
|
288
|
+
const _queryParams = {};
|
|
289
|
+
if (skipInvalidFiles != null) {
|
|
290
|
+
_queryParams["skipInvalidFiles"] = skipInvalidFiles.toString();
|
|
291
|
+
}
|
|
224
292
|
const _response = yield core.fetcher({
|
|
225
|
-
url: (0, url_join_1.default)((
|
|
293
|
+
url: (0, url_join_1.default)((_a = (yield core.Supplier.get(this._options.baseUrl))) !== null && _a !== void 0 ? _a : ((_b = (yield core.Supplier.get(this._options.environment))) !== null && _b !== void 0 ? _b : environments.WebflowEnvironment.DataApi)
|
|
294
|
+
.base, `collections/${encodeURIComponent(collectionId)}/items`),
|
|
226
295
|
method: "POST",
|
|
227
|
-
headers:
|
|
296
|
+
headers: (0, headers_js_1.mergeHeaders)((_c = this._options) === null || _c === void 0 ? void 0 : _c.headers, (0, headers_js_1.mergeOnlyDefinedHeaders)({ Authorization: yield this._getAuthorizationHeader() }), requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers),
|
|
228
297
|
contentType: "application/json",
|
|
298
|
+
queryParameters: _queryParams,
|
|
229
299
|
requestType: "json",
|
|
230
|
-
body: serializers.collections.
|
|
300
|
+
body: serializers.collections.ItemsCreateItemRequestBody.jsonOrThrow(_body, {
|
|
231
301
|
unrecognizedObjectKeys: "passthrough",
|
|
232
302
|
allowUnrecognizedUnionMembers: true,
|
|
233
303
|
allowUnrecognizedEnumValues: true,
|
|
@@ -237,18 +307,21 @@ class Items {
|
|
|
237
307
|
abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
|
|
238
308
|
});
|
|
239
309
|
if (_response.ok) {
|
|
240
|
-
return
|
|
241
|
-
|
|
242
|
-
|
|
243
|
-
|
|
244
|
-
|
|
245
|
-
|
|
246
|
-
|
|
310
|
+
return {
|
|
311
|
+
data: serializers.CollectionItem.parseOrThrow(_response.body, {
|
|
312
|
+
unrecognizedObjectKeys: "passthrough",
|
|
313
|
+
allowUnrecognizedUnionMembers: true,
|
|
314
|
+
allowUnrecognizedEnumValues: true,
|
|
315
|
+
skipValidation: true,
|
|
316
|
+
breadcrumbsPrefix: ["response"],
|
|
317
|
+
}),
|
|
318
|
+
rawResponse: _response.rawResponse,
|
|
319
|
+
};
|
|
247
320
|
}
|
|
248
321
|
if (_response.error.reason === "status-code") {
|
|
249
322
|
switch (_response.error.statusCode) {
|
|
250
323
|
case 400:
|
|
251
|
-
throw new Webflow.BadRequestError(_response.error.body);
|
|
324
|
+
throw new Webflow.BadRequestError(_response.error.body, _response.rawResponse);
|
|
252
325
|
case 401:
|
|
253
326
|
throw new Webflow.UnauthorizedError(serializers.Error_.parseOrThrow(_response.error.body, {
|
|
254
327
|
unrecognizedObjectKeys: "passthrough",
|
|
@@ -256,7 +329,7 @@ class Items {
|
|
|
256
329
|
allowUnrecognizedEnumValues: true,
|
|
257
330
|
skipValidation: true,
|
|
258
331
|
breadcrumbsPrefix: ["response"],
|
|
259
|
-
}));
|
|
332
|
+
}), _response.rawResponse);
|
|
260
333
|
case 404:
|
|
261
334
|
throw new Webflow.NotFoundError(serializers.Error_.parseOrThrow(_response.error.body, {
|
|
262
335
|
unrecognizedObjectKeys: "passthrough",
|
|
@@ -264,7 +337,7 @@ class Items {
|
|
|
264
337
|
allowUnrecognizedEnumValues: true,
|
|
265
338
|
skipValidation: true,
|
|
266
339
|
breadcrumbsPrefix: ["response"],
|
|
267
|
-
}));
|
|
340
|
+
}), _response.rawResponse);
|
|
268
341
|
case 429:
|
|
269
342
|
throw new Webflow.TooManyRequestsError(serializers.Error_.parseOrThrow(_response.error.body, {
|
|
270
343
|
unrecognizedObjectKeys: "passthrough",
|
|
@@ -272,7 +345,7 @@ class Items {
|
|
|
272
345
|
allowUnrecognizedEnumValues: true,
|
|
273
346
|
skipValidation: true,
|
|
274
347
|
breadcrumbsPrefix: ["response"],
|
|
275
|
-
}));
|
|
348
|
+
}), _response.rawResponse);
|
|
276
349
|
case 500:
|
|
277
350
|
throw new Webflow.InternalServerError(serializers.Error_.parseOrThrow(_response.error.body, {
|
|
278
351
|
unrecognizedObjectKeys: "passthrough",
|
|
@@ -280,11 +353,12 @@ class Items {
|
|
|
280
353
|
allowUnrecognizedEnumValues: true,
|
|
281
354
|
skipValidation: true,
|
|
282
355
|
breadcrumbsPrefix: ["response"],
|
|
283
|
-
}));
|
|
356
|
+
}), _response.rawResponse);
|
|
284
357
|
default:
|
|
285
358
|
throw new errors.WebflowError({
|
|
286
359
|
statusCode: _response.error.statusCode,
|
|
287
360
|
body: _response.error.body,
|
|
361
|
+
rawResponse: _response.rawResponse,
|
|
288
362
|
});
|
|
289
363
|
}
|
|
290
364
|
}
|
|
@@ -293,12 +367,14 @@ class Items {
|
|
|
293
367
|
throw new errors.WebflowError({
|
|
294
368
|
statusCode: _response.error.statusCode,
|
|
295
369
|
body: _response.error.rawBody,
|
|
370
|
+
rawResponse: _response.rawResponse,
|
|
296
371
|
});
|
|
297
372
|
case "timeout":
|
|
298
373
|
throw new errors.WebflowTimeoutError("Timeout exceeded when calling POST /collections/{collection_id}/items.");
|
|
299
374
|
case "unknown":
|
|
300
375
|
throw new errors.WebflowError({
|
|
301
376
|
message: _response.error.errorMessage,
|
|
377
|
+
rawResponse: _response.rawResponse,
|
|
302
378
|
});
|
|
303
379
|
}
|
|
304
380
|
});
|
|
@@ -329,12 +405,16 @@ class Items {
|
|
|
329
405
|
* })
|
|
330
406
|
*/
|
|
331
407
|
deleteItems(collectionId, request, requestOptions) {
|
|
332
|
-
|
|
408
|
+
return core.HttpResponsePromise.fromPromise(this.__deleteItems(collectionId, request, requestOptions));
|
|
409
|
+
}
|
|
410
|
+
__deleteItems(collectionId, request, requestOptions) {
|
|
333
411
|
return __awaiter(this, void 0, void 0, function* () {
|
|
412
|
+
var _a, _b, _c;
|
|
334
413
|
const _response = yield core.fetcher({
|
|
335
|
-
url: (0, url_join_1.default)((
|
|
414
|
+
url: (0, url_join_1.default)((_a = (yield core.Supplier.get(this._options.baseUrl))) !== null && _a !== void 0 ? _a : ((_b = (yield core.Supplier.get(this._options.environment))) !== null && _b !== void 0 ? _b : environments.WebflowEnvironment.DataApi)
|
|
415
|
+
.base, `collections/${encodeURIComponent(collectionId)}/items`),
|
|
336
416
|
method: "DELETE",
|
|
337
|
-
headers:
|
|
417
|
+
headers: (0, headers_js_1.mergeHeaders)((_c = this._options) === null || _c === void 0 ? void 0 : _c.headers, (0, headers_js_1.mergeOnlyDefinedHeaders)({ Authorization: yield this._getAuthorizationHeader() }), requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers),
|
|
338
418
|
contentType: "application/json",
|
|
339
419
|
requestType: "json",
|
|
340
420
|
body: serializers.collections.ItemsDeleteItemsRequest.jsonOrThrow(request, {
|
|
@@ -347,12 +427,12 @@ class Items {
|
|
|
347
427
|
abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
|
|
348
428
|
});
|
|
349
429
|
if (_response.ok) {
|
|
350
|
-
return;
|
|
430
|
+
return { data: undefined, rawResponse: _response.rawResponse };
|
|
351
431
|
}
|
|
352
432
|
if (_response.error.reason === "status-code") {
|
|
353
433
|
switch (_response.error.statusCode) {
|
|
354
434
|
case 400:
|
|
355
|
-
throw new Webflow.BadRequestError(_response.error.body);
|
|
435
|
+
throw new Webflow.BadRequestError(_response.error.body, _response.rawResponse);
|
|
356
436
|
case 401:
|
|
357
437
|
throw new Webflow.UnauthorizedError(serializers.Error_.parseOrThrow(_response.error.body, {
|
|
358
438
|
unrecognizedObjectKeys: "passthrough",
|
|
@@ -360,7 +440,7 @@ class Items {
|
|
|
360
440
|
allowUnrecognizedEnumValues: true,
|
|
361
441
|
skipValidation: true,
|
|
362
442
|
breadcrumbsPrefix: ["response"],
|
|
363
|
-
}));
|
|
443
|
+
}), _response.rawResponse);
|
|
364
444
|
case 404:
|
|
365
445
|
throw new Webflow.NotFoundError(serializers.Error_.parseOrThrow(_response.error.body, {
|
|
366
446
|
unrecognizedObjectKeys: "passthrough",
|
|
@@ -368,9 +448,9 @@ class Items {
|
|
|
368
448
|
allowUnrecognizedEnumValues: true,
|
|
369
449
|
skipValidation: true,
|
|
370
450
|
breadcrumbsPrefix: ["response"],
|
|
371
|
-
}));
|
|
451
|
+
}), _response.rawResponse);
|
|
372
452
|
case 409:
|
|
373
|
-
throw new Webflow.ConflictError(_response.error.body);
|
|
453
|
+
throw new Webflow.ConflictError(_response.error.body, _response.rawResponse);
|
|
374
454
|
case 429:
|
|
375
455
|
throw new Webflow.TooManyRequestsError(serializers.Error_.parseOrThrow(_response.error.body, {
|
|
376
456
|
unrecognizedObjectKeys: "passthrough",
|
|
@@ -378,7 +458,7 @@ class Items {
|
|
|
378
458
|
allowUnrecognizedEnumValues: true,
|
|
379
459
|
skipValidation: true,
|
|
380
460
|
breadcrumbsPrefix: ["response"],
|
|
381
|
-
}));
|
|
461
|
+
}), _response.rawResponse);
|
|
382
462
|
case 500:
|
|
383
463
|
throw new Webflow.InternalServerError(serializers.Error_.parseOrThrow(_response.error.body, {
|
|
384
464
|
unrecognizedObjectKeys: "passthrough",
|
|
@@ -386,11 +466,12 @@ class Items {
|
|
|
386
466
|
allowUnrecognizedEnumValues: true,
|
|
387
467
|
skipValidation: true,
|
|
388
468
|
breadcrumbsPrefix: ["response"],
|
|
389
|
-
}));
|
|
469
|
+
}), _response.rawResponse);
|
|
390
470
|
default:
|
|
391
471
|
throw new errors.WebflowError({
|
|
392
472
|
statusCode: _response.error.statusCode,
|
|
393
473
|
body: _response.error.body,
|
|
474
|
+
rawResponse: _response.rawResponse,
|
|
394
475
|
});
|
|
395
476
|
}
|
|
396
477
|
}
|
|
@@ -399,12 +480,14 @@ class Items {
|
|
|
399
480
|
throw new errors.WebflowError({
|
|
400
481
|
statusCode: _response.error.statusCode,
|
|
401
482
|
body: _response.error.rawBody,
|
|
483
|
+
rawResponse: _response.rawResponse,
|
|
402
484
|
});
|
|
403
485
|
case "timeout":
|
|
404
486
|
throw new errors.WebflowTimeoutError("Timeout exceeded when calling DELETE /collections/{collection_id}/items.");
|
|
405
487
|
case "unknown":
|
|
406
488
|
throw new errors.WebflowError({
|
|
407
489
|
message: _response.error.errorMessage,
|
|
490
|
+
rawResponse: _response.rawResponse,
|
|
408
491
|
});
|
|
409
492
|
}
|
|
410
493
|
});
|
|
@@ -430,6 +513,7 @@ class Items {
|
|
|
430
513
|
*
|
|
431
514
|
* @example
|
|
432
515
|
* await client.collections.items.updateItems("580e63fc8c9a982ac9b8b745", {
|
|
516
|
+
* skipInvalidFiles: true,
|
|
433
517
|
* items: [{
|
|
434
518
|
* id: "66f6ed9576ddacf3149d5ea6",
|
|
435
519
|
* cmsLocaleId: "66f6e966c9e1dc700a857ca5",
|
|
@@ -463,6 +547,7 @@ class Items {
|
|
|
463
547
|
*
|
|
464
548
|
* @example
|
|
465
549
|
* await client.collections.items.updateItems("580e63fc8c9a982ac9b8b745", {
|
|
550
|
+
* skipInvalidFiles: true,
|
|
466
551
|
* items: [{
|
|
467
552
|
* id: "580e64008c9a982ac9b8b754",
|
|
468
553
|
* isArchived: false,
|
|
@@ -483,15 +568,25 @@ class Items {
|
|
|
483
568
|
* })
|
|
484
569
|
*/
|
|
485
570
|
updateItems(collectionId, request = {}, requestOptions) {
|
|
486
|
-
|
|
487
|
-
|
|
571
|
+
return core.HttpResponsePromise.fromPromise(this.__updateItems(collectionId, request, requestOptions));
|
|
572
|
+
}
|
|
573
|
+
__updateItems(collectionId_1) {
|
|
574
|
+
return __awaiter(this, arguments, void 0, function* (collectionId, request = {}, requestOptions) {
|
|
575
|
+
var _a, _b, _c;
|
|
576
|
+
const { skipInvalidFiles } = request, _body = __rest(request, ["skipInvalidFiles"]);
|
|
577
|
+
const _queryParams = {};
|
|
578
|
+
if (skipInvalidFiles != null) {
|
|
579
|
+
_queryParams["skipInvalidFiles"] = skipInvalidFiles.toString();
|
|
580
|
+
}
|
|
488
581
|
const _response = yield core.fetcher({
|
|
489
|
-
url: (0, url_join_1.default)((
|
|
582
|
+
url: (0, url_join_1.default)((_a = (yield core.Supplier.get(this._options.baseUrl))) !== null && _a !== void 0 ? _a : ((_b = (yield core.Supplier.get(this._options.environment))) !== null && _b !== void 0 ? _b : environments.WebflowEnvironment.DataApi)
|
|
583
|
+
.base, `collections/${encodeURIComponent(collectionId)}/items`),
|
|
490
584
|
method: "PATCH",
|
|
491
|
-
headers:
|
|
585
|
+
headers: (0, headers_js_1.mergeHeaders)((_c = this._options) === null || _c === void 0 ? void 0 : _c.headers, (0, headers_js_1.mergeOnlyDefinedHeaders)({ Authorization: yield this._getAuthorizationHeader() }), requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers),
|
|
492
586
|
contentType: "application/json",
|
|
587
|
+
queryParameters: _queryParams,
|
|
493
588
|
requestType: "json",
|
|
494
|
-
body: serializers.collections.ItemsUpdateItemsRequest.jsonOrThrow(
|
|
589
|
+
body: serializers.collections.ItemsUpdateItemsRequest.jsonOrThrow(_body, {
|
|
495
590
|
unrecognizedObjectKeys: "passthrough",
|
|
496
591
|
allowUnrecognizedUnionMembers: true,
|
|
497
592
|
allowUnrecognizedEnumValues: true,
|
|
@@ -501,18 +596,21 @@ class Items {
|
|
|
501
596
|
abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
|
|
502
597
|
});
|
|
503
598
|
if (_response.ok) {
|
|
504
|
-
return
|
|
505
|
-
|
|
506
|
-
|
|
507
|
-
|
|
508
|
-
|
|
509
|
-
|
|
510
|
-
|
|
599
|
+
return {
|
|
600
|
+
data: serializers.collections.ItemsUpdateItemsResponse.parseOrThrow(_response.body, {
|
|
601
|
+
unrecognizedObjectKeys: "passthrough",
|
|
602
|
+
allowUnrecognizedUnionMembers: true,
|
|
603
|
+
allowUnrecognizedEnumValues: true,
|
|
604
|
+
skipValidation: true,
|
|
605
|
+
breadcrumbsPrefix: ["response"],
|
|
606
|
+
}),
|
|
607
|
+
rawResponse: _response.rawResponse,
|
|
608
|
+
};
|
|
511
609
|
}
|
|
512
610
|
if (_response.error.reason === "status-code") {
|
|
513
611
|
switch (_response.error.statusCode) {
|
|
514
612
|
case 400:
|
|
515
|
-
throw new Webflow.BadRequestError(_response.error.body);
|
|
613
|
+
throw new Webflow.BadRequestError(_response.error.body, _response.rawResponse);
|
|
516
614
|
case 401:
|
|
517
615
|
throw new Webflow.UnauthorizedError(serializers.Error_.parseOrThrow(_response.error.body, {
|
|
518
616
|
unrecognizedObjectKeys: "passthrough",
|
|
@@ -520,7 +618,7 @@ class Items {
|
|
|
520
618
|
allowUnrecognizedEnumValues: true,
|
|
521
619
|
skipValidation: true,
|
|
522
620
|
breadcrumbsPrefix: ["response"],
|
|
523
|
-
}));
|
|
621
|
+
}), _response.rawResponse);
|
|
524
622
|
case 404:
|
|
525
623
|
throw new Webflow.NotFoundError(serializers.Error_.parseOrThrow(_response.error.body, {
|
|
526
624
|
unrecognizedObjectKeys: "passthrough",
|
|
@@ -528,7 +626,7 @@ class Items {
|
|
|
528
626
|
allowUnrecognizedEnumValues: true,
|
|
529
627
|
skipValidation: true,
|
|
530
628
|
breadcrumbsPrefix: ["response"],
|
|
531
|
-
}));
|
|
629
|
+
}), _response.rawResponse);
|
|
532
630
|
case 429:
|
|
533
631
|
throw new Webflow.TooManyRequestsError(serializers.Error_.parseOrThrow(_response.error.body, {
|
|
534
632
|
unrecognizedObjectKeys: "passthrough",
|
|
@@ -536,7 +634,7 @@ class Items {
|
|
|
536
634
|
allowUnrecognizedEnumValues: true,
|
|
537
635
|
skipValidation: true,
|
|
538
636
|
breadcrumbsPrefix: ["response"],
|
|
539
|
-
}));
|
|
637
|
+
}), _response.rawResponse);
|
|
540
638
|
case 500:
|
|
541
639
|
throw new Webflow.InternalServerError(serializers.Error_.parseOrThrow(_response.error.body, {
|
|
542
640
|
unrecognizedObjectKeys: "passthrough",
|
|
@@ -544,11 +642,12 @@ class Items {
|
|
|
544
642
|
allowUnrecognizedEnumValues: true,
|
|
545
643
|
skipValidation: true,
|
|
546
644
|
breadcrumbsPrefix: ["response"],
|
|
547
|
-
}));
|
|
645
|
+
}), _response.rawResponse);
|
|
548
646
|
default:
|
|
549
647
|
throw new errors.WebflowError({
|
|
550
648
|
statusCode: _response.error.statusCode,
|
|
551
649
|
body: _response.error.body,
|
|
650
|
+
rawResponse: _response.rawResponse,
|
|
552
651
|
});
|
|
553
652
|
}
|
|
554
653
|
}
|
|
@@ -557,12 +656,14 @@ class Items {
|
|
|
557
656
|
throw new errors.WebflowError({
|
|
558
657
|
statusCode: _response.error.statusCode,
|
|
559
658
|
body: _response.error.rawBody,
|
|
659
|
+
rawResponse: _response.rawResponse,
|
|
560
660
|
});
|
|
561
661
|
case "timeout":
|
|
562
662
|
throw new errors.WebflowTimeoutError("Timeout exceeded when calling PATCH /collections/{collection_id}/items.");
|
|
563
663
|
case "unknown":
|
|
564
664
|
throw new errors.WebflowError({
|
|
565
665
|
message: _response.error.errorMessage,
|
|
666
|
+
rawResponse: _response.rawResponse,
|
|
566
667
|
});
|
|
567
668
|
}
|
|
568
669
|
});
|
|
@@ -588,12 +689,23 @@ class Items {
|
|
|
588
689
|
* @throws {@link Webflow.InternalServerError}
|
|
589
690
|
*
|
|
590
691
|
* @example
|
|
591
|
-
* await client.collections.items.listItemsLive("580e63fc8c9a982ac9b8b745"
|
|
692
|
+
* await client.collections.items.listItemsLive("580e63fc8c9a982ac9b8b745", {
|
|
693
|
+
* cmsLocaleId: "cmsLocaleId",
|
|
694
|
+
* offset: 1.1,
|
|
695
|
+
* limit: 1.1,
|
|
696
|
+
* name: "name",
|
|
697
|
+
* slug: "slug",
|
|
698
|
+
* sortBy: "lastPublished",
|
|
699
|
+
* sortOrder: "asc"
|
|
700
|
+
* })
|
|
592
701
|
*/
|
|
593
702
|
listItemsLive(collectionId, request = {}, requestOptions) {
|
|
594
|
-
|
|
595
|
-
|
|
596
|
-
|
|
703
|
+
return core.HttpResponsePromise.fromPromise(this.__listItemsLive(collectionId, request, requestOptions));
|
|
704
|
+
}
|
|
705
|
+
__listItemsLive(collectionId_1) {
|
|
706
|
+
return __awaiter(this, arguments, void 0, function* (collectionId, request = {}, requestOptions) {
|
|
707
|
+
var _a, _b, _c;
|
|
708
|
+
const { cmsLocaleId, offset, limit, name, slug, lastPublished, sortBy, sortOrder } = request;
|
|
597
709
|
const _queryParams = {};
|
|
598
710
|
if (cmsLocaleId != null) {
|
|
599
711
|
_queryParams["cmsLocaleId"] = cmsLocaleId;
|
|
@@ -610,37 +722,54 @@ class Items {
|
|
|
610
722
|
if (slug != null) {
|
|
611
723
|
_queryParams["slug"] = slug;
|
|
612
724
|
}
|
|
725
|
+
if (lastPublished != null) {
|
|
726
|
+
_queryParams["lastPublished"] = serializers.ItemsListItemsLiveRequestLastPublished.jsonOrThrow(lastPublished, {
|
|
727
|
+
unrecognizedObjectKeys: "passthrough",
|
|
728
|
+
allowUnrecognizedUnionMembers: true,
|
|
729
|
+
allowUnrecognizedEnumValues: true,
|
|
730
|
+
breadcrumbsPrefix: ["request", "lastPublished"],
|
|
731
|
+
});
|
|
732
|
+
}
|
|
613
733
|
if (sortBy != null) {
|
|
614
|
-
_queryParams["sortBy"] = sortBy
|
|
734
|
+
_queryParams["sortBy"] = serializers.collections.ItemsListItemsLiveRequestSortBy.jsonOrThrow(sortBy, {
|
|
735
|
+
unrecognizedObjectKeys: "passthrough",
|
|
736
|
+
allowUnrecognizedUnionMembers: true,
|
|
737
|
+
allowUnrecognizedEnumValues: true,
|
|
738
|
+
});
|
|
615
739
|
}
|
|
616
740
|
if (sortOrder != null) {
|
|
617
|
-
_queryParams["sortOrder"] = sortOrder
|
|
741
|
+
_queryParams["sortOrder"] = serializers.collections.ItemsListItemsLiveRequestSortOrder.jsonOrThrow(sortOrder, {
|
|
742
|
+
unrecognizedObjectKeys: "passthrough",
|
|
743
|
+
allowUnrecognizedUnionMembers: true,
|
|
744
|
+
allowUnrecognizedEnumValues: true,
|
|
745
|
+
});
|
|
618
746
|
}
|
|
619
747
|
const _response = yield core.fetcher({
|
|
620
|
-
url: (0, url_join_1.default)((
|
|
748
|
+
url: (0, url_join_1.default)((_a = (yield core.Supplier.get(this._options.baseUrl))) !== null && _a !== void 0 ? _a : ((_b = (yield core.Supplier.get(this._options.environment))) !== null && _b !== void 0 ? _b : environments.WebflowEnvironment.DataApi)
|
|
621
749
|
.dataApi, `collections/${encodeURIComponent(collectionId)}/items/live`),
|
|
622
750
|
method: "GET",
|
|
623
|
-
headers:
|
|
624
|
-
contentType: "application/json",
|
|
751
|
+
headers: (0, headers_js_1.mergeHeaders)((_c = this._options) === null || _c === void 0 ? void 0 : _c.headers, (0, headers_js_1.mergeOnlyDefinedHeaders)({ Authorization: yield this._getAuthorizationHeader() }), requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers),
|
|
625
752
|
queryParameters: _queryParams,
|
|
626
|
-
requestType: "json",
|
|
627
753
|
timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
|
|
628
754
|
maxRetries: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries,
|
|
629
755
|
abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
|
|
630
756
|
});
|
|
631
757
|
if (_response.ok) {
|
|
632
|
-
return
|
|
633
|
-
|
|
634
|
-
|
|
635
|
-
|
|
636
|
-
|
|
637
|
-
|
|
638
|
-
|
|
758
|
+
return {
|
|
759
|
+
data: serializers.CollectionItemList.parseOrThrow(_response.body, {
|
|
760
|
+
unrecognizedObjectKeys: "passthrough",
|
|
761
|
+
allowUnrecognizedUnionMembers: true,
|
|
762
|
+
allowUnrecognizedEnumValues: true,
|
|
763
|
+
skipValidation: true,
|
|
764
|
+
breadcrumbsPrefix: ["response"],
|
|
765
|
+
}),
|
|
766
|
+
rawResponse: _response.rawResponse,
|
|
767
|
+
};
|
|
639
768
|
}
|
|
640
769
|
if (_response.error.reason === "status-code") {
|
|
641
770
|
switch (_response.error.statusCode) {
|
|
642
771
|
case 400:
|
|
643
|
-
throw new Webflow.BadRequestError(_response.error.body);
|
|
772
|
+
throw new Webflow.BadRequestError(_response.error.body, _response.rawResponse);
|
|
644
773
|
case 401:
|
|
645
774
|
throw new Webflow.UnauthorizedError(serializers.Error_.parseOrThrow(_response.error.body, {
|
|
646
775
|
unrecognizedObjectKeys: "passthrough",
|
|
@@ -648,7 +777,7 @@ class Items {
|
|
|
648
777
|
allowUnrecognizedEnumValues: true,
|
|
649
778
|
skipValidation: true,
|
|
650
779
|
breadcrumbsPrefix: ["response"],
|
|
651
|
-
}));
|
|
780
|
+
}), _response.rawResponse);
|
|
652
781
|
case 404:
|
|
653
782
|
throw new Webflow.NotFoundError(serializers.Error_.parseOrThrow(_response.error.body, {
|
|
654
783
|
unrecognizedObjectKeys: "passthrough",
|
|
@@ -656,7 +785,7 @@ class Items {
|
|
|
656
785
|
allowUnrecognizedEnumValues: true,
|
|
657
786
|
skipValidation: true,
|
|
658
787
|
breadcrumbsPrefix: ["response"],
|
|
659
|
-
}));
|
|
788
|
+
}), _response.rawResponse);
|
|
660
789
|
case 429:
|
|
661
790
|
throw new Webflow.TooManyRequestsError(serializers.Error_.parseOrThrow(_response.error.body, {
|
|
662
791
|
unrecognizedObjectKeys: "passthrough",
|
|
@@ -664,7 +793,7 @@ class Items {
|
|
|
664
793
|
allowUnrecognizedEnumValues: true,
|
|
665
794
|
skipValidation: true,
|
|
666
795
|
breadcrumbsPrefix: ["response"],
|
|
667
|
-
}));
|
|
796
|
+
}), _response.rawResponse);
|
|
668
797
|
case 500:
|
|
669
798
|
throw new Webflow.InternalServerError(serializers.Error_.parseOrThrow(_response.error.body, {
|
|
670
799
|
unrecognizedObjectKeys: "passthrough",
|
|
@@ -672,11 +801,12 @@ class Items {
|
|
|
672
801
|
allowUnrecognizedEnumValues: true,
|
|
673
802
|
skipValidation: true,
|
|
674
803
|
breadcrumbsPrefix: ["response"],
|
|
675
|
-
}));
|
|
804
|
+
}), _response.rawResponse);
|
|
676
805
|
default:
|
|
677
806
|
throw new errors.WebflowError({
|
|
678
807
|
statusCode: _response.error.statusCode,
|
|
679
808
|
body: _response.error.body,
|
|
809
|
+
rawResponse: _response.rawResponse,
|
|
680
810
|
});
|
|
681
811
|
}
|
|
682
812
|
}
|
|
@@ -685,12 +815,14 @@ class Items {
|
|
|
685
815
|
throw new errors.WebflowError({
|
|
686
816
|
statusCode: _response.error.statusCode,
|
|
687
817
|
body: _response.error.rawBody,
|
|
818
|
+
rawResponse: _response.rawResponse,
|
|
688
819
|
});
|
|
689
820
|
case "timeout":
|
|
690
821
|
throw new errors.WebflowTimeoutError("Timeout exceeded when calling GET /collections/{collection_id}/items/live.");
|
|
691
822
|
case "unknown":
|
|
692
823
|
throw new errors.WebflowError({
|
|
693
824
|
message: _response.error.errorMessage,
|
|
825
|
+
rawResponse: _response.rawResponse,
|
|
694
826
|
});
|
|
695
827
|
}
|
|
696
828
|
});
|
|
@@ -699,7 +831,7 @@ class Items {
|
|
|
699
831
|
* Create item(s) in a collection that will be immediately published to the live site.
|
|
700
832
|
*
|
|
701
833
|
*
|
|
702
|
-
* To create items across multiple locales, [please use this endpoint.](/
|
|
834
|
+
* To create items across multiple locales, [please use this endpoint.](/data/reference/cms/collection-items/staged-items/create-items)
|
|
703
835
|
*
|
|
704
836
|
*
|
|
705
837
|
* Required scope | `CMS:write`
|
|
@@ -716,43 +848,59 @@ class Items {
|
|
|
716
848
|
*
|
|
717
849
|
* @example
|
|
718
850
|
* await client.collections.items.createItemLive("580e63fc8c9a982ac9b8b745", {
|
|
719
|
-
*
|
|
720
|
-
*
|
|
721
|
-
*
|
|
722
|
-
*
|
|
723
|
-
*
|
|
851
|
+
* skipInvalidFiles: true,
|
|
852
|
+
* body: {
|
|
853
|
+
* isArchived: false,
|
|
854
|
+
* isDraft: false,
|
|
855
|
+
* fieldData: {
|
|
856
|
+
* name: "The Hitchhiker's Guide to the Galaxy",
|
|
857
|
+
* slug: "hitchhikers-guide-to-the-galaxy"
|
|
858
|
+
* }
|
|
724
859
|
* }
|
|
725
860
|
* })
|
|
726
861
|
*
|
|
727
862
|
* @example
|
|
728
863
|
* await client.collections.items.createItemLive("580e63fc8c9a982ac9b8b745", {
|
|
729
|
-
*
|
|
730
|
-
*
|
|
731
|
-
*
|
|
732
|
-
*
|
|
733
|
-
*
|
|
734
|
-
*
|
|
735
|
-
*
|
|
736
|
-
*
|
|
737
|
-
*
|
|
738
|
-
*
|
|
739
|
-
*
|
|
740
|
-
*
|
|
741
|
-
*
|
|
742
|
-
*
|
|
743
|
-
*
|
|
864
|
+
* skipInvalidFiles: true,
|
|
865
|
+
* body: {
|
|
866
|
+
* items: [{
|
|
867
|
+
* isArchived: false,
|
|
868
|
+
* isDraft: false,
|
|
869
|
+
* fieldData: {
|
|
870
|
+
* name: "Senior Data Analyst",
|
|
871
|
+
* slug: "senior-data-analyst"
|
|
872
|
+
* }
|
|
873
|
+
* }, {
|
|
874
|
+
* isArchived: false,
|
|
875
|
+
* isDraft: false,
|
|
876
|
+
* fieldData: {
|
|
877
|
+
* name: "Product Manager",
|
|
878
|
+
* slug: "product-manager"
|
|
879
|
+
* }
|
|
880
|
+
* }]
|
|
881
|
+
* }
|
|
744
882
|
* })
|
|
745
883
|
*/
|
|
746
884
|
createItemLive(collectionId, request, requestOptions) {
|
|
747
|
-
|
|
885
|
+
return core.HttpResponsePromise.fromPromise(this.__createItemLive(collectionId, request, requestOptions));
|
|
886
|
+
}
|
|
887
|
+
__createItemLive(collectionId, request, requestOptions) {
|
|
748
888
|
return __awaiter(this, void 0, void 0, function* () {
|
|
889
|
+
var _a, _b, _c;
|
|
890
|
+
const { skipInvalidFiles, body: _body } = request;
|
|
891
|
+
const _queryParams = {};
|
|
892
|
+
if (skipInvalidFiles != null) {
|
|
893
|
+
_queryParams["skipInvalidFiles"] = skipInvalidFiles.toString();
|
|
894
|
+
}
|
|
749
895
|
const _response = yield core.fetcher({
|
|
750
|
-
url: (0, url_join_1.default)((
|
|
896
|
+
url: (0, url_join_1.default)((_a = (yield core.Supplier.get(this._options.baseUrl))) !== null && _a !== void 0 ? _a : ((_b = (yield core.Supplier.get(this._options.environment))) !== null && _b !== void 0 ? _b : environments.WebflowEnvironment.DataApi)
|
|
897
|
+
.base, `collections/${encodeURIComponent(collectionId)}/items/live`),
|
|
751
898
|
method: "POST",
|
|
752
|
-
headers:
|
|
899
|
+
headers: (0, headers_js_1.mergeHeaders)((_c = this._options) === null || _c === void 0 ? void 0 : _c.headers, (0, headers_js_1.mergeOnlyDefinedHeaders)({ Authorization: yield this._getAuthorizationHeader() }), requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers),
|
|
753
900
|
contentType: "application/json",
|
|
901
|
+
queryParameters: _queryParams,
|
|
754
902
|
requestType: "json",
|
|
755
|
-
body: serializers.collections.
|
|
903
|
+
body: serializers.collections.ItemsCreateItemLiveRequestBody.jsonOrThrow(_body, {
|
|
756
904
|
unrecognizedObjectKeys: "passthrough",
|
|
757
905
|
allowUnrecognizedUnionMembers: true,
|
|
758
906
|
allowUnrecognizedEnumValues: true,
|
|
@@ -762,18 +910,21 @@ class Items {
|
|
|
762
910
|
abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
|
|
763
911
|
});
|
|
764
912
|
if (_response.ok) {
|
|
765
|
-
return
|
|
766
|
-
|
|
767
|
-
|
|
768
|
-
|
|
769
|
-
|
|
770
|
-
|
|
771
|
-
|
|
913
|
+
return {
|
|
914
|
+
data: serializers.CollectionItem.parseOrThrow(_response.body, {
|
|
915
|
+
unrecognizedObjectKeys: "passthrough",
|
|
916
|
+
allowUnrecognizedUnionMembers: true,
|
|
917
|
+
allowUnrecognizedEnumValues: true,
|
|
918
|
+
skipValidation: true,
|
|
919
|
+
breadcrumbsPrefix: ["response"],
|
|
920
|
+
}),
|
|
921
|
+
rawResponse: _response.rawResponse,
|
|
922
|
+
};
|
|
772
923
|
}
|
|
773
924
|
if (_response.error.reason === "status-code") {
|
|
774
925
|
switch (_response.error.statusCode) {
|
|
775
926
|
case 400:
|
|
776
|
-
throw new Webflow.BadRequestError(_response.error.body);
|
|
927
|
+
throw new Webflow.BadRequestError(_response.error.body, _response.rawResponse);
|
|
777
928
|
case 401:
|
|
778
929
|
throw new Webflow.UnauthorizedError(serializers.Error_.parseOrThrow(_response.error.body, {
|
|
779
930
|
unrecognizedObjectKeys: "passthrough",
|
|
@@ -781,7 +932,7 @@ class Items {
|
|
|
781
932
|
allowUnrecognizedEnumValues: true,
|
|
782
933
|
skipValidation: true,
|
|
783
934
|
breadcrumbsPrefix: ["response"],
|
|
784
|
-
}));
|
|
935
|
+
}), _response.rawResponse);
|
|
785
936
|
case 404:
|
|
786
937
|
throw new Webflow.NotFoundError(serializers.Error_.parseOrThrow(_response.error.body, {
|
|
787
938
|
unrecognizedObjectKeys: "passthrough",
|
|
@@ -789,7 +940,7 @@ class Items {
|
|
|
789
940
|
allowUnrecognizedEnumValues: true,
|
|
790
941
|
skipValidation: true,
|
|
791
942
|
breadcrumbsPrefix: ["response"],
|
|
792
|
-
}));
|
|
943
|
+
}), _response.rawResponse);
|
|
793
944
|
case 429:
|
|
794
945
|
throw new Webflow.TooManyRequestsError(serializers.Error_.parseOrThrow(_response.error.body, {
|
|
795
946
|
unrecognizedObjectKeys: "passthrough",
|
|
@@ -797,7 +948,7 @@ class Items {
|
|
|
797
948
|
allowUnrecognizedEnumValues: true,
|
|
798
949
|
skipValidation: true,
|
|
799
950
|
breadcrumbsPrefix: ["response"],
|
|
800
|
-
}));
|
|
951
|
+
}), _response.rawResponse);
|
|
801
952
|
case 500:
|
|
802
953
|
throw new Webflow.InternalServerError(serializers.Error_.parseOrThrow(_response.error.body, {
|
|
803
954
|
unrecognizedObjectKeys: "passthrough",
|
|
@@ -805,11 +956,12 @@ class Items {
|
|
|
805
956
|
allowUnrecognizedEnumValues: true,
|
|
806
957
|
skipValidation: true,
|
|
807
958
|
breadcrumbsPrefix: ["response"],
|
|
808
|
-
}));
|
|
959
|
+
}), _response.rawResponse);
|
|
809
960
|
default:
|
|
810
961
|
throw new errors.WebflowError({
|
|
811
962
|
statusCode: _response.error.statusCode,
|
|
812
963
|
body: _response.error.body,
|
|
964
|
+
rawResponse: _response.rawResponse,
|
|
813
965
|
});
|
|
814
966
|
}
|
|
815
967
|
}
|
|
@@ -818,20 +970,20 @@ class Items {
|
|
|
818
970
|
throw new errors.WebflowError({
|
|
819
971
|
statusCode: _response.error.statusCode,
|
|
820
972
|
body: _response.error.rawBody,
|
|
973
|
+
rawResponse: _response.rawResponse,
|
|
821
974
|
});
|
|
822
975
|
case "timeout":
|
|
823
976
|
throw new errors.WebflowTimeoutError("Timeout exceeded when calling POST /collections/{collection_id}/items/live.");
|
|
824
977
|
case "unknown":
|
|
825
978
|
throw new errors.WebflowError({
|
|
826
979
|
message: _response.error.errorMessage,
|
|
980
|
+
rawResponse: _response.rawResponse,
|
|
827
981
|
});
|
|
828
982
|
}
|
|
829
983
|
});
|
|
830
984
|
}
|
|
831
985
|
/**
|
|
832
|
-
*
|
|
833
|
-
*
|
|
834
|
-
* Using this endpoint to delete published item(s) will unpublish the item(s) from the live site and set the item(s) `isDraft` property to `true`.
|
|
986
|
+
* Unpublish up to 100 items from the live site and set the `isDraft` property to `true`.
|
|
835
987
|
*
|
|
836
988
|
* <Tip title="Localization Tip">Items will only be unpublished in the primary locale unless a `cmsLocaleId` is included in the request.</Tip>
|
|
837
989
|
*
|
|
@@ -855,12 +1007,16 @@ class Items {
|
|
|
855
1007
|
* })
|
|
856
1008
|
*/
|
|
857
1009
|
deleteItemsLive(collectionId, request, requestOptions) {
|
|
858
|
-
|
|
1010
|
+
return core.HttpResponsePromise.fromPromise(this.__deleteItemsLive(collectionId, request, requestOptions));
|
|
1011
|
+
}
|
|
1012
|
+
__deleteItemsLive(collectionId, request, requestOptions) {
|
|
859
1013
|
return __awaiter(this, void 0, void 0, function* () {
|
|
1014
|
+
var _a, _b, _c;
|
|
860
1015
|
const _response = yield core.fetcher({
|
|
861
|
-
url: (0, url_join_1.default)((
|
|
1016
|
+
url: (0, url_join_1.default)((_a = (yield core.Supplier.get(this._options.baseUrl))) !== null && _a !== void 0 ? _a : ((_b = (yield core.Supplier.get(this._options.environment))) !== null && _b !== void 0 ? _b : environments.WebflowEnvironment.DataApi)
|
|
1017
|
+
.base, `collections/${encodeURIComponent(collectionId)}/items/live`),
|
|
862
1018
|
method: "DELETE",
|
|
863
|
-
headers:
|
|
1019
|
+
headers: (0, headers_js_1.mergeHeaders)((_c = this._options) === null || _c === void 0 ? void 0 : _c.headers, (0, headers_js_1.mergeOnlyDefinedHeaders)({ Authorization: yield this._getAuthorizationHeader() }), requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers),
|
|
864
1020
|
contentType: "application/json",
|
|
865
1021
|
requestType: "json",
|
|
866
1022
|
body: serializers.collections.ItemsDeleteItemsLiveRequest.jsonOrThrow(request, {
|
|
@@ -873,12 +1029,12 @@ class Items {
|
|
|
873
1029
|
abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
|
|
874
1030
|
});
|
|
875
1031
|
if (_response.ok) {
|
|
876
|
-
return;
|
|
1032
|
+
return { data: undefined, rawResponse: _response.rawResponse };
|
|
877
1033
|
}
|
|
878
1034
|
if (_response.error.reason === "status-code") {
|
|
879
1035
|
switch (_response.error.statusCode) {
|
|
880
1036
|
case 400:
|
|
881
|
-
throw new Webflow.BadRequestError(_response.error.body);
|
|
1037
|
+
throw new Webflow.BadRequestError(_response.error.body, _response.rawResponse);
|
|
882
1038
|
case 401:
|
|
883
1039
|
throw new Webflow.UnauthorizedError(serializers.Error_.parseOrThrow(_response.error.body, {
|
|
884
1040
|
unrecognizedObjectKeys: "passthrough",
|
|
@@ -886,7 +1042,7 @@ class Items {
|
|
|
886
1042
|
allowUnrecognizedEnumValues: true,
|
|
887
1043
|
skipValidation: true,
|
|
888
1044
|
breadcrumbsPrefix: ["response"],
|
|
889
|
-
}));
|
|
1045
|
+
}), _response.rawResponse);
|
|
890
1046
|
case 404:
|
|
891
1047
|
throw new Webflow.NotFoundError(serializers.Error_.parseOrThrow(_response.error.body, {
|
|
892
1048
|
unrecognizedObjectKeys: "passthrough",
|
|
@@ -894,7 +1050,7 @@ class Items {
|
|
|
894
1050
|
allowUnrecognizedEnumValues: true,
|
|
895
1051
|
skipValidation: true,
|
|
896
1052
|
breadcrumbsPrefix: ["response"],
|
|
897
|
-
}));
|
|
1053
|
+
}), _response.rawResponse);
|
|
898
1054
|
case 429:
|
|
899
1055
|
throw new Webflow.TooManyRequestsError(serializers.Error_.parseOrThrow(_response.error.body, {
|
|
900
1056
|
unrecognizedObjectKeys: "passthrough",
|
|
@@ -902,7 +1058,7 @@ class Items {
|
|
|
902
1058
|
allowUnrecognizedEnumValues: true,
|
|
903
1059
|
skipValidation: true,
|
|
904
1060
|
breadcrumbsPrefix: ["response"],
|
|
905
|
-
}));
|
|
1061
|
+
}), _response.rawResponse);
|
|
906
1062
|
case 500:
|
|
907
1063
|
throw new Webflow.InternalServerError(serializers.Error_.parseOrThrow(_response.error.body, {
|
|
908
1064
|
unrecognizedObjectKeys: "passthrough",
|
|
@@ -910,11 +1066,12 @@ class Items {
|
|
|
910
1066
|
allowUnrecognizedEnumValues: true,
|
|
911
1067
|
skipValidation: true,
|
|
912
1068
|
breadcrumbsPrefix: ["response"],
|
|
913
|
-
}));
|
|
1069
|
+
}), _response.rawResponse);
|
|
914
1070
|
default:
|
|
915
1071
|
throw new errors.WebflowError({
|
|
916
1072
|
statusCode: _response.error.statusCode,
|
|
917
1073
|
body: _response.error.body,
|
|
1074
|
+
rawResponse: _response.rawResponse,
|
|
918
1075
|
});
|
|
919
1076
|
}
|
|
920
1077
|
}
|
|
@@ -923,12 +1080,14 @@ class Items {
|
|
|
923
1080
|
throw new errors.WebflowError({
|
|
924
1081
|
statusCode: _response.error.statusCode,
|
|
925
1082
|
body: _response.error.rawBody,
|
|
1083
|
+
rawResponse: _response.rawResponse,
|
|
926
1084
|
});
|
|
927
1085
|
case "timeout":
|
|
928
1086
|
throw new errors.WebflowTimeoutError("Timeout exceeded when calling DELETE /collections/{collection_id}/items/live.");
|
|
929
1087
|
case "unknown":
|
|
930
1088
|
throw new errors.WebflowError({
|
|
931
1089
|
message: _response.error.errorMessage,
|
|
1090
|
+
rawResponse: _response.rawResponse,
|
|
932
1091
|
});
|
|
933
1092
|
}
|
|
934
1093
|
});
|
|
@@ -953,6 +1112,7 @@ class Items {
|
|
|
953
1112
|
*
|
|
954
1113
|
* @example
|
|
955
1114
|
* await client.collections.items.updateItemsLive("580e63fc8c9a982ac9b8b745", {
|
|
1115
|
+
* skipInvalidFiles: true,
|
|
956
1116
|
* items: [{
|
|
957
1117
|
* id: "66f6ed9576ddacf3149d5ea6",
|
|
958
1118
|
* cmsLocaleId: "66f6e966c9e1dc700a857ca5",
|
|
@@ -986,6 +1146,7 @@ class Items {
|
|
|
986
1146
|
*
|
|
987
1147
|
* @example
|
|
988
1148
|
* await client.collections.items.updateItemsLive("580e63fc8c9a982ac9b8b745", {
|
|
1149
|
+
* skipInvalidFiles: true,
|
|
989
1150
|
* items: [{
|
|
990
1151
|
* id: "580e64008c9a982ac9b8b754",
|
|
991
1152
|
* isArchived: false,
|
|
@@ -1006,15 +1167,25 @@ class Items {
|
|
|
1006
1167
|
* })
|
|
1007
1168
|
*/
|
|
1008
1169
|
updateItemsLive(collectionId, request = {}, requestOptions) {
|
|
1009
|
-
|
|
1010
|
-
|
|
1170
|
+
return core.HttpResponsePromise.fromPromise(this.__updateItemsLive(collectionId, request, requestOptions));
|
|
1171
|
+
}
|
|
1172
|
+
__updateItemsLive(collectionId_1) {
|
|
1173
|
+
return __awaiter(this, arguments, void 0, function* (collectionId, request = {}, requestOptions) {
|
|
1174
|
+
var _a, _b, _c;
|
|
1175
|
+
const { skipInvalidFiles } = request, _body = __rest(request, ["skipInvalidFiles"]);
|
|
1176
|
+
const _queryParams = {};
|
|
1177
|
+
if (skipInvalidFiles != null) {
|
|
1178
|
+
_queryParams["skipInvalidFiles"] = skipInvalidFiles.toString();
|
|
1179
|
+
}
|
|
1011
1180
|
const _response = yield core.fetcher({
|
|
1012
|
-
url: (0, url_join_1.default)((
|
|
1181
|
+
url: (0, url_join_1.default)((_a = (yield core.Supplier.get(this._options.baseUrl))) !== null && _a !== void 0 ? _a : ((_b = (yield core.Supplier.get(this._options.environment))) !== null && _b !== void 0 ? _b : environments.WebflowEnvironment.DataApi)
|
|
1182
|
+
.base, `collections/${encodeURIComponent(collectionId)}/items/live`),
|
|
1013
1183
|
method: "PATCH",
|
|
1014
|
-
headers:
|
|
1184
|
+
headers: (0, headers_js_1.mergeHeaders)((_c = this._options) === null || _c === void 0 ? void 0 : _c.headers, (0, headers_js_1.mergeOnlyDefinedHeaders)({ Authorization: yield this._getAuthorizationHeader() }), requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers),
|
|
1015
1185
|
contentType: "application/json",
|
|
1186
|
+
queryParameters: _queryParams,
|
|
1016
1187
|
requestType: "json",
|
|
1017
|
-
body: serializers.collections.ItemsUpdateItemsLiveRequest.jsonOrThrow(
|
|
1188
|
+
body: serializers.collections.ItemsUpdateItemsLiveRequest.jsonOrThrow(_body, {
|
|
1018
1189
|
unrecognizedObjectKeys: "passthrough",
|
|
1019
1190
|
allowUnrecognizedUnionMembers: true,
|
|
1020
1191
|
allowUnrecognizedEnumValues: true,
|
|
@@ -1024,18 +1195,21 @@ class Items {
|
|
|
1024
1195
|
abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
|
|
1025
1196
|
});
|
|
1026
1197
|
if (_response.ok) {
|
|
1027
|
-
return
|
|
1028
|
-
|
|
1029
|
-
|
|
1030
|
-
|
|
1031
|
-
|
|
1032
|
-
|
|
1033
|
-
|
|
1198
|
+
return {
|
|
1199
|
+
data: serializers.CollectionItemListNoPagination.parseOrThrow(_response.body, {
|
|
1200
|
+
unrecognizedObjectKeys: "passthrough",
|
|
1201
|
+
allowUnrecognizedUnionMembers: true,
|
|
1202
|
+
allowUnrecognizedEnumValues: true,
|
|
1203
|
+
skipValidation: true,
|
|
1204
|
+
breadcrumbsPrefix: ["response"],
|
|
1205
|
+
}),
|
|
1206
|
+
rawResponse: _response.rawResponse,
|
|
1207
|
+
};
|
|
1034
1208
|
}
|
|
1035
1209
|
if (_response.error.reason === "status-code") {
|
|
1036
1210
|
switch (_response.error.statusCode) {
|
|
1037
1211
|
case 400:
|
|
1038
|
-
throw new Webflow.BadRequestError(_response.error.body);
|
|
1212
|
+
throw new Webflow.BadRequestError(_response.error.body, _response.rawResponse);
|
|
1039
1213
|
case 401:
|
|
1040
1214
|
throw new Webflow.UnauthorizedError(serializers.Error_.parseOrThrow(_response.error.body, {
|
|
1041
1215
|
unrecognizedObjectKeys: "passthrough",
|
|
@@ -1043,7 +1217,7 @@ class Items {
|
|
|
1043
1217
|
allowUnrecognizedEnumValues: true,
|
|
1044
1218
|
skipValidation: true,
|
|
1045
1219
|
breadcrumbsPrefix: ["response"],
|
|
1046
|
-
}));
|
|
1220
|
+
}), _response.rawResponse);
|
|
1047
1221
|
case 404:
|
|
1048
1222
|
throw new Webflow.NotFoundError(serializers.Error_.parseOrThrow(_response.error.body, {
|
|
1049
1223
|
unrecognizedObjectKeys: "passthrough",
|
|
@@ -1051,9 +1225,9 @@ class Items {
|
|
|
1051
1225
|
allowUnrecognizedEnumValues: true,
|
|
1052
1226
|
skipValidation: true,
|
|
1053
1227
|
breadcrumbsPrefix: ["response"],
|
|
1054
|
-
}));
|
|
1228
|
+
}), _response.rawResponse);
|
|
1055
1229
|
case 409:
|
|
1056
|
-
throw new Webflow.ConflictError(_response.error.body);
|
|
1230
|
+
throw new Webflow.ConflictError(_response.error.body, _response.rawResponse);
|
|
1057
1231
|
case 429:
|
|
1058
1232
|
throw new Webflow.TooManyRequestsError(serializers.Error_.parseOrThrow(_response.error.body, {
|
|
1059
1233
|
unrecognizedObjectKeys: "passthrough",
|
|
@@ -1061,7 +1235,7 @@ class Items {
|
|
|
1061
1235
|
allowUnrecognizedEnumValues: true,
|
|
1062
1236
|
skipValidation: true,
|
|
1063
1237
|
breadcrumbsPrefix: ["response"],
|
|
1064
|
-
}));
|
|
1238
|
+
}), _response.rawResponse);
|
|
1065
1239
|
case 500:
|
|
1066
1240
|
throw new Webflow.InternalServerError(serializers.Error_.parseOrThrow(_response.error.body, {
|
|
1067
1241
|
unrecognizedObjectKeys: "passthrough",
|
|
@@ -1069,11 +1243,12 @@ class Items {
|
|
|
1069
1243
|
allowUnrecognizedEnumValues: true,
|
|
1070
1244
|
skipValidation: true,
|
|
1071
1245
|
breadcrumbsPrefix: ["response"],
|
|
1072
|
-
}));
|
|
1246
|
+
}), _response.rawResponse);
|
|
1073
1247
|
default:
|
|
1074
1248
|
throw new errors.WebflowError({
|
|
1075
1249
|
statusCode: _response.error.statusCode,
|
|
1076
1250
|
body: _response.error.body,
|
|
1251
|
+
rawResponse: _response.rawResponse,
|
|
1077
1252
|
});
|
|
1078
1253
|
}
|
|
1079
1254
|
}
|
|
@@ -1082,12 +1257,14 @@ class Items {
|
|
|
1082
1257
|
throw new errors.WebflowError({
|
|
1083
1258
|
statusCode: _response.error.statusCode,
|
|
1084
1259
|
body: _response.error.rawBody,
|
|
1260
|
+
rawResponse: _response.rawResponse,
|
|
1085
1261
|
});
|
|
1086
1262
|
case "timeout":
|
|
1087
1263
|
throw new errors.WebflowTimeoutError("Timeout exceeded when calling PATCH /collections/{collection_id}/items/live.");
|
|
1088
1264
|
case "unknown":
|
|
1089
1265
|
throw new errors.WebflowError({
|
|
1090
1266
|
message: _response.error.errorMessage,
|
|
1267
|
+
rawResponse: _response.rawResponse,
|
|
1091
1268
|
});
|
|
1092
1269
|
}
|
|
1093
1270
|
});
|
|
@@ -1114,6 +1291,7 @@ class Items {
|
|
|
1114
1291
|
*
|
|
1115
1292
|
* @example
|
|
1116
1293
|
* await client.collections.items.createItems("580e63fc8c9a982ac9b8b745", {
|
|
1294
|
+
* skipInvalidFiles: true,
|
|
1117
1295
|
* cmsLocaleIds: ["66f6e966c9e1dc700a857ca3", "66f6e966c9e1dc700a857ca4", "66f6e966c9e1dc700a857ca5"],
|
|
1118
1296
|
* isArchived: false,
|
|
1119
1297
|
* isDraft: false,
|
|
@@ -1125,6 +1303,7 @@ class Items {
|
|
|
1125
1303
|
*
|
|
1126
1304
|
* @example
|
|
1127
1305
|
* await client.collections.items.createItems("580e63fc8c9a982ac9b8b745", {
|
|
1306
|
+
* skipInvalidFiles: true,
|
|
1128
1307
|
* cmsLocaleIds: ["66f6e966c9e1dc700a857ca3", "66f6e966c9e1dc700a857ca4"],
|
|
1129
1308
|
* isArchived: false,
|
|
1130
1309
|
* isDraft: false,
|
|
@@ -1138,15 +1317,25 @@ class Items {
|
|
|
1138
1317
|
* })
|
|
1139
1318
|
*/
|
|
1140
1319
|
createItems(collectionId, request, requestOptions) {
|
|
1141
|
-
|
|
1320
|
+
return core.HttpResponsePromise.fromPromise(this.__createItems(collectionId, request, requestOptions));
|
|
1321
|
+
}
|
|
1322
|
+
__createItems(collectionId, request, requestOptions) {
|
|
1142
1323
|
return __awaiter(this, void 0, void 0, function* () {
|
|
1324
|
+
var _a, _b, _c;
|
|
1325
|
+
const { skipInvalidFiles } = request, _body = __rest(request, ["skipInvalidFiles"]);
|
|
1326
|
+
const _queryParams = {};
|
|
1327
|
+
if (skipInvalidFiles != null) {
|
|
1328
|
+
_queryParams["skipInvalidFiles"] = skipInvalidFiles.toString();
|
|
1329
|
+
}
|
|
1143
1330
|
const _response = yield core.fetcher({
|
|
1144
|
-
url: (0, url_join_1.default)((
|
|
1331
|
+
url: (0, url_join_1.default)((_a = (yield core.Supplier.get(this._options.baseUrl))) !== null && _a !== void 0 ? _a : ((_b = (yield core.Supplier.get(this._options.environment))) !== null && _b !== void 0 ? _b : environments.WebflowEnvironment.DataApi)
|
|
1332
|
+
.base, `collections/${encodeURIComponent(collectionId)}/items/bulk`),
|
|
1145
1333
|
method: "POST",
|
|
1146
|
-
headers:
|
|
1334
|
+
headers: (0, headers_js_1.mergeHeaders)((_c = this._options) === null || _c === void 0 ? void 0 : _c.headers, (0, headers_js_1.mergeOnlyDefinedHeaders)({ Authorization: yield this._getAuthorizationHeader() }), requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers),
|
|
1147
1335
|
contentType: "application/json",
|
|
1336
|
+
queryParameters: _queryParams,
|
|
1148
1337
|
requestType: "json",
|
|
1149
|
-
body: serializers.collections.CreateBulkCollectionItemRequestBody.jsonOrThrow(
|
|
1338
|
+
body: serializers.collections.CreateBulkCollectionItemRequestBody.jsonOrThrow(_body, {
|
|
1150
1339
|
unrecognizedObjectKeys: "passthrough",
|
|
1151
1340
|
allowUnrecognizedUnionMembers: true,
|
|
1152
1341
|
allowUnrecognizedEnumValues: true,
|
|
@@ -1156,18 +1345,21 @@ class Items {
|
|
|
1156
1345
|
abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
|
|
1157
1346
|
});
|
|
1158
1347
|
if (_response.ok) {
|
|
1159
|
-
return
|
|
1160
|
-
|
|
1161
|
-
|
|
1162
|
-
|
|
1163
|
-
|
|
1164
|
-
|
|
1165
|
-
|
|
1348
|
+
return {
|
|
1349
|
+
data: serializers.BulkCollectionItem.parseOrThrow(_response.body, {
|
|
1350
|
+
unrecognizedObjectKeys: "passthrough",
|
|
1351
|
+
allowUnrecognizedUnionMembers: true,
|
|
1352
|
+
allowUnrecognizedEnumValues: true,
|
|
1353
|
+
skipValidation: true,
|
|
1354
|
+
breadcrumbsPrefix: ["response"],
|
|
1355
|
+
}),
|
|
1356
|
+
rawResponse: _response.rawResponse,
|
|
1357
|
+
};
|
|
1166
1358
|
}
|
|
1167
1359
|
if (_response.error.reason === "status-code") {
|
|
1168
1360
|
switch (_response.error.statusCode) {
|
|
1169
1361
|
case 400:
|
|
1170
|
-
throw new Webflow.BadRequestError(_response.error.body);
|
|
1362
|
+
throw new Webflow.BadRequestError(_response.error.body, _response.rawResponse);
|
|
1171
1363
|
case 401:
|
|
1172
1364
|
throw new Webflow.UnauthorizedError(serializers.Error_.parseOrThrow(_response.error.body, {
|
|
1173
1365
|
unrecognizedObjectKeys: "passthrough",
|
|
@@ -1175,7 +1367,7 @@ class Items {
|
|
|
1175
1367
|
allowUnrecognizedEnumValues: true,
|
|
1176
1368
|
skipValidation: true,
|
|
1177
1369
|
breadcrumbsPrefix: ["response"],
|
|
1178
|
-
}));
|
|
1370
|
+
}), _response.rawResponse);
|
|
1179
1371
|
case 404:
|
|
1180
1372
|
throw new Webflow.NotFoundError(serializers.Error_.parseOrThrow(_response.error.body, {
|
|
1181
1373
|
unrecognizedObjectKeys: "passthrough",
|
|
@@ -1183,7 +1375,7 @@ class Items {
|
|
|
1183
1375
|
allowUnrecognizedEnumValues: true,
|
|
1184
1376
|
skipValidation: true,
|
|
1185
1377
|
breadcrumbsPrefix: ["response"],
|
|
1186
|
-
}));
|
|
1378
|
+
}), _response.rawResponse);
|
|
1187
1379
|
case 429:
|
|
1188
1380
|
throw new Webflow.TooManyRequestsError(serializers.Error_.parseOrThrow(_response.error.body, {
|
|
1189
1381
|
unrecognizedObjectKeys: "passthrough",
|
|
@@ -1191,7 +1383,7 @@ class Items {
|
|
|
1191
1383
|
allowUnrecognizedEnumValues: true,
|
|
1192
1384
|
skipValidation: true,
|
|
1193
1385
|
breadcrumbsPrefix: ["response"],
|
|
1194
|
-
}));
|
|
1386
|
+
}), _response.rawResponse);
|
|
1195
1387
|
case 500:
|
|
1196
1388
|
throw new Webflow.InternalServerError(serializers.Error_.parseOrThrow(_response.error.body, {
|
|
1197
1389
|
unrecognizedObjectKeys: "passthrough",
|
|
@@ -1199,11 +1391,12 @@ class Items {
|
|
|
1199
1391
|
allowUnrecognizedEnumValues: true,
|
|
1200
1392
|
skipValidation: true,
|
|
1201
1393
|
breadcrumbsPrefix: ["response"],
|
|
1202
|
-
}));
|
|
1394
|
+
}), _response.rawResponse);
|
|
1203
1395
|
default:
|
|
1204
1396
|
throw new errors.WebflowError({
|
|
1205
1397
|
statusCode: _response.error.statusCode,
|
|
1206
1398
|
body: _response.error.body,
|
|
1399
|
+
rawResponse: _response.rawResponse,
|
|
1207
1400
|
});
|
|
1208
1401
|
}
|
|
1209
1402
|
}
|
|
@@ -1212,12 +1405,14 @@ class Items {
|
|
|
1212
1405
|
throw new errors.WebflowError({
|
|
1213
1406
|
statusCode: _response.error.statusCode,
|
|
1214
1407
|
body: _response.error.rawBody,
|
|
1408
|
+
rawResponse: _response.rawResponse,
|
|
1215
1409
|
});
|
|
1216
1410
|
case "timeout":
|
|
1217
1411
|
throw new errors.WebflowTimeoutError("Timeout exceeded when calling POST /collections/{collection_id}/items/bulk.");
|
|
1218
1412
|
case "unknown":
|
|
1219
1413
|
throw new errors.WebflowError({
|
|
1220
1414
|
message: _response.error.errorMessage,
|
|
1415
|
+
rawResponse: _response.rawResponse,
|
|
1221
1416
|
});
|
|
1222
1417
|
}
|
|
1223
1418
|
});
|
|
@@ -1239,41 +1434,47 @@ class Items {
|
|
|
1239
1434
|
* @throws {@link Webflow.InternalServerError}
|
|
1240
1435
|
*
|
|
1241
1436
|
* @example
|
|
1242
|
-
* await client.collections.items.getItem("580e63fc8c9a982ac9b8b745", "580e64008c9a982ac9b8b754"
|
|
1437
|
+
* await client.collections.items.getItem("580e63fc8c9a982ac9b8b745", "580e64008c9a982ac9b8b754", {
|
|
1438
|
+
* cmsLocaleId: "cmsLocaleId"
|
|
1439
|
+
* })
|
|
1243
1440
|
*/
|
|
1244
1441
|
getItem(collectionId, itemId, request = {}, requestOptions) {
|
|
1245
|
-
|
|
1246
|
-
|
|
1442
|
+
return core.HttpResponsePromise.fromPromise(this.__getItem(collectionId, itemId, request, requestOptions));
|
|
1443
|
+
}
|
|
1444
|
+
__getItem(collectionId_1, itemId_1) {
|
|
1445
|
+
return __awaiter(this, arguments, void 0, function* (collectionId, itemId, request = {}, requestOptions) {
|
|
1446
|
+
var _a, _b, _c;
|
|
1247
1447
|
const { cmsLocaleId } = request;
|
|
1248
1448
|
const _queryParams = {};
|
|
1249
1449
|
if (cmsLocaleId != null) {
|
|
1250
1450
|
_queryParams["cmsLocaleId"] = cmsLocaleId;
|
|
1251
1451
|
}
|
|
1252
1452
|
const _response = yield core.fetcher({
|
|
1253
|
-
url: (0, url_join_1.default)((
|
|
1254
|
-
.
|
|
1453
|
+
url: (0, url_join_1.default)((_a = (yield core.Supplier.get(this._options.baseUrl))) !== null && _a !== void 0 ? _a : ((_b = (yield core.Supplier.get(this._options.environment))) !== null && _b !== void 0 ? _b : environments.WebflowEnvironment.DataApi)
|
|
1454
|
+
.base, `collections/${encodeURIComponent(collectionId)}/items/${encodeURIComponent(itemId)}`),
|
|
1255
1455
|
method: "GET",
|
|
1256
|
-
headers:
|
|
1257
|
-
contentType: "application/json",
|
|
1456
|
+
headers: (0, headers_js_1.mergeHeaders)((_c = this._options) === null || _c === void 0 ? void 0 : _c.headers, (0, headers_js_1.mergeOnlyDefinedHeaders)({ Authorization: yield this._getAuthorizationHeader() }), requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers),
|
|
1258
1457
|
queryParameters: _queryParams,
|
|
1259
|
-
requestType: "json",
|
|
1260
1458
|
timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
|
|
1261
1459
|
maxRetries: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries,
|
|
1262
1460
|
abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
|
|
1263
1461
|
});
|
|
1264
1462
|
if (_response.ok) {
|
|
1265
|
-
return
|
|
1266
|
-
|
|
1267
|
-
|
|
1268
|
-
|
|
1269
|
-
|
|
1270
|
-
|
|
1271
|
-
|
|
1463
|
+
return {
|
|
1464
|
+
data: serializers.CollectionItem.parseOrThrow(_response.body, {
|
|
1465
|
+
unrecognizedObjectKeys: "passthrough",
|
|
1466
|
+
allowUnrecognizedUnionMembers: true,
|
|
1467
|
+
allowUnrecognizedEnumValues: true,
|
|
1468
|
+
skipValidation: true,
|
|
1469
|
+
breadcrumbsPrefix: ["response"],
|
|
1470
|
+
}),
|
|
1471
|
+
rawResponse: _response.rawResponse,
|
|
1472
|
+
};
|
|
1272
1473
|
}
|
|
1273
1474
|
if (_response.error.reason === "status-code") {
|
|
1274
1475
|
switch (_response.error.statusCode) {
|
|
1275
1476
|
case 400:
|
|
1276
|
-
throw new Webflow.BadRequestError(_response.error.body);
|
|
1477
|
+
throw new Webflow.BadRequestError(_response.error.body, _response.rawResponse);
|
|
1277
1478
|
case 401:
|
|
1278
1479
|
throw new Webflow.UnauthorizedError(serializers.Error_.parseOrThrow(_response.error.body, {
|
|
1279
1480
|
unrecognizedObjectKeys: "passthrough",
|
|
@@ -1281,7 +1482,7 @@ class Items {
|
|
|
1281
1482
|
allowUnrecognizedEnumValues: true,
|
|
1282
1483
|
skipValidation: true,
|
|
1283
1484
|
breadcrumbsPrefix: ["response"],
|
|
1284
|
-
}));
|
|
1485
|
+
}), _response.rawResponse);
|
|
1285
1486
|
case 404:
|
|
1286
1487
|
throw new Webflow.NotFoundError(serializers.Error_.parseOrThrow(_response.error.body, {
|
|
1287
1488
|
unrecognizedObjectKeys: "passthrough",
|
|
@@ -1289,7 +1490,7 @@ class Items {
|
|
|
1289
1490
|
allowUnrecognizedEnumValues: true,
|
|
1290
1491
|
skipValidation: true,
|
|
1291
1492
|
breadcrumbsPrefix: ["response"],
|
|
1292
|
-
}));
|
|
1493
|
+
}), _response.rawResponse);
|
|
1293
1494
|
case 429:
|
|
1294
1495
|
throw new Webflow.TooManyRequestsError(serializers.Error_.parseOrThrow(_response.error.body, {
|
|
1295
1496
|
unrecognizedObjectKeys: "passthrough",
|
|
@@ -1297,7 +1498,7 @@ class Items {
|
|
|
1297
1498
|
allowUnrecognizedEnumValues: true,
|
|
1298
1499
|
skipValidation: true,
|
|
1299
1500
|
breadcrumbsPrefix: ["response"],
|
|
1300
|
-
}));
|
|
1501
|
+
}), _response.rawResponse);
|
|
1301
1502
|
case 500:
|
|
1302
1503
|
throw new Webflow.InternalServerError(serializers.Error_.parseOrThrow(_response.error.body, {
|
|
1303
1504
|
unrecognizedObjectKeys: "passthrough",
|
|
@@ -1305,11 +1506,12 @@ class Items {
|
|
|
1305
1506
|
allowUnrecognizedEnumValues: true,
|
|
1306
1507
|
skipValidation: true,
|
|
1307
1508
|
breadcrumbsPrefix: ["response"],
|
|
1308
|
-
}));
|
|
1509
|
+
}), _response.rawResponse);
|
|
1309
1510
|
default:
|
|
1310
1511
|
throw new errors.WebflowError({
|
|
1311
1512
|
statusCode: _response.error.statusCode,
|
|
1312
1513
|
body: _response.error.body,
|
|
1514
|
+
rawResponse: _response.rawResponse,
|
|
1313
1515
|
});
|
|
1314
1516
|
}
|
|
1315
1517
|
}
|
|
@@ -1318,12 +1520,14 @@ class Items {
|
|
|
1318
1520
|
throw new errors.WebflowError({
|
|
1319
1521
|
statusCode: _response.error.statusCode,
|
|
1320
1522
|
body: _response.error.rawBody,
|
|
1523
|
+
rawResponse: _response.rawResponse,
|
|
1321
1524
|
});
|
|
1322
1525
|
case "timeout":
|
|
1323
1526
|
throw new errors.WebflowTimeoutError("Timeout exceeded when calling GET /collections/{collection_id}/items/{item_id}.");
|
|
1324
1527
|
case "unknown":
|
|
1325
1528
|
throw new errors.WebflowError({
|
|
1326
1529
|
message: _response.error.errorMessage,
|
|
1530
|
+
rawResponse: _response.rawResponse,
|
|
1327
1531
|
});
|
|
1328
1532
|
}
|
|
1329
1533
|
});
|
|
@@ -1345,34 +1549,38 @@ class Items {
|
|
|
1345
1549
|
* @throws {@link Webflow.InternalServerError}
|
|
1346
1550
|
*
|
|
1347
1551
|
* @example
|
|
1348
|
-
* await client.collections.items.deleteItem("580e63fc8c9a982ac9b8b745", "580e64008c9a982ac9b8b754"
|
|
1552
|
+
* await client.collections.items.deleteItem("580e63fc8c9a982ac9b8b745", "580e64008c9a982ac9b8b754", {
|
|
1553
|
+
* cmsLocaleId: "cmsLocaleId"
|
|
1554
|
+
* })
|
|
1349
1555
|
*/
|
|
1350
1556
|
deleteItem(collectionId, itemId, request = {}, requestOptions) {
|
|
1351
|
-
|
|
1352
|
-
|
|
1557
|
+
return core.HttpResponsePromise.fromPromise(this.__deleteItem(collectionId, itemId, request, requestOptions));
|
|
1558
|
+
}
|
|
1559
|
+
__deleteItem(collectionId_1, itemId_1) {
|
|
1560
|
+
return __awaiter(this, arguments, void 0, function* (collectionId, itemId, request = {}, requestOptions) {
|
|
1561
|
+
var _a, _b, _c;
|
|
1353
1562
|
const { cmsLocaleId } = request;
|
|
1354
1563
|
const _queryParams = {};
|
|
1355
1564
|
if (cmsLocaleId != null) {
|
|
1356
1565
|
_queryParams["cmsLocaleId"] = cmsLocaleId;
|
|
1357
1566
|
}
|
|
1358
1567
|
const _response = yield core.fetcher({
|
|
1359
|
-
url: (0, url_join_1.default)((
|
|
1568
|
+
url: (0, url_join_1.default)((_a = (yield core.Supplier.get(this._options.baseUrl))) !== null && _a !== void 0 ? _a : ((_b = (yield core.Supplier.get(this._options.environment))) !== null && _b !== void 0 ? _b : environments.WebflowEnvironment.DataApi)
|
|
1569
|
+
.base, `collections/${encodeURIComponent(collectionId)}/items/${encodeURIComponent(itemId)}`),
|
|
1360
1570
|
method: "DELETE",
|
|
1361
|
-
headers:
|
|
1362
|
-
contentType: "application/json",
|
|
1571
|
+
headers: (0, headers_js_1.mergeHeaders)((_c = this._options) === null || _c === void 0 ? void 0 : _c.headers, (0, headers_js_1.mergeOnlyDefinedHeaders)({ Authorization: yield this._getAuthorizationHeader() }), requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers),
|
|
1363
1572
|
queryParameters: _queryParams,
|
|
1364
|
-
requestType: "json",
|
|
1365
1573
|
timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
|
|
1366
1574
|
maxRetries: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries,
|
|
1367
1575
|
abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
|
|
1368
1576
|
});
|
|
1369
1577
|
if (_response.ok) {
|
|
1370
|
-
return;
|
|
1578
|
+
return { data: undefined, rawResponse: _response.rawResponse };
|
|
1371
1579
|
}
|
|
1372
1580
|
if (_response.error.reason === "status-code") {
|
|
1373
1581
|
switch (_response.error.statusCode) {
|
|
1374
1582
|
case 400:
|
|
1375
|
-
throw new Webflow.BadRequestError(_response.error.body);
|
|
1583
|
+
throw new Webflow.BadRequestError(_response.error.body, _response.rawResponse);
|
|
1376
1584
|
case 401:
|
|
1377
1585
|
throw new Webflow.UnauthorizedError(serializers.Error_.parseOrThrow(_response.error.body, {
|
|
1378
1586
|
unrecognizedObjectKeys: "passthrough",
|
|
@@ -1380,7 +1588,7 @@ class Items {
|
|
|
1380
1588
|
allowUnrecognizedEnumValues: true,
|
|
1381
1589
|
skipValidation: true,
|
|
1382
1590
|
breadcrumbsPrefix: ["response"],
|
|
1383
|
-
}));
|
|
1591
|
+
}), _response.rawResponse);
|
|
1384
1592
|
case 404:
|
|
1385
1593
|
throw new Webflow.NotFoundError(serializers.Error_.parseOrThrow(_response.error.body, {
|
|
1386
1594
|
unrecognizedObjectKeys: "passthrough",
|
|
@@ -1388,7 +1596,7 @@ class Items {
|
|
|
1388
1596
|
allowUnrecognizedEnumValues: true,
|
|
1389
1597
|
skipValidation: true,
|
|
1390
1598
|
breadcrumbsPrefix: ["response"],
|
|
1391
|
-
}));
|
|
1599
|
+
}), _response.rawResponse);
|
|
1392
1600
|
case 429:
|
|
1393
1601
|
throw new Webflow.TooManyRequestsError(serializers.Error_.parseOrThrow(_response.error.body, {
|
|
1394
1602
|
unrecognizedObjectKeys: "passthrough",
|
|
@@ -1396,7 +1604,7 @@ class Items {
|
|
|
1396
1604
|
allowUnrecognizedEnumValues: true,
|
|
1397
1605
|
skipValidation: true,
|
|
1398
1606
|
breadcrumbsPrefix: ["response"],
|
|
1399
|
-
}));
|
|
1607
|
+
}), _response.rawResponse);
|
|
1400
1608
|
case 500:
|
|
1401
1609
|
throw new Webflow.InternalServerError(serializers.Error_.parseOrThrow(_response.error.body, {
|
|
1402
1610
|
unrecognizedObjectKeys: "passthrough",
|
|
@@ -1404,11 +1612,12 @@ class Items {
|
|
|
1404
1612
|
allowUnrecognizedEnumValues: true,
|
|
1405
1613
|
skipValidation: true,
|
|
1406
1614
|
breadcrumbsPrefix: ["response"],
|
|
1407
|
-
}));
|
|
1615
|
+
}), _response.rawResponse);
|
|
1408
1616
|
default:
|
|
1409
1617
|
throw new errors.WebflowError({
|
|
1410
1618
|
statusCode: _response.error.statusCode,
|
|
1411
1619
|
body: _response.error.body,
|
|
1620
|
+
rawResponse: _response.rawResponse,
|
|
1412
1621
|
});
|
|
1413
1622
|
}
|
|
1414
1623
|
}
|
|
@@ -1417,12 +1626,14 @@ class Items {
|
|
|
1417
1626
|
throw new errors.WebflowError({
|
|
1418
1627
|
statusCode: _response.error.statusCode,
|
|
1419
1628
|
body: _response.error.rawBody,
|
|
1629
|
+
rawResponse: _response.rawResponse,
|
|
1420
1630
|
});
|
|
1421
1631
|
case "timeout":
|
|
1422
1632
|
throw new errors.WebflowTimeoutError("Timeout exceeded when calling DELETE /collections/{collection_id}/items/{item_id}.");
|
|
1423
1633
|
case "unknown":
|
|
1424
1634
|
throw new errors.WebflowError({
|
|
1425
1635
|
message: _response.error.errorMessage,
|
|
1636
|
+
rawResponse: _response.rawResponse,
|
|
1426
1637
|
});
|
|
1427
1638
|
}
|
|
1428
1639
|
});
|
|
@@ -1434,7 +1645,7 @@ class Items {
|
|
|
1434
1645
|
*
|
|
1435
1646
|
* @param {string} collectionId - Unique identifier for a Collection
|
|
1436
1647
|
* @param {string} itemId - Unique identifier for an Item
|
|
1437
|
-
* @param {Webflow.
|
|
1648
|
+
* @param {Webflow.collections.ItemsUpdateItemRequest} request
|
|
1438
1649
|
* @param {Items.RequestOptions} requestOptions - Request-specific configuration.
|
|
1439
1650
|
*
|
|
1440
1651
|
* @throws {@link Webflow.BadRequestError}
|
|
@@ -1445,24 +1656,37 @@ class Items {
|
|
|
1445
1656
|
*
|
|
1446
1657
|
* @example
|
|
1447
1658
|
* await client.collections.items.updateItem("580e63fc8c9a982ac9b8b745", "580e64008c9a982ac9b8b754", {
|
|
1448
|
-
*
|
|
1449
|
-
*
|
|
1450
|
-
*
|
|
1451
|
-
*
|
|
1452
|
-
*
|
|
1659
|
+
* skipInvalidFiles: true,
|
|
1660
|
+
* body: {
|
|
1661
|
+
* isArchived: false,
|
|
1662
|
+
* isDraft: false,
|
|
1663
|
+
* fieldData: {
|
|
1664
|
+
* name: "The Hitchhiker's Guide to the Galaxy",
|
|
1665
|
+
* slug: "hitchhikers-guide-to-the-galaxy"
|
|
1666
|
+
* }
|
|
1453
1667
|
* }
|
|
1454
1668
|
* })
|
|
1455
1669
|
*/
|
|
1456
1670
|
updateItem(collectionId, itemId, request, requestOptions) {
|
|
1457
|
-
|
|
1671
|
+
return core.HttpResponsePromise.fromPromise(this.__updateItem(collectionId, itemId, request, requestOptions));
|
|
1672
|
+
}
|
|
1673
|
+
__updateItem(collectionId, itemId, request, requestOptions) {
|
|
1458
1674
|
return __awaiter(this, void 0, void 0, function* () {
|
|
1675
|
+
var _a, _b, _c;
|
|
1676
|
+
const { skipInvalidFiles, body: _body } = request;
|
|
1677
|
+
const _queryParams = {};
|
|
1678
|
+
if (skipInvalidFiles != null) {
|
|
1679
|
+
_queryParams["skipInvalidFiles"] = skipInvalidFiles.toString();
|
|
1680
|
+
}
|
|
1459
1681
|
const _response = yield core.fetcher({
|
|
1460
|
-
url: (0, url_join_1.default)((
|
|
1682
|
+
url: (0, url_join_1.default)((_a = (yield core.Supplier.get(this._options.baseUrl))) !== null && _a !== void 0 ? _a : ((_b = (yield core.Supplier.get(this._options.environment))) !== null && _b !== void 0 ? _b : environments.WebflowEnvironment.DataApi)
|
|
1683
|
+
.base, `collections/${encodeURIComponent(collectionId)}/items/${encodeURIComponent(itemId)}`),
|
|
1461
1684
|
method: "PATCH",
|
|
1462
|
-
headers:
|
|
1685
|
+
headers: (0, headers_js_1.mergeHeaders)((_c = this._options) === null || _c === void 0 ? void 0 : _c.headers, (0, headers_js_1.mergeOnlyDefinedHeaders)({ Authorization: yield this._getAuthorizationHeader() }), requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers),
|
|
1463
1686
|
contentType: "application/json",
|
|
1687
|
+
queryParameters: _queryParams,
|
|
1464
1688
|
requestType: "json",
|
|
1465
|
-
body: serializers.CollectionItemPatchSingle.jsonOrThrow(
|
|
1689
|
+
body: serializers.CollectionItemPatchSingle.jsonOrThrow(_body, {
|
|
1466
1690
|
unrecognizedObjectKeys: "passthrough",
|
|
1467
1691
|
allowUnrecognizedUnionMembers: true,
|
|
1468
1692
|
allowUnrecognizedEnumValues: true,
|
|
@@ -1472,18 +1696,21 @@ class Items {
|
|
|
1472
1696
|
abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
|
|
1473
1697
|
});
|
|
1474
1698
|
if (_response.ok) {
|
|
1475
|
-
return
|
|
1476
|
-
|
|
1477
|
-
|
|
1478
|
-
|
|
1479
|
-
|
|
1480
|
-
|
|
1481
|
-
|
|
1699
|
+
return {
|
|
1700
|
+
data: serializers.CollectionItem.parseOrThrow(_response.body, {
|
|
1701
|
+
unrecognizedObjectKeys: "passthrough",
|
|
1702
|
+
allowUnrecognizedUnionMembers: true,
|
|
1703
|
+
allowUnrecognizedEnumValues: true,
|
|
1704
|
+
skipValidation: true,
|
|
1705
|
+
breadcrumbsPrefix: ["response"],
|
|
1706
|
+
}),
|
|
1707
|
+
rawResponse: _response.rawResponse,
|
|
1708
|
+
};
|
|
1482
1709
|
}
|
|
1483
1710
|
if (_response.error.reason === "status-code") {
|
|
1484
1711
|
switch (_response.error.statusCode) {
|
|
1485
1712
|
case 400:
|
|
1486
|
-
throw new Webflow.BadRequestError(_response.error.body);
|
|
1713
|
+
throw new Webflow.BadRequestError(_response.error.body, _response.rawResponse);
|
|
1487
1714
|
case 401:
|
|
1488
1715
|
throw new Webflow.UnauthorizedError(serializers.Error_.parseOrThrow(_response.error.body, {
|
|
1489
1716
|
unrecognizedObjectKeys: "passthrough",
|
|
@@ -1491,7 +1718,7 @@ class Items {
|
|
|
1491
1718
|
allowUnrecognizedEnumValues: true,
|
|
1492
1719
|
skipValidation: true,
|
|
1493
1720
|
breadcrumbsPrefix: ["response"],
|
|
1494
|
-
}));
|
|
1721
|
+
}), _response.rawResponse);
|
|
1495
1722
|
case 404:
|
|
1496
1723
|
throw new Webflow.NotFoundError(serializers.Error_.parseOrThrow(_response.error.body, {
|
|
1497
1724
|
unrecognizedObjectKeys: "passthrough",
|
|
@@ -1499,7 +1726,7 @@ class Items {
|
|
|
1499
1726
|
allowUnrecognizedEnumValues: true,
|
|
1500
1727
|
skipValidation: true,
|
|
1501
1728
|
breadcrumbsPrefix: ["response"],
|
|
1502
|
-
}));
|
|
1729
|
+
}), _response.rawResponse);
|
|
1503
1730
|
case 429:
|
|
1504
1731
|
throw new Webflow.TooManyRequestsError(serializers.Error_.parseOrThrow(_response.error.body, {
|
|
1505
1732
|
unrecognizedObjectKeys: "passthrough",
|
|
@@ -1507,7 +1734,7 @@ class Items {
|
|
|
1507
1734
|
allowUnrecognizedEnumValues: true,
|
|
1508
1735
|
skipValidation: true,
|
|
1509
1736
|
breadcrumbsPrefix: ["response"],
|
|
1510
|
-
}));
|
|
1737
|
+
}), _response.rawResponse);
|
|
1511
1738
|
case 500:
|
|
1512
1739
|
throw new Webflow.InternalServerError(serializers.Error_.parseOrThrow(_response.error.body, {
|
|
1513
1740
|
unrecognizedObjectKeys: "passthrough",
|
|
@@ -1515,11 +1742,12 @@ class Items {
|
|
|
1515
1742
|
allowUnrecognizedEnumValues: true,
|
|
1516
1743
|
skipValidation: true,
|
|
1517
1744
|
breadcrumbsPrefix: ["response"],
|
|
1518
|
-
}));
|
|
1745
|
+
}), _response.rawResponse);
|
|
1519
1746
|
default:
|
|
1520
1747
|
throw new errors.WebflowError({
|
|
1521
1748
|
statusCode: _response.error.statusCode,
|
|
1522
1749
|
body: _response.error.body,
|
|
1750
|
+
rawResponse: _response.rawResponse,
|
|
1523
1751
|
});
|
|
1524
1752
|
}
|
|
1525
1753
|
}
|
|
@@ -1528,12 +1756,14 @@ class Items {
|
|
|
1528
1756
|
throw new errors.WebflowError({
|
|
1529
1757
|
statusCode: _response.error.statusCode,
|
|
1530
1758
|
body: _response.error.rawBody,
|
|
1759
|
+
rawResponse: _response.rawResponse,
|
|
1531
1760
|
});
|
|
1532
1761
|
case "timeout":
|
|
1533
1762
|
throw new errors.WebflowTimeoutError("Timeout exceeded when calling PATCH /collections/{collection_id}/items/{item_id}.");
|
|
1534
1763
|
case "unknown":
|
|
1535
1764
|
throw new errors.WebflowError({
|
|
1536
1765
|
message: _response.error.errorMessage,
|
|
1766
|
+
rawResponse: _response.rawResponse,
|
|
1537
1767
|
});
|
|
1538
1768
|
}
|
|
1539
1769
|
});
|
|
@@ -1560,41 +1790,47 @@ class Items {
|
|
|
1560
1790
|
* @throws {@link Webflow.InternalServerError}
|
|
1561
1791
|
*
|
|
1562
1792
|
* @example
|
|
1563
|
-
* await client.collections.items.getItemLive("580e63fc8c9a982ac9b8b745", "580e64008c9a982ac9b8b754"
|
|
1793
|
+
* await client.collections.items.getItemLive("580e63fc8c9a982ac9b8b745", "580e64008c9a982ac9b8b754", {
|
|
1794
|
+
* cmsLocaleId: "cmsLocaleId"
|
|
1795
|
+
* })
|
|
1564
1796
|
*/
|
|
1565
1797
|
getItemLive(collectionId, itemId, request = {}, requestOptions) {
|
|
1566
|
-
|
|
1567
|
-
|
|
1798
|
+
return core.HttpResponsePromise.fromPromise(this.__getItemLive(collectionId, itemId, request, requestOptions));
|
|
1799
|
+
}
|
|
1800
|
+
__getItemLive(collectionId_1, itemId_1) {
|
|
1801
|
+
return __awaiter(this, arguments, void 0, function* (collectionId, itemId, request = {}, requestOptions) {
|
|
1802
|
+
var _a, _b, _c;
|
|
1568
1803
|
const { cmsLocaleId } = request;
|
|
1569
1804
|
const _queryParams = {};
|
|
1570
1805
|
if (cmsLocaleId != null) {
|
|
1571
1806
|
_queryParams["cmsLocaleId"] = cmsLocaleId;
|
|
1572
1807
|
}
|
|
1573
1808
|
const _response = yield core.fetcher({
|
|
1574
|
-
url: (0, url_join_1.default)((
|
|
1809
|
+
url: (0, url_join_1.default)((_a = (yield core.Supplier.get(this._options.baseUrl))) !== null && _a !== void 0 ? _a : ((_b = (yield core.Supplier.get(this._options.environment))) !== null && _b !== void 0 ? _b : environments.WebflowEnvironment.DataApi)
|
|
1575
1810
|
.dataApi, `collections/${encodeURIComponent(collectionId)}/items/${encodeURIComponent(itemId)}/live`),
|
|
1576
1811
|
method: "GET",
|
|
1577
|
-
headers:
|
|
1578
|
-
contentType: "application/json",
|
|
1812
|
+
headers: (0, headers_js_1.mergeHeaders)((_c = this._options) === null || _c === void 0 ? void 0 : _c.headers, (0, headers_js_1.mergeOnlyDefinedHeaders)({ Authorization: yield this._getAuthorizationHeader() }), requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers),
|
|
1579
1813
|
queryParameters: _queryParams,
|
|
1580
|
-
requestType: "json",
|
|
1581
1814
|
timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
|
|
1582
1815
|
maxRetries: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries,
|
|
1583
1816
|
abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
|
|
1584
1817
|
});
|
|
1585
1818
|
if (_response.ok) {
|
|
1586
|
-
return
|
|
1587
|
-
|
|
1588
|
-
|
|
1589
|
-
|
|
1590
|
-
|
|
1591
|
-
|
|
1592
|
-
|
|
1819
|
+
return {
|
|
1820
|
+
data: serializers.CollectionItem.parseOrThrow(_response.body, {
|
|
1821
|
+
unrecognizedObjectKeys: "passthrough",
|
|
1822
|
+
allowUnrecognizedUnionMembers: true,
|
|
1823
|
+
allowUnrecognizedEnumValues: true,
|
|
1824
|
+
skipValidation: true,
|
|
1825
|
+
breadcrumbsPrefix: ["response"],
|
|
1826
|
+
}),
|
|
1827
|
+
rawResponse: _response.rawResponse,
|
|
1828
|
+
};
|
|
1593
1829
|
}
|
|
1594
1830
|
if (_response.error.reason === "status-code") {
|
|
1595
1831
|
switch (_response.error.statusCode) {
|
|
1596
1832
|
case 400:
|
|
1597
|
-
throw new Webflow.BadRequestError(_response.error.body);
|
|
1833
|
+
throw new Webflow.BadRequestError(_response.error.body, _response.rawResponse);
|
|
1598
1834
|
case 401:
|
|
1599
1835
|
throw new Webflow.UnauthorizedError(serializers.Error_.parseOrThrow(_response.error.body, {
|
|
1600
1836
|
unrecognizedObjectKeys: "passthrough",
|
|
@@ -1602,7 +1838,7 @@ class Items {
|
|
|
1602
1838
|
allowUnrecognizedEnumValues: true,
|
|
1603
1839
|
skipValidation: true,
|
|
1604
1840
|
breadcrumbsPrefix: ["response"],
|
|
1605
|
-
}));
|
|
1841
|
+
}), _response.rawResponse);
|
|
1606
1842
|
case 404:
|
|
1607
1843
|
throw new Webflow.NotFoundError(serializers.Error_.parseOrThrow(_response.error.body, {
|
|
1608
1844
|
unrecognizedObjectKeys: "passthrough",
|
|
@@ -1610,7 +1846,7 @@ class Items {
|
|
|
1610
1846
|
allowUnrecognizedEnumValues: true,
|
|
1611
1847
|
skipValidation: true,
|
|
1612
1848
|
breadcrumbsPrefix: ["response"],
|
|
1613
|
-
}));
|
|
1849
|
+
}), _response.rawResponse);
|
|
1614
1850
|
case 429:
|
|
1615
1851
|
throw new Webflow.TooManyRequestsError(serializers.Error_.parseOrThrow(_response.error.body, {
|
|
1616
1852
|
unrecognizedObjectKeys: "passthrough",
|
|
@@ -1618,7 +1854,7 @@ class Items {
|
|
|
1618
1854
|
allowUnrecognizedEnumValues: true,
|
|
1619
1855
|
skipValidation: true,
|
|
1620
1856
|
breadcrumbsPrefix: ["response"],
|
|
1621
|
-
}));
|
|
1857
|
+
}), _response.rawResponse);
|
|
1622
1858
|
case 500:
|
|
1623
1859
|
throw new Webflow.InternalServerError(serializers.Error_.parseOrThrow(_response.error.body, {
|
|
1624
1860
|
unrecognizedObjectKeys: "passthrough",
|
|
@@ -1626,11 +1862,12 @@ class Items {
|
|
|
1626
1862
|
allowUnrecognizedEnumValues: true,
|
|
1627
1863
|
skipValidation: true,
|
|
1628
1864
|
breadcrumbsPrefix: ["response"],
|
|
1629
|
-
}));
|
|
1865
|
+
}), _response.rawResponse);
|
|
1630
1866
|
default:
|
|
1631
1867
|
throw new errors.WebflowError({
|
|
1632
1868
|
statusCode: _response.error.statusCode,
|
|
1633
1869
|
body: _response.error.body,
|
|
1870
|
+
rawResponse: _response.rawResponse,
|
|
1634
1871
|
});
|
|
1635
1872
|
}
|
|
1636
1873
|
}
|
|
@@ -1639,20 +1876,22 @@ class Items {
|
|
|
1639
1876
|
throw new errors.WebflowError({
|
|
1640
1877
|
statusCode: _response.error.statusCode,
|
|
1641
1878
|
body: _response.error.rawBody,
|
|
1879
|
+
rawResponse: _response.rawResponse,
|
|
1642
1880
|
});
|
|
1643
1881
|
case "timeout":
|
|
1644
1882
|
throw new errors.WebflowTimeoutError("Timeout exceeded when calling GET /collections/{collection_id}/items/{item_id}/live.");
|
|
1645
1883
|
case "unknown":
|
|
1646
1884
|
throw new errors.WebflowError({
|
|
1647
1885
|
message: _response.error.errorMessage,
|
|
1886
|
+
rawResponse: _response.rawResponse,
|
|
1648
1887
|
});
|
|
1649
1888
|
}
|
|
1650
1889
|
});
|
|
1651
1890
|
}
|
|
1652
1891
|
/**
|
|
1653
|
-
*
|
|
1892
|
+
* Unpublish a live item from the site and set the `isDraft` property to `true`.
|
|
1654
1893
|
*
|
|
1655
|
-
*
|
|
1894
|
+
* For bulk unpublishing, please use [this endpoint.](/data/v2.0.0/reference/cms/collection-items/live-items/delete-items-live)
|
|
1656
1895
|
*
|
|
1657
1896
|
* Required scope | `CMS:write`
|
|
1658
1897
|
*
|
|
@@ -1668,34 +1907,38 @@ class Items {
|
|
|
1668
1907
|
* @throws {@link Webflow.InternalServerError}
|
|
1669
1908
|
*
|
|
1670
1909
|
* @example
|
|
1671
|
-
* await client.collections.items.deleteItemLive("580e63fc8c9a982ac9b8b745", "580e64008c9a982ac9b8b754"
|
|
1910
|
+
* await client.collections.items.deleteItemLive("580e63fc8c9a982ac9b8b745", "580e64008c9a982ac9b8b754", {
|
|
1911
|
+
* cmsLocaleId: "cmsLocaleId"
|
|
1912
|
+
* })
|
|
1672
1913
|
*/
|
|
1673
1914
|
deleteItemLive(collectionId, itemId, request = {}, requestOptions) {
|
|
1674
|
-
|
|
1675
|
-
|
|
1915
|
+
return core.HttpResponsePromise.fromPromise(this.__deleteItemLive(collectionId, itemId, request, requestOptions));
|
|
1916
|
+
}
|
|
1917
|
+
__deleteItemLive(collectionId_1, itemId_1) {
|
|
1918
|
+
return __awaiter(this, arguments, void 0, function* (collectionId, itemId, request = {}, requestOptions) {
|
|
1919
|
+
var _a, _b, _c;
|
|
1676
1920
|
const { cmsLocaleId } = request;
|
|
1677
1921
|
const _queryParams = {};
|
|
1678
1922
|
if (cmsLocaleId != null) {
|
|
1679
1923
|
_queryParams["cmsLocaleId"] = cmsLocaleId;
|
|
1680
1924
|
}
|
|
1681
1925
|
const _response = yield core.fetcher({
|
|
1682
|
-
url: (0, url_join_1.default)((
|
|
1926
|
+
url: (0, url_join_1.default)((_a = (yield core.Supplier.get(this._options.baseUrl))) !== null && _a !== void 0 ? _a : ((_b = (yield core.Supplier.get(this._options.environment))) !== null && _b !== void 0 ? _b : environments.WebflowEnvironment.DataApi)
|
|
1927
|
+
.base, `collections/${encodeURIComponent(collectionId)}/items/${encodeURIComponent(itemId)}/live`),
|
|
1683
1928
|
method: "DELETE",
|
|
1684
|
-
headers:
|
|
1685
|
-
contentType: "application/json",
|
|
1929
|
+
headers: (0, headers_js_1.mergeHeaders)((_c = this._options) === null || _c === void 0 ? void 0 : _c.headers, (0, headers_js_1.mergeOnlyDefinedHeaders)({ Authorization: yield this._getAuthorizationHeader() }), requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers),
|
|
1686
1930
|
queryParameters: _queryParams,
|
|
1687
|
-
requestType: "json",
|
|
1688
1931
|
timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
|
|
1689
1932
|
maxRetries: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries,
|
|
1690
1933
|
abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
|
|
1691
1934
|
});
|
|
1692
1935
|
if (_response.ok) {
|
|
1693
|
-
return;
|
|
1936
|
+
return { data: undefined, rawResponse: _response.rawResponse };
|
|
1694
1937
|
}
|
|
1695
1938
|
if (_response.error.reason === "status-code") {
|
|
1696
1939
|
switch (_response.error.statusCode) {
|
|
1697
1940
|
case 400:
|
|
1698
|
-
throw new Webflow.BadRequestError(_response.error.body);
|
|
1941
|
+
throw new Webflow.BadRequestError(_response.error.body, _response.rawResponse);
|
|
1699
1942
|
case 401:
|
|
1700
1943
|
throw new Webflow.UnauthorizedError(serializers.Error_.parseOrThrow(_response.error.body, {
|
|
1701
1944
|
unrecognizedObjectKeys: "passthrough",
|
|
@@ -1703,7 +1946,7 @@ class Items {
|
|
|
1703
1946
|
allowUnrecognizedEnumValues: true,
|
|
1704
1947
|
skipValidation: true,
|
|
1705
1948
|
breadcrumbsPrefix: ["response"],
|
|
1706
|
-
}));
|
|
1949
|
+
}), _response.rawResponse);
|
|
1707
1950
|
case 404:
|
|
1708
1951
|
throw new Webflow.NotFoundError(serializers.Error_.parseOrThrow(_response.error.body, {
|
|
1709
1952
|
unrecognizedObjectKeys: "passthrough",
|
|
@@ -1711,7 +1954,7 @@ class Items {
|
|
|
1711
1954
|
allowUnrecognizedEnumValues: true,
|
|
1712
1955
|
skipValidation: true,
|
|
1713
1956
|
breadcrumbsPrefix: ["response"],
|
|
1714
|
-
}));
|
|
1957
|
+
}), _response.rawResponse);
|
|
1715
1958
|
case 429:
|
|
1716
1959
|
throw new Webflow.TooManyRequestsError(serializers.Error_.parseOrThrow(_response.error.body, {
|
|
1717
1960
|
unrecognizedObjectKeys: "passthrough",
|
|
@@ -1719,7 +1962,7 @@ class Items {
|
|
|
1719
1962
|
allowUnrecognizedEnumValues: true,
|
|
1720
1963
|
skipValidation: true,
|
|
1721
1964
|
breadcrumbsPrefix: ["response"],
|
|
1722
|
-
}));
|
|
1965
|
+
}), _response.rawResponse);
|
|
1723
1966
|
case 500:
|
|
1724
1967
|
throw new Webflow.InternalServerError(serializers.Error_.parseOrThrow(_response.error.body, {
|
|
1725
1968
|
unrecognizedObjectKeys: "passthrough",
|
|
@@ -1727,11 +1970,12 @@ class Items {
|
|
|
1727
1970
|
allowUnrecognizedEnumValues: true,
|
|
1728
1971
|
skipValidation: true,
|
|
1729
1972
|
breadcrumbsPrefix: ["response"],
|
|
1730
|
-
}));
|
|
1973
|
+
}), _response.rawResponse);
|
|
1731
1974
|
default:
|
|
1732
1975
|
throw new errors.WebflowError({
|
|
1733
1976
|
statusCode: _response.error.statusCode,
|
|
1734
1977
|
body: _response.error.body,
|
|
1978
|
+
rawResponse: _response.rawResponse,
|
|
1735
1979
|
});
|
|
1736
1980
|
}
|
|
1737
1981
|
}
|
|
@@ -1740,12 +1984,14 @@ class Items {
|
|
|
1740
1984
|
throw new errors.WebflowError({
|
|
1741
1985
|
statusCode: _response.error.statusCode,
|
|
1742
1986
|
body: _response.error.rawBody,
|
|
1987
|
+
rawResponse: _response.rawResponse,
|
|
1743
1988
|
});
|
|
1744
1989
|
case "timeout":
|
|
1745
1990
|
throw new errors.WebflowTimeoutError("Timeout exceeded when calling DELETE /collections/{collection_id}/items/{item_id}/live.");
|
|
1746
1991
|
case "unknown":
|
|
1747
1992
|
throw new errors.WebflowError({
|
|
1748
1993
|
message: _response.error.errorMessage,
|
|
1994
|
+
rawResponse: _response.rawResponse,
|
|
1749
1995
|
});
|
|
1750
1996
|
}
|
|
1751
1997
|
});
|
|
@@ -1757,7 +2003,7 @@ class Items {
|
|
|
1757
2003
|
*
|
|
1758
2004
|
* @param {string} collectionId - Unique identifier for a Collection
|
|
1759
2005
|
* @param {string} itemId - Unique identifier for an Item
|
|
1760
|
-
* @param {Webflow.
|
|
2006
|
+
* @param {Webflow.collections.ItemsUpdateItemLiveRequest} request
|
|
1761
2007
|
* @param {Items.RequestOptions} requestOptions - Request-specific configuration.
|
|
1762
2008
|
*
|
|
1763
2009
|
* @throws {@link Webflow.BadRequestError}
|
|
@@ -1769,24 +2015,37 @@ class Items {
|
|
|
1769
2015
|
*
|
|
1770
2016
|
* @example
|
|
1771
2017
|
* await client.collections.items.updateItemLive("580e63fc8c9a982ac9b8b745", "580e64008c9a982ac9b8b754", {
|
|
1772
|
-
*
|
|
1773
|
-
*
|
|
1774
|
-
*
|
|
1775
|
-
*
|
|
1776
|
-
*
|
|
2018
|
+
* skipInvalidFiles: true,
|
|
2019
|
+
* body: {
|
|
2020
|
+
* isArchived: false,
|
|
2021
|
+
* isDraft: false,
|
|
2022
|
+
* fieldData: {
|
|
2023
|
+
* name: "The Hitchhiker's Guide to the Galaxy",
|
|
2024
|
+
* slug: "hitchhikers-guide-to-the-galaxy"
|
|
2025
|
+
* }
|
|
1777
2026
|
* }
|
|
1778
2027
|
* })
|
|
1779
2028
|
*/
|
|
1780
2029
|
updateItemLive(collectionId, itemId, request, requestOptions) {
|
|
1781
|
-
|
|
2030
|
+
return core.HttpResponsePromise.fromPromise(this.__updateItemLive(collectionId, itemId, request, requestOptions));
|
|
2031
|
+
}
|
|
2032
|
+
__updateItemLive(collectionId, itemId, request, requestOptions) {
|
|
1782
2033
|
return __awaiter(this, void 0, void 0, function* () {
|
|
2034
|
+
var _a, _b, _c;
|
|
2035
|
+
const { skipInvalidFiles, body: _body } = request;
|
|
2036
|
+
const _queryParams = {};
|
|
2037
|
+
if (skipInvalidFiles != null) {
|
|
2038
|
+
_queryParams["skipInvalidFiles"] = skipInvalidFiles.toString();
|
|
2039
|
+
}
|
|
1783
2040
|
const _response = yield core.fetcher({
|
|
1784
|
-
url: (0, url_join_1.default)((
|
|
2041
|
+
url: (0, url_join_1.default)((_a = (yield core.Supplier.get(this._options.baseUrl))) !== null && _a !== void 0 ? _a : ((_b = (yield core.Supplier.get(this._options.environment))) !== null && _b !== void 0 ? _b : environments.WebflowEnvironment.DataApi)
|
|
2042
|
+
.base, `collections/${encodeURIComponent(collectionId)}/items/${encodeURIComponent(itemId)}/live`),
|
|
1785
2043
|
method: "PATCH",
|
|
1786
|
-
headers:
|
|
2044
|
+
headers: (0, headers_js_1.mergeHeaders)((_c = this._options) === null || _c === void 0 ? void 0 : _c.headers, (0, headers_js_1.mergeOnlyDefinedHeaders)({ Authorization: yield this._getAuthorizationHeader() }), requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers),
|
|
1787
2045
|
contentType: "application/json",
|
|
2046
|
+
queryParameters: _queryParams,
|
|
1788
2047
|
requestType: "json",
|
|
1789
|
-
body: serializers.CollectionItemPatchSingle.jsonOrThrow(
|
|
2048
|
+
body: serializers.CollectionItemPatchSingle.jsonOrThrow(_body, {
|
|
1790
2049
|
unrecognizedObjectKeys: "passthrough",
|
|
1791
2050
|
allowUnrecognizedUnionMembers: true,
|
|
1792
2051
|
allowUnrecognizedEnumValues: true,
|
|
@@ -1796,18 +2055,21 @@ class Items {
|
|
|
1796
2055
|
abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
|
|
1797
2056
|
});
|
|
1798
2057
|
if (_response.ok) {
|
|
1799
|
-
return
|
|
1800
|
-
|
|
1801
|
-
|
|
1802
|
-
|
|
1803
|
-
|
|
1804
|
-
|
|
1805
|
-
|
|
2058
|
+
return {
|
|
2059
|
+
data: serializers.CollectionItem.parseOrThrow(_response.body, {
|
|
2060
|
+
unrecognizedObjectKeys: "passthrough",
|
|
2061
|
+
allowUnrecognizedUnionMembers: true,
|
|
2062
|
+
allowUnrecognizedEnumValues: true,
|
|
2063
|
+
skipValidation: true,
|
|
2064
|
+
breadcrumbsPrefix: ["response"],
|
|
2065
|
+
}),
|
|
2066
|
+
rawResponse: _response.rawResponse,
|
|
2067
|
+
};
|
|
1806
2068
|
}
|
|
1807
2069
|
if (_response.error.reason === "status-code") {
|
|
1808
2070
|
switch (_response.error.statusCode) {
|
|
1809
2071
|
case 400:
|
|
1810
|
-
throw new Webflow.BadRequestError(_response.error.body);
|
|
2072
|
+
throw new Webflow.BadRequestError(_response.error.body, _response.rawResponse);
|
|
1811
2073
|
case 401:
|
|
1812
2074
|
throw new Webflow.UnauthorizedError(serializers.Error_.parseOrThrow(_response.error.body, {
|
|
1813
2075
|
unrecognizedObjectKeys: "passthrough",
|
|
@@ -1815,7 +2077,7 @@ class Items {
|
|
|
1815
2077
|
allowUnrecognizedEnumValues: true,
|
|
1816
2078
|
skipValidation: true,
|
|
1817
2079
|
breadcrumbsPrefix: ["response"],
|
|
1818
|
-
}));
|
|
2080
|
+
}), _response.rawResponse);
|
|
1819
2081
|
case 404:
|
|
1820
2082
|
throw new Webflow.NotFoundError(serializers.Error_.parseOrThrow(_response.error.body, {
|
|
1821
2083
|
unrecognizedObjectKeys: "passthrough",
|
|
@@ -1823,9 +2085,9 @@ class Items {
|
|
|
1823
2085
|
allowUnrecognizedEnumValues: true,
|
|
1824
2086
|
skipValidation: true,
|
|
1825
2087
|
breadcrumbsPrefix: ["response"],
|
|
1826
|
-
}));
|
|
2088
|
+
}), _response.rawResponse);
|
|
1827
2089
|
case 409:
|
|
1828
|
-
throw new Webflow.ConflictError(_response.error.body);
|
|
2090
|
+
throw new Webflow.ConflictError(_response.error.body, _response.rawResponse);
|
|
1829
2091
|
case 429:
|
|
1830
2092
|
throw new Webflow.TooManyRequestsError(serializers.Error_.parseOrThrow(_response.error.body, {
|
|
1831
2093
|
unrecognizedObjectKeys: "passthrough",
|
|
@@ -1833,7 +2095,7 @@ class Items {
|
|
|
1833
2095
|
allowUnrecognizedEnumValues: true,
|
|
1834
2096
|
skipValidation: true,
|
|
1835
2097
|
breadcrumbsPrefix: ["response"],
|
|
1836
|
-
}));
|
|
2098
|
+
}), _response.rawResponse);
|
|
1837
2099
|
case 500:
|
|
1838
2100
|
throw new Webflow.InternalServerError(serializers.Error_.parseOrThrow(_response.error.body, {
|
|
1839
2101
|
unrecognizedObjectKeys: "passthrough",
|
|
@@ -1841,11 +2103,12 @@ class Items {
|
|
|
1841
2103
|
allowUnrecognizedEnumValues: true,
|
|
1842
2104
|
skipValidation: true,
|
|
1843
2105
|
breadcrumbsPrefix: ["response"],
|
|
1844
|
-
}));
|
|
2106
|
+
}), _response.rawResponse);
|
|
1845
2107
|
default:
|
|
1846
2108
|
throw new errors.WebflowError({
|
|
1847
2109
|
statusCode: _response.error.statusCode,
|
|
1848
2110
|
body: _response.error.body,
|
|
2111
|
+
rawResponse: _response.rawResponse,
|
|
1849
2112
|
});
|
|
1850
2113
|
}
|
|
1851
2114
|
}
|
|
@@ -1854,12 +2117,14 @@ class Items {
|
|
|
1854
2117
|
throw new errors.WebflowError({
|
|
1855
2118
|
statusCode: _response.error.statusCode,
|
|
1856
2119
|
body: _response.error.rawBody,
|
|
2120
|
+
rawResponse: _response.rawResponse,
|
|
1857
2121
|
});
|
|
1858
2122
|
case "timeout":
|
|
1859
2123
|
throw new errors.WebflowTimeoutError("Timeout exceeded when calling PATCH /collections/{collection_id}/items/{item_id}/live.");
|
|
1860
2124
|
case "unknown":
|
|
1861
2125
|
throw new errors.WebflowError({
|
|
1862
2126
|
message: _response.error.errorMessage,
|
|
2127
|
+
rawResponse: _response.rawResponse,
|
|
1863
2128
|
});
|
|
1864
2129
|
}
|
|
1865
2130
|
});
|
|
@@ -1882,16 +2147,42 @@ class Items {
|
|
|
1882
2147
|
*
|
|
1883
2148
|
* @example
|
|
1884
2149
|
* await client.collections.items.publishItem("580e63fc8c9a982ac9b8b745", {
|
|
1885
|
-
* itemIds: ["
|
|
2150
|
+
* itemIds: ["643fd856d66b6528195ee2ca", "643fd856d66b6528195ee2cb", "643fd856d66b6528195ee2cc"]
|
|
2151
|
+
* })
|
|
2152
|
+
*
|
|
2153
|
+
* @example
|
|
2154
|
+
* await client.collections.items.publishItem("580e63fc8c9a982ac9b8b745", {
|
|
2155
|
+
* items: [{
|
|
2156
|
+
* id: "643fd856d66b6528195ee2ca",
|
|
2157
|
+
* cmsLocaleIds: ["653ad57de882f528b32e810e"]
|
|
2158
|
+
* }, {
|
|
2159
|
+
* id: "643fd856d66b6528195ee2cb",
|
|
2160
|
+
* cmsLocaleIds: ["653ad57de882f528b32e810e"]
|
|
2161
|
+
* }, {
|
|
2162
|
+
* id: "643fd856d66b6528195ee2cc",
|
|
2163
|
+
* cmsLocaleIds: ["653ad57de882f528b32e810e"]
|
|
2164
|
+
* }]
|
|
2165
|
+
* })
|
|
2166
|
+
*
|
|
2167
|
+
* @example
|
|
2168
|
+
* await client.collections.items.publishItem("580e63fc8c9a982ac9b8b745", {
|
|
2169
|
+
* items: [{
|
|
2170
|
+
* id: "643fd856d66b6528195ee2ca",
|
|
2171
|
+
* cmsLocaleIds: ["653ad57de882f528b32e810e", "6514390aea353fc691d69827", "65143930ea353fc691d69cd8"]
|
|
2172
|
+
* }]
|
|
1886
2173
|
* })
|
|
1887
2174
|
*/
|
|
1888
2175
|
publishItem(collectionId, request, requestOptions) {
|
|
1889
|
-
|
|
2176
|
+
return core.HttpResponsePromise.fromPromise(this.__publishItem(collectionId, request, requestOptions));
|
|
2177
|
+
}
|
|
2178
|
+
__publishItem(collectionId, request, requestOptions) {
|
|
1890
2179
|
return __awaiter(this, void 0, void 0, function* () {
|
|
2180
|
+
var _a, _b, _c;
|
|
1891
2181
|
const _response = yield core.fetcher({
|
|
1892
|
-
url: (0, url_join_1.default)((
|
|
2182
|
+
url: (0, url_join_1.default)((_a = (yield core.Supplier.get(this._options.baseUrl))) !== null && _a !== void 0 ? _a : ((_b = (yield core.Supplier.get(this._options.environment))) !== null && _b !== void 0 ? _b : environments.WebflowEnvironment.DataApi)
|
|
2183
|
+
.base, `collections/${encodeURIComponent(collectionId)}/items/publish`),
|
|
1893
2184
|
method: "POST",
|
|
1894
|
-
headers:
|
|
2185
|
+
headers: (0, headers_js_1.mergeHeaders)((_c = this._options) === null || _c === void 0 ? void 0 : _c.headers, (0, headers_js_1.mergeOnlyDefinedHeaders)({ Authorization: yield this._getAuthorizationHeader() }), requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers),
|
|
1895
2186
|
contentType: "application/json",
|
|
1896
2187
|
requestType: "json",
|
|
1897
2188
|
body: serializers.collections.ItemsPublishItemRequest.jsonOrThrow(request, {
|
|
@@ -1904,18 +2195,21 @@ class Items {
|
|
|
1904
2195
|
abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
|
|
1905
2196
|
});
|
|
1906
2197
|
if (_response.ok) {
|
|
1907
|
-
return
|
|
1908
|
-
|
|
1909
|
-
|
|
1910
|
-
|
|
1911
|
-
|
|
1912
|
-
|
|
1913
|
-
|
|
2198
|
+
return {
|
|
2199
|
+
data: serializers.collections.ItemsPublishItemResponse.parseOrThrow(_response.body, {
|
|
2200
|
+
unrecognizedObjectKeys: "passthrough",
|
|
2201
|
+
allowUnrecognizedUnionMembers: true,
|
|
2202
|
+
allowUnrecognizedEnumValues: true,
|
|
2203
|
+
skipValidation: true,
|
|
2204
|
+
breadcrumbsPrefix: ["response"],
|
|
2205
|
+
}),
|
|
2206
|
+
rawResponse: _response.rawResponse,
|
|
2207
|
+
};
|
|
1914
2208
|
}
|
|
1915
2209
|
if (_response.error.reason === "status-code") {
|
|
1916
2210
|
switch (_response.error.statusCode) {
|
|
1917
2211
|
case 400:
|
|
1918
|
-
throw new Webflow.BadRequestError(_response.error.body);
|
|
2212
|
+
throw new Webflow.BadRequestError(_response.error.body, _response.rawResponse);
|
|
1919
2213
|
case 401:
|
|
1920
2214
|
throw new Webflow.UnauthorizedError(serializers.Error_.parseOrThrow(_response.error.body, {
|
|
1921
2215
|
unrecognizedObjectKeys: "passthrough",
|
|
@@ -1923,7 +2217,7 @@ class Items {
|
|
|
1923
2217
|
allowUnrecognizedEnumValues: true,
|
|
1924
2218
|
skipValidation: true,
|
|
1925
2219
|
breadcrumbsPrefix: ["response"],
|
|
1926
|
-
}));
|
|
2220
|
+
}), _response.rawResponse);
|
|
1927
2221
|
case 404:
|
|
1928
2222
|
throw new Webflow.NotFoundError(serializers.Error_.parseOrThrow(_response.error.body, {
|
|
1929
2223
|
unrecognizedObjectKeys: "passthrough",
|
|
@@ -1931,9 +2225,9 @@ class Items {
|
|
|
1931
2225
|
allowUnrecognizedEnumValues: true,
|
|
1932
2226
|
skipValidation: true,
|
|
1933
2227
|
breadcrumbsPrefix: ["response"],
|
|
1934
|
-
}));
|
|
2228
|
+
}), _response.rawResponse);
|
|
1935
2229
|
case 409:
|
|
1936
|
-
throw new Webflow.ConflictError(_response.error.body);
|
|
2230
|
+
throw new Webflow.ConflictError(_response.error.body, _response.rawResponse);
|
|
1937
2231
|
case 429:
|
|
1938
2232
|
throw new Webflow.TooManyRequestsError(serializers.Error_.parseOrThrow(_response.error.body, {
|
|
1939
2233
|
unrecognizedObjectKeys: "passthrough",
|
|
@@ -1941,7 +2235,7 @@ class Items {
|
|
|
1941
2235
|
allowUnrecognizedEnumValues: true,
|
|
1942
2236
|
skipValidation: true,
|
|
1943
2237
|
breadcrumbsPrefix: ["response"],
|
|
1944
|
-
}));
|
|
2238
|
+
}), _response.rawResponse);
|
|
1945
2239
|
case 500:
|
|
1946
2240
|
throw new Webflow.InternalServerError(serializers.Error_.parseOrThrow(_response.error.body, {
|
|
1947
2241
|
unrecognizedObjectKeys: "passthrough",
|
|
@@ -1949,11 +2243,12 @@ class Items {
|
|
|
1949
2243
|
allowUnrecognizedEnumValues: true,
|
|
1950
2244
|
skipValidation: true,
|
|
1951
2245
|
breadcrumbsPrefix: ["response"],
|
|
1952
|
-
}));
|
|
2246
|
+
}), _response.rawResponse);
|
|
1953
2247
|
default:
|
|
1954
2248
|
throw new errors.WebflowError({
|
|
1955
2249
|
statusCode: _response.error.statusCode,
|
|
1956
2250
|
body: _response.error.body,
|
|
2251
|
+
rawResponse: _response.rawResponse,
|
|
1957
2252
|
});
|
|
1958
2253
|
}
|
|
1959
2254
|
}
|
|
@@ -1962,19 +2257,25 @@ class Items {
|
|
|
1962
2257
|
throw new errors.WebflowError({
|
|
1963
2258
|
statusCode: _response.error.statusCode,
|
|
1964
2259
|
body: _response.error.rawBody,
|
|
2260
|
+
rawResponse: _response.rawResponse,
|
|
1965
2261
|
});
|
|
1966
2262
|
case "timeout":
|
|
1967
2263
|
throw new errors.WebflowTimeoutError("Timeout exceeded when calling POST /collections/{collection_id}/items/publish.");
|
|
1968
2264
|
case "unknown":
|
|
1969
2265
|
throw new errors.WebflowError({
|
|
1970
2266
|
message: _response.error.errorMessage,
|
|
2267
|
+
rawResponse: _response.rawResponse,
|
|
1971
2268
|
});
|
|
1972
2269
|
}
|
|
1973
2270
|
});
|
|
1974
2271
|
}
|
|
1975
2272
|
_getAuthorizationHeader() {
|
|
1976
2273
|
return __awaiter(this, void 0, void 0, function* () {
|
|
1977
|
-
|
|
2274
|
+
const bearer = yield core.Supplier.get(this._options.accessToken);
|
|
2275
|
+
if (bearer != null) {
|
|
2276
|
+
return `Bearer ${bearer}`;
|
|
2277
|
+
}
|
|
2278
|
+
return undefined;
|
|
1978
2279
|
});
|
|
1979
2280
|
}
|
|
1980
2281
|
}
|