webflow-api 2.0.0-beta → 2.1.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.
Files changed (614) hide show
  1. package/README.md +33 -2
  2. package/api/resources/accessGroups/client/Client.d.ts +1 -3
  3. package/api/resources/accessGroups/client/Client.js +5 -5
  4. package/api/resources/accessGroups/client/requests/AccessGroupsListRequest.d.ts +1 -3
  5. package/api/resources/assets/client/Client.d.ts +21 -7
  6. package/api/resources/assets/client/Client.js +110 -21
  7. package/api/resources/assets/client/requests/AssetsUpdateRequest.d.ts +13 -0
  8. package/api/resources/assets/client/requests/index.d.ts +1 -0
  9. package/api/resources/collections/client/Client.d.ts +11 -4
  10. package/api/resources/collections/client/Client.js +31 -14
  11. package/api/resources/collections/client/requests/CollectionsCreateRequest.d.ts +8 -0
  12. package/api/resources/collections/resources/fields/client/Client.d.ts +16 -1
  13. package/api/resources/collections/resources/fields/client/Client.js +24 -5
  14. package/api/resources/collections/resources/fields/client/requests/FieldCreate.d.ts +23 -0
  15. package/api/resources/collections/resources/fields/client/requests/FieldUpdate.d.ts +8 -0
  16. package/api/resources/collections/resources/fields/client/requests/index.d.ts +1 -0
  17. package/api/resources/collections/resources/fields/index.d.ts +1 -0
  18. package/api/resources/collections/resources/fields/index.js +1 -0
  19. package/api/resources/collections/resources/fields/types/FieldCreateType.d.ts +22 -0
  20. package/api/resources/collections/resources/fields/types/FieldCreateType.js +21 -0
  21. package/api/resources/collections/resources/fields/types/index.d.ts +1 -0
  22. package/api/resources/collections/resources/fields/types/index.js +17 -0
  23. package/api/resources/collections/resources/index.d.ts +2 -1
  24. package/api/resources/collections/resources/index.js +3 -2
  25. package/api/resources/collections/resources/items/client/Client.d.ts +82 -16
  26. package/api/resources/collections/resources/items/client/Client.js +302 -29
  27. package/api/resources/collections/resources/items/client/requests/ItemsDeleteItemRequest.d.ts +13 -0
  28. package/api/resources/collections/resources/items/client/requests/ItemsDeleteItemRequest.js +5 -0
  29. package/api/resources/collections/resources/items/client/requests/ItemsGetItemRequest.d.ts +13 -0
  30. package/api/resources/collections/resources/items/client/requests/ItemsGetItemRequest.js +5 -0
  31. package/api/resources/collections/resources/items/client/requests/ItemsListItemsRequest.d.ts +4 -0
  32. package/api/resources/collections/resources/items/client/requests/ItemsPublishItemRequest.d.ts +1 -1
  33. package/api/resources/collections/resources/items/client/requests/index.d.ts +2 -0
  34. package/api/resources/ecommerce/client/Client.d.ts +1 -1
  35. package/api/resources/ecommerce/client/Client.js +5 -3
  36. package/api/resources/forms/client/Client.d.ts +6 -6
  37. package/api/resources/forms/client/Client.js +35 -16
  38. package/api/resources/forms/client/requests/FormsListRequest.d.ts +17 -0
  39. package/api/resources/forms/client/requests/FormsListRequest.js +5 -0
  40. package/api/resources/forms/client/requests/index.d.ts +1 -0
  41. package/api/resources/index.d.ts +3 -1
  42. package/api/resources/index.js +4 -2
  43. package/api/resources/inventory/client/Client.d.ts +2 -2
  44. package/api/resources/inventory/client/Client.js +10 -6
  45. package/api/resources/orders/client/Client.d.ts +6 -10
  46. package/api/resources/orders/client/Client.js +30 -22
  47. package/api/resources/orders/client/requests/OrdersListRequest.d.ts +1 -3
  48. package/api/resources/orders/client/requests/OrdersRefundRequest.d.ts +1 -3
  49. package/api/resources/pages/client/Client.d.ts +73 -4
  50. package/api/resources/pages/client/Client.js +312 -8
  51. package/api/resources/pages/client/index.d.ts +1 -1
  52. package/api/resources/pages/client/index.js +15 -0
  53. package/api/resources/pages/client/requests/DomWrite.d.ts +21 -0
  54. package/api/resources/pages/client/requests/DomWrite.js +5 -0
  55. package/api/resources/pages/client/requests/PagesGetContentRequest.d.ts +13 -0
  56. package/api/resources/pages/client/requests/PagesGetContentRequest.js +5 -0
  57. package/api/resources/pages/client/requests/PagesGetMetadataRequest.d.ts +13 -0
  58. package/api/resources/pages/client/requests/PagesGetMetadataRequest.js +5 -0
  59. package/api/resources/pages/client/requests/PagesListRequest.d.ts +21 -0
  60. package/api/resources/pages/client/requests/PagesListRequest.js +5 -0
  61. package/api/resources/pages/client/requests/UpdatePageSettingsRequest.d.ts +40 -0
  62. package/api/resources/pages/client/requests/UpdatePageSettingsRequest.js +5 -0
  63. package/api/resources/pages/client/requests/index.d.ts +5 -0
  64. package/api/resources/pages/client/requests/index.js +2 -0
  65. package/api/resources/pages/index.d.ts +1 -0
  66. package/api/resources/pages/index.js +1 -0
  67. package/api/resources/pages/resources/scripts/client/Client.d.ts +20 -3
  68. package/api/resources/pages/resources/scripts/client/Client.js +32 -9
  69. package/api/resources/pages/types/DomWriteNodesItem.d.ts +9 -0
  70. package/api/resources/pages/types/DomWriteNodesItem.js +5 -0
  71. package/api/resources/pages/types/index.d.ts +1 -0
  72. package/api/resources/pages/types/index.js +17 -0
  73. package/api/resources/products/client/Client.d.ts +54 -74
  74. package/api/resources/products/client/Client.js +79 -87
  75. package/api/resources/products/client/requests/ProductSkuCreate.d.ts +15 -0
  76. package/api/resources/products/client/requests/ProductSkuCreate.js +5 -0
  77. package/api/resources/products/client/requests/ProductsCreateSkuRequest.d.ts +7 -7
  78. package/api/resources/products/client/requests/ProductsUpdateRequest.d.ts +29 -8
  79. package/api/resources/products/client/requests/ProductsUpdateSkuRequest.d.ts +7 -7
  80. package/api/resources/products/client/requests/index.d.ts +1 -1
  81. package/api/resources/products/types/ProductSkuCreateProduct.d.ts +22 -0
  82. package/api/resources/products/types/ProductSkuCreateProduct.js +5 -0
  83. package/api/resources/products/types/ProductSkuCreateProductFieldData.d.ts +23 -0
  84. package/api/resources/products/types/ProductSkuCreateProductFieldData.js +5 -0
  85. package/api/resources/products/types/ProductSkuCreateProductFieldDataEcProductType.d.ts +13 -0
  86. package/api/resources/products/types/ProductSkuCreateProductFieldDataEcProductType.js +12 -0
  87. package/api/resources/products/types/ProductSkuCreateProductFieldDataTaxCategory.d.ts +38 -0
  88. package/api/resources/products/types/ProductSkuCreateProductFieldDataTaxCategory.js +37 -0
  89. package/api/resources/products/types/ProductSkuCreateSku.d.ts +19 -0
  90. package/api/resources/products/types/ProductSkuCreateSku.js +5 -0
  91. package/api/resources/products/types/ProductSkuCreateSkuFieldData.d.ts +26 -0
  92. package/api/resources/products/types/ProductSkuCreateSkuFieldData.js +5 -0
  93. package/api/resources/products/types/ProductSkuCreateSkuFieldDataCompareAtPrice.d.ts +12 -0
  94. package/api/resources/products/types/ProductSkuCreateSkuFieldDataCompareAtPrice.js +5 -0
  95. package/api/resources/products/types/ProductSkuCreateSkuFieldDataEcSkuBillingMethod.d.ts +11 -0
  96. package/api/resources/products/types/ProductSkuCreateSkuFieldDataEcSkuBillingMethod.js +10 -0
  97. package/api/resources/products/types/ProductSkuCreateSkuFieldDataEcSkuSubscriptionPlan.d.ts +15 -0
  98. package/api/resources/products/types/ProductSkuCreateSkuFieldDataEcSkuSubscriptionPlan.js +5 -0
  99. package/api/resources/products/types/ProductSkuCreateSkuFieldDataEcSkuSubscriptionPlanInterval.d.ts +13 -0
  100. package/api/resources/products/types/ProductSkuCreateSkuFieldDataEcSkuSubscriptionPlanInterval.js +12 -0
  101. package/api/resources/products/types/ProductSkuCreateSkuFieldDataPrice.d.ts +13 -0
  102. package/api/resources/products/types/ProductSkuCreateSkuFieldDataPrice.js +5 -0
  103. package/api/resources/products/types/index.d.ts +11 -0
  104. package/api/resources/products/types/index.js +11 -0
  105. package/api/resources/scripts/client/Client.d.ts +16 -1
  106. package/api/resources/scripts/client/Client.js +28 -7
  107. package/api/resources/scripts/client/requests/CustomCodeHostedRequest.d.ts +9 -0
  108. package/api/resources/scripts/client/requests/CustomCodeInlineRequest.d.ts +8 -0
  109. package/api/resources/sites/client/Client.d.ts +6 -3
  110. package/api/resources/sites/client/Client.js +26 -13
  111. package/api/resources/sites/resources/activityLogs/client/Client.d.ts +32 -0
  112. package/api/resources/sites/resources/activityLogs/client/Client.js +136 -0
  113. package/api/resources/sites/resources/activityLogs/client/index.d.ts +1 -0
  114. package/api/resources/sites/resources/activityLogs/client/index.js +17 -0
  115. package/api/resources/sites/resources/activityLogs/client/requests/ActivityLogsListRequest.d.ts +17 -0
  116. package/api/resources/sites/resources/activityLogs/client/requests/ActivityLogsListRequest.js +5 -0
  117. package/api/resources/sites/resources/activityLogs/client/requests/index.d.ts +1 -0
  118. package/api/resources/sites/resources/activityLogs/client/requests/index.js +2 -0
  119. package/api/resources/sites/resources/activityLogs/index.d.ts +1 -0
  120. package/api/resources/sites/resources/activityLogs/index.js +17 -0
  121. package/api/resources/sites/resources/index.d.ts +2 -0
  122. package/api/resources/sites/resources/index.js +3 -1
  123. package/api/resources/sites/resources/scripts/client/Client.d.ts +21 -4
  124. package/api/resources/sites/resources/scripts/client/Client.js +37 -12
  125. package/api/resources/token/client/Client.js +8 -4
  126. package/api/resources/users/client/Client.d.ts +14 -18
  127. package/api/resources/users/client/Client.js +35 -29
  128. package/api/resources/users/client/requests/UsersInviteRequest.d.ts +2 -1
  129. package/api/resources/users/client/requests/UsersListRequest.d.ts +1 -3
  130. package/api/resources/users/client/requests/UsersUpdateRequest.d.ts +23 -0
  131. package/api/resources/users/client/requests/UsersUpdateRequest.js +5 -0
  132. package/api/resources/users/client/requests/index.d.ts +1 -0
  133. package/api/resources/users/types/UsersUpdateRequestData.d.ts +11 -0
  134. package/api/resources/users/types/UsersUpdateRequestData.js +5 -0
  135. package/api/resources/users/types/index.d.ts +1 -0
  136. package/api/resources/users/types/index.js +1 -0
  137. package/api/resources/webhooks/client/Client.d.ts +4 -4
  138. package/api/resources/webhooks/client/Client.js +20 -12
  139. package/api/types/AssetFolder.d.ts +3 -0
  140. package/api/types/AssetFolderList.d.ts +2 -1
  141. package/api/types/CollectionItem.d.ts +2 -0
  142. package/api/types/Dom.d.ts +13 -0
  143. package/api/types/Dom.js +5 -0
  144. package/api/types/ImageNode.d.ts +10 -0
  145. package/api/types/ImageNode.js +5 -0
  146. package/api/types/InvalidScopes.d.ts +10 -0
  147. package/api/types/InvalidScopes.js +5 -0
  148. package/api/types/Node.d.ts +15 -0
  149. package/api/types/Node.js +5 -0
  150. package/api/types/NodeType.d.ts +8 -0
  151. package/api/types/NodeType.js +10 -0
  152. package/api/types/NotEnterprisePlanSite.d.ts +14 -0
  153. package/api/types/NotEnterprisePlanSite.js +5 -0
  154. package/api/types/OauthScope.d.ts +5 -1
  155. package/api/types/OauthScope.js +1 -0
  156. package/api/types/ProductAndSkUs.d.ts +1 -0
  157. package/api/types/ProductFieldData.d.ts +17 -3
  158. package/api/types/ProductFieldDataEcProductType.d.ts +13 -0
  159. package/api/types/ProductFieldDataEcProductType.js +12 -0
  160. package/api/types/ProductFieldDataTaxCategory.d.ts +38 -0
  161. package/api/types/ProductFieldDataTaxCategory.js +37 -0
  162. package/api/types/PublishStatus.d.ts +1 -1
  163. package/api/types/SiteActivityLogItem.d.ts +1 -1
  164. package/api/types/SiteActivityLogItemUser.d.ts +7 -0
  165. package/api/types/SiteActivityLogItemUser.js +5 -0
  166. package/api/types/Sku.d.ts +1 -0
  167. package/api/types/SkuFieldData.d.ts +15 -4
  168. package/api/types/SkuFieldDataCompareAtPrice.d.ts +12 -0
  169. package/api/types/SkuFieldDataCompareAtPrice.js +5 -0
  170. package/api/types/SkuFieldDataEcSkuBillingMethod.d.ts +8 -0
  171. package/api/types/SkuFieldDataEcSkuBillingMethod.js +10 -0
  172. package/api/types/SkuFieldDataEcSkuSubscriptionPlan.d.ts +12 -0
  173. package/api/types/SkuFieldDataEcSkuSubscriptionPlan.js +5 -0
  174. package/api/types/SkuFieldDataEcSkuSubscriptionPlanInterval.d.ts +13 -0
  175. package/api/types/SkuFieldDataEcSkuSubscriptionPlanInterval.js +12 -0
  176. package/api/types/SkuPropertyList.d.ts +6 -6
  177. package/api/types/SkuPropertyListEnumItem.d.ts +3 -3
  178. package/api/types/TextNode.d.ts +10 -0
  179. package/api/types/TextNode.js +5 -0
  180. package/api/types/index.d.ts +14 -0
  181. package/api/types/index.js +14 -0
  182. package/core/fetcher/Fetcher.d.ts +1 -1
  183. package/core/fetcher/Fetcher.js +26 -18
  184. package/core/index.d.ts +1 -0
  185. package/core/index.js +1 -0
  186. package/core/runtime/index.d.ts +1 -0
  187. package/core/runtime/index.js +5 -0
  188. package/core/runtime/runtime.d.ts +8 -0
  189. package/core/runtime/runtime.js +82 -0
  190. package/dist/api/resources/accessGroups/client/Client.d.ts +1 -3
  191. package/dist/api/resources/accessGroups/client/Client.js +5 -5
  192. package/dist/api/resources/accessGroups/client/requests/AccessGroupsListRequest.d.ts +1 -3
  193. package/dist/api/resources/assets/client/Client.d.ts +21 -7
  194. package/dist/api/resources/assets/client/Client.js +110 -21
  195. package/dist/api/resources/assets/client/requests/AssetsUpdateRequest.d.ts +13 -0
  196. package/dist/api/resources/assets/client/requests/AssetsUpdateRequest.js +5 -0
  197. package/dist/api/resources/assets/client/requests/index.d.ts +1 -0
  198. package/dist/api/resources/collections/client/Client.d.ts +11 -4
  199. package/dist/api/resources/collections/client/Client.js +31 -14
  200. package/dist/api/resources/collections/client/requests/CollectionsCreateRequest.d.ts +8 -0
  201. package/dist/api/resources/collections/resources/fields/client/Client.d.ts +16 -1
  202. package/dist/api/resources/collections/resources/fields/client/Client.js +24 -5
  203. package/dist/api/resources/collections/resources/fields/client/requests/FieldCreate.d.ts +23 -0
  204. package/dist/api/resources/collections/resources/fields/client/requests/FieldCreate.js +5 -0
  205. package/dist/api/resources/collections/resources/fields/client/requests/FieldUpdate.d.ts +8 -0
  206. package/dist/api/resources/collections/resources/fields/client/requests/index.d.ts +1 -0
  207. package/dist/api/resources/collections/resources/fields/index.d.ts +1 -0
  208. package/dist/api/resources/collections/resources/fields/index.js +1 -0
  209. package/dist/api/resources/collections/resources/fields/types/FieldCreateType.d.ts +22 -0
  210. package/dist/api/resources/collections/resources/fields/types/FieldCreateType.js +21 -0
  211. package/dist/api/resources/collections/resources/fields/types/index.d.ts +1 -0
  212. package/dist/api/resources/collections/resources/fields/types/index.js +17 -0
  213. package/dist/api/resources/collections/resources/index.d.ts +2 -1
  214. package/dist/api/resources/collections/resources/index.js +3 -2
  215. package/dist/api/resources/collections/resources/items/client/Client.d.ts +82 -16
  216. package/dist/api/resources/collections/resources/items/client/Client.js +302 -29
  217. package/dist/api/resources/collections/resources/items/client/requests/ItemsDeleteItemRequest.d.ts +13 -0
  218. package/dist/api/resources/collections/resources/items/client/requests/ItemsDeleteItemRequest.js +5 -0
  219. package/dist/api/resources/collections/resources/items/client/requests/ItemsGetItemRequest.d.ts +13 -0
  220. package/dist/api/resources/collections/resources/items/client/requests/ItemsGetItemRequest.js +5 -0
  221. package/dist/api/resources/collections/resources/items/client/requests/ItemsListItemsRequest.d.ts +4 -0
  222. package/dist/api/resources/collections/resources/items/client/requests/ItemsPublishItemRequest.d.ts +1 -1
  223. package/dist/api/resources/collections/resources/items/client/requests/index.d.ts +2 -0
  224. package/dist/api/resources/ecommerce/client/Client.d.ts +1 -1
  225. package/dist/api/resources/ecommerce/client/Client.js +5 -3
  226. package/dist/api/resources/forms/client/Client.d.ts +6 -6
  227. package/dist/api/resources/forms/client/Client.js +35 -16
  228. package/dist/api/resources/forms/client/requests/FormsListRequest.d.ts +17 -0
  229. package/dist/api/resources/forms/client/requests/FormsListRequest.js +5 -0
  230. package/dist/api/resources/forms/client/requests/index.d.ts +1 -0
  231. package/dist/api/resources/index.d.ts +3 -1
  232. package/dist/api/resources/index.js +4 -2
  233. package/dist/api/resources/inventory/client/Client.d.ts +2 -2
  234. package/dist/api/resources/inventory/client/Client.js +10 -6
  235. package/dist/api/resources/orders/client/Client.d.ts +6 -10
  236. package/dist/api/resources/orders/client/Client.js +30 -22
  237. package/dist/api/resources/orders/client/requests/OrdersListRequest.d.ts +1 -3
  238. package/dist/api/resources/orders/client/requests/OrdersRefundRequest.d.ts +1 -3
  239. package/dist/api/resources/pages/client/Client.d.ts +73 -4
  240. package/dist/api/resources/pages/client/Client.js +312 -8
  241. package/dist/api/resources/pages/client/index.d.ts +1 -1
  242. package/dist/api/resources/pages/client/index.js +15 -0
  243. package/dist/api/resources/pages/client/requests/DomWrite.d.ts +21 -0
  244. package/dist/api/resources/pages/client/requests/DomWrite.js +5 -0
  245. package/dist/api/resources/pages/client/requests/PagesGetContentRequest.d.ts +13 -0
  246. package/dist/api/resources/pages/client/requests/PagesGetContentRequest.js +5 -0
  247. package/dist/api/resources/pages/client/requests/PagesGetMetadataRequest.d.ts +13 -0
  248. package/dist/api/resources/pages/client/requests/PagesGetMetadataRequest.js +5 -0
  249. package/dist/api/resources/pages/client/requests/PagesListRequest.d.ts +21 -0
  250. package/dist/api/resources/pages/client/requests/PagesListRequest.js +5 -0
  251. package/dist/api/resources/pages/client/requests/UpdatePageSettingsRequest.d.ts +40 -0
  252. package/dist/api/resources/pages/client/requests/UpdatePageSettingsRequest.js +5 -0
  253. package/dist/api/resources/pages/client/requests/index.d.ts +5 -0
  254. package/dist/api/resources/pages/client/requests/index.js +2 -0
  255. package/dist/api/resources/pages/index.d.ts +1 -0
  256. package/dist/api/resources/pages/index.js +1 -0
  257. package/dist/api/resources/pages/resources/scripts/client/Client.d.ts +20 -3
  258. package/dist/api/resources/pages/resources/scripts/client/Client.js +32 -9
  259. package/dist/api/resources/pages/types/DomWriteNodesItem.d.ts +9 -0
  260. package/dist/api/resources/pages/types/DomWriteNodesItem.js +5 -0
  261. package/dist/api/resources/pages/types/index.d.ts +1 -0
  262. package/dist/api/resources/pages/types/index.js +17 -0
  263. package/dist/api/resources/products/client/Client.d.ts +54 -74
  264. package/dist/api/resources/products/client/Client.js +79 -87
  265. package/dist/api/resources/products/client/requests/ProductSkuCreate.d.ts +15 -0
  266. package/dist/api/resources/products/client/requests/ProductSkuCreate.js +5 -0
  267. package/dist/api/resources/products/client/requests/ProductsCreateSkuRequest.d.ts +7 -7
  268. package/dist/api/resources/products/client/requests/ProductsUpdateRequest.d.ts +29 -8
  269. package/dist/api/resources/products/client/requests/ProductsUpdateSkuRequest.d.ts +7 -7
  270. package/dist/api/resources/products/client/requests/index.d.ts +1 -1
  271. package/dist/api/resources/products/types/ProductSkuCreateProduct.d.ts +22 -0
  272. package/dist/api/resources/products/types/ProductSkuCreateProduct.js +5 -0
  273. package/dist/api/resources/products/types/ProductSkuCreateProductFieldData.d.ts +23 -0
  274. package/dist/api/resources/products/types/ProductSkuCreateProductFieldData.js +5 -0
  275. package/dist/api/resources/products/types/ProductSkuCreateProductFieldDataEcProductType.d.ts +13 -0
  276. package/dist/api/resources/products/types/ProductSkuCreateProductFieldDataEcProductType.js +12 -0
  277. package/dist/api/resources/products/types/ProductSkuCreateProductFieldDataTaxCategory.d.ts +38 -0
  278. package/dist/api/resources/products/types/ProductSkuCreateProductFieldDataTaxCategory.js +37 -0
  279. package/dist/api/resources/products/types/ProductSkuCreateSku.d.ts +19 -0
  280. package/dist/api/resources/products/types/ProductSkuCreateSku.js +5 -0
  281. package/dist/api/resources/products/types/ProductSkuCreateSkuFieldData.d.ts +26 -0
  282. package/dist/api/resources/products/types/ProductSkuCreateSkuFieldData.js +5 -0
  283. package/dist/api/resources/products/types/ProductSkuCreateSkuFieldDataCompareAtPrice.d.ts +12 -0
  284. package/dist/api/resources/products/types/ProductSkuCreateSkuFieldDataCompareAtPrice.js +5 -0
  285. package/dist/api/resources/products/types/ProductSkuCreateSkuFieldDataEcSkuBillingMethod.d.ts +11 -0
  286. package/dist/api/resources/products/types/ProductSkuCreateSkuFieldDataEcSkuBillingMethod.js +10 -0
  287. package/dist/api/resources/products/types/ProductSkuCreateSkuFieldDataEcSkuSubscriptionPlan.d.ts +15 -0
  288. package/dist/api/resources/products/types/ProductSkuCreateSkuFieldDataEcSkuSubscriptionPlan.js +5 -0
  289. package/dist/api/resources/products/types/ProductSkuCreateSkuFieldDataEcSkuSubscriptionPlanInterval.d.ts +13 -0
  290. package/dist/api/resources/products/types/ProductSkuCreateSkuFieldDataEcSkuSubscriptionPlanInterval.js +12 -0
  291. package/dist/api/resources/products/types/ProductSkuCreateSkuFieldDataPrice.d.ts +13 -0
  292. package/dist/api/resources/products/types/ProductSkuCreateSkuFieldDataPrice.js +5 -0
  293. package/dist/api/resources/products/types/index.d.ts +11 -0
  294. package/dist/api/resources/products/types/index.js +11 -0
  295. package/dist/api/resources/scripts/client/Client.d.ts +16 -1
  296. package/dist/api/resources/scripts/client/Client.js +28 -7
  297. package/dist/api/resources/scripts/client/requests/CustomCodeHostedRequest.d.ts +9 -0
  298. package/dist/api/resources/scripts/client/requests/CustomCodeInlineRequest.d.ts +8 -0
  299. package/dist/api/resources/sites/client/Client.d.ts +6 -3
  300. package/dist/api/resources/sites/client/Client.js +26 -13
  301. package/dist/api/resources/sites/resources/activityLogs/client/Client.d.ts +32 -0
  302. package/dist/api/resources/sites/resources/activityLogs/client/Client.js +136 -0
  303. package/dist/api/resources/sites/resources/activityLogs/client/index.d.ts +1 -0
  304. package/dist/api/resources/sites/resources/activityLogs/client/index.js +17 -0
  305. package/dist/api/resources/sites/resources/activityLogs/client/requests/ActivityLogsListRequest.d.ts +17 -0
  306. package/dist/api/resources/sites/resources/activityLogs/client/requests/ActivityLogsListRequest.js +5 -0
  307. package/dist/api/resources/sites/resources/activityLogs/client/requests/index.d.ts +1 -0
  308. package/dist/api/resources/sites/resources/activityLogs/client/requests/index.js +2 -0
  309. package/dist/api/resources/sites/resources/activityLogs/index.d.ts +1 -0
  310. package/dist/api/resources/sites/resources/activityLogs/index.js +17 -0
  311. package/dist/api/resources/sites/resources/index.d.ts +2 -0
  312. package/dist/api/resources/sites/resources/index.js +3 -1
  313. package/dist/api/resources/sites/resources/scripts/client/Client.d.ts +21 -4
  314. package/dist/api/resources/sites/resources/scripts/client/Client.js +37 -12
  315. package/dist/api/resources/token/client/Client.js +8 -4
  316. package/dist/api/resources/users/client/Client.d.ts +14 -18
  317. package/dist/api/resources/users/client/Client.js +35 -29
  318. package/dist/api/resources/users/client/requests/UsersInviteRequest.d.ts +2 -1
  319. package/dist/api/resources/users/client/requests/UsersListRequest.d.ts +1 -3
  320. package/dist/api/resources/users/client/requests/UsersUpdateRequest.d.ts +23 -0
  321. package/dist/api/resources/users/client/requests/UsersUpdateRequest.js +5 -0
  322. package/dist/api/resources/users/client/requests/index.d.ts +1 -0
  323. package/dist/api/resources/users/types/UsersUpdateRequestData.d.ts +11 -0
  324. package/dist/api/resources/users/types/UsersUpdateRequestData.js +5 -0
  325. package/dist/api/resources/users/types/index.d.ts +1 -0
  326. package/dist/api/resources/users/types/index.js +1 -0
  327. package/dist/api/resources/webhooks/client/Client.d.ts +4 -4
  328. package/dist/api/resources/webhooks/client/Client.js +20 -12
  329. package/dist/api/types/AssetFolder.d.ts +3 -0
  330. package/dist/api/types/AssetFolderList.d.ts +2 -1
  331. package/dist/api/types/CollectionItem.d.ts +2 -0
  332. package/dist/api/types/Dom.d.ts +13 -0
  333. package/dist/api/types/Dom.js +5 -0
  334. package/dist/api/types/ImageNode.d.ts +10 -0
  335. package/dist/api/types/ImageNode.js +5 -0
  336. package/dist/api/types/InvalidScopes.d.ts +10 -0
  337. package/dist/api/types/InvalidScopes.js +5 -0
  338. package/dist/api/types/Node.d.ts +15 -0
  339. package/dist/api/types/Node.js +5 -0
  340. package/dist/api/types/NodeType.d.ts +8 -0
  341. package/dist/api/types/NodeType.js +10 -0
  342. package/dist/api/types/NotEnterprisePlanSite.d.ts +14 -0
  343. package/dist/api/types/NotEnterprisePlanSite.js +5 -0
  344. package/dist/api/types/OauthScope.d.ts +5 -1
  345. package/dist/api/types/OauthScope.js +1 -0
  346. package/dist/api/types/ProductAndSkUs.d.ts +1 -0
  347. package/dist/api/types/ProductFieldData.d.ts +17 -3
  348. package/dist/api/types/ProductFieldDataEcProductType.d.ts +13 -0
  349. package/dist/api/types/ProductFieldDataEcProductType.js +12 -0
  350. package/dist/api/types/ProductFieldDataTaxCategory.d.ts +38 -0
  351. package/dist/api/types/ProductFieldDataTaxCategory.js +37 -0
  352. package/dist/api/types/PublishStatus.d.ts +1 -1
  353. package/dist/api/types/SiteActivityLogItem.d.ts +1 -1
  354. package/dist/api/types/SiteActivityLogItemUser.d.ts +7 -0
  355. package/dist/api/types/SiteActivityLogItemUser.js +5 -0
  356. package/dist/api/types/Sku.d.ts +1 -0
  357. package/dist/api/types/SkuFieldData.d.ts +15 -4
  358. package/dist/api/types/SkuFieldDataCompareAtPrice.d.ts +12 -0
  359. package/dist/api/types/SkuFieldDataCompareAtPrice.js +5 -0
  360. package/dist/api/types/SkuFieldDataEcSkuBillingMethod.d.ts +8 -0
  361. package/dist/api/types/SkuFieldDataEcSkuBillingMethod.js +10 -0
  362. package/dist/api/types/SkuFieldDataEcSkuSubscriptionPlan.d.ts +12 -0
  363. package/dist/api/types/SkuFieldDataEcSkuSubscriptionPlan.js +5 -0
  364. package/dist/api/types/SkuFieldDataEcSkuSubscriptionPlanInterval.d.ts +13 -0
  365. package/dist/api/types/SkuFieldDataEcSkuSubscriptionPlanInterval.js +12 -0
  366. package/dist/api/types/SkuPropertyList.d.ts +6 -6
  367. package/dist/api/types/SkuPropertyListEnumItem.d.ts +3 -3
  368. package/dist/api/types/TextNode.d.ts +10 -0
  369. package/dist/api/types/TextNode.js +5 -0
  370. package/dist/api/types/index.d.ts +14 -0
  371. package/dist/api/types/index.js +14 -0
  372. package/dist/core/fetcher/Fetcher.d.ts +1 -1
  373. package/dist/core/fetcher/Fetcher.js +26 -18
  374. package/dist/core/index.d.ts +1 -0
  375. package/dist/core/index.js +1 -0
  376. package/dist/core/runtime/index.d.ts +1 -0
  377. package/dist/core/runtime/index.js +5 -0
  378. package/dist/core/runtime/runtime.d.ts +8 -0
  379. package/dist/core/runtime/runtime.js +82 -0
  380. package/dist/serialization/resources/assets/client/requests/AssetsUpdateRequest.d.ts +12 -0
  381. package/dist/serialization/resources/assets/client/requests/AssetsUpdateRequest.js +33 -0
  382. package/dist/serialization/resources/assets/client/requests/index.d.ts +1 -0
  383. package/dist/serialization/resources/assets/client/requests/index.js +3 -1
  384. package/dist/serialization/resources/collections/resources/fields/client/requests/FieldCreate.d.ts +15 -0
  385. package/dist/serialization/resources/collections/resources/fields/client/requests/FieldCreate.js +45 -0
  386. package/dist/serialization/resources/collections/resources/fields/client/requests/index.d.ts +1 -0
  387. package/dist/serialization/resources/collections/resources/fields/client/requests/index.js +3 -1
  388. package/dist/serialization/resources/collections/resources/fields/index.d.ts +1 -0
  389. package/dist/serialization/resources/collections/resources/fields/index.js +1 -0
  390. package/dist/serialization/resources/collections/resources/fields/types/FieldCreateType.d.ts +10 -0
  391. package/dist/serialization/resources/collections/resources/fields/types/FieldCreateType.js +45 -0
  392. package/dist/serialization/resources/collections/resources/fields/types/index.d.ts +1 -0
  393. package/dist/serialization/resources/collections/resources/fields/types/index.js +17 -0
  394. package/dist/serialization/resources/collections/resources/index.d.ts +2 -1
  395. package/dist/serialization/resources/collections/resources/index.js +3 -2
  396. package/dist/serialization/resources/index.d.ts +3 -0
  397. package/dist/serialization/resources/index.js +4 -1
  398. package/dist/serialization/resources/pages/client/index.d.ts +1 -0
  399. package/dist/serialization/resources/pages/client/index.js +17 -0
  400. package/dist/serialization/resources/pages/client/requests/DomWrite.d.ts +12 -0
  401. package/dist/serialization/resources/pages/client/requests/DomWrite.js +42 -0
  402. package/dist/serialization/resources/pages/client/requests/index.d.ts +1 -0
  403. package/dist/serialization/resources/pages/client/requests/index.js +5 -0
  404. package/dist/serialization/resources/pages/index.d.ts +2 -0
  405. package/dist/serialization/resources/pages/index.js +18 -0
  406. package/dist/serialization/resources/pages/types/DomWriteNodesItem.d.ts +13 -0
  407. package/dist/serialization/resources/pages/types/DomWriteNodesItem.js +34 -0
  408. package/dist/serialization/resources/pages/types/index.d.ts +1 -0
  409. package/dist/serialization/resources/pages/types/index.js +17 -0
  410. package/dist/serialization/resources/products/client/requests/{ProductsCreateRequest.d.ts → ProductSkuCreate.d.ts} +4 -4
  411. package/{serialization/resources/products/client/requests/ProductsCreateRequest.js → dist/serialization/resources/products/client/requests/ProductSkuCreate.js} +6 -4
  412. package/dist/serialization/resources/products/client/requests/index.d.ts +1 -1
  413. package/dist/serialization/resources/products/client/requests/index.js +3 -3
  414. package/dist/serialization/resources/products/types/ProductSkuCreateProduct.d.ts +18 -0
  415. package/dist/serialization/resources/products/types/ProductSkuCreateProduct.js +50 -0
  416. package/dist/serialization/resources/products/types/ProductSkuCreateProductFieldData.d.ts +20 -0
  417. package/dist/serialization/resources/products/types/ProductSkuCreateProductFieldData.js +56 -0
  418. package/dist/serialization/resources/products/types/ProductSkuCreateProductFieldDataEcProductType.d.ts +10 -0
  419. package/dist/serialization/resources/products/types/ProductSkuCreateProductFieldDataEcProductType.js +36 -0
  420. package/dist/serialization/resources/products/types/ProductSkuCreateProductFieldDataTaxCategory.d.ts +10 -0
  421. package/dist/serialization/resources/products/types/ProductSkuCreateProductFieldDataTaxCategory.js +61 -0
  422. package/dist/serialization/resources/products/types/ProductSkuCreateSku.d.ts +16 -0
  423. package/dist/serialization/resources/products/types/ProductSkuCreateSku.js +48 -0
  424. package/dist/serialization/resources/products/types/ProductSkuCreateSkuFieldData.d.ts +20 -0
  425. package/dist/serialization/resources/products/types/ProductSkuCreateSkuFieldData.js +56 -0
  426. package/dist/serialization/resources/products/types/ProductSkuCreateSkuFieldDataCompareAtPrice.d.ts +13 -0
  427. package/dist/serialization/resources/products/types/ProductSkuCreateSkuFieldDataCompareAtPrice.js +34 -0
  428. package/dist/serialization/resources/products/types/ProductSkuCreateSkuFieldDataEcSkuBillingMethod.d.ts +10 -0
  429. package/dist/serialization/resources/products/types/ProductSkuCreateSkuFieldDataEcSkuBillingMethod.js +31 -0
  430. package/dist/serialization/resources/products/types/ProductSkuCreateSkuFieldDataEcSkuSubscriptionPlan.d.ts +14 -0
  431. package/dist/serialization/resources/products/types/ProductSkuCreateSkuFieldDataEcSkuSubscriptionPlan.js +46 -0
  432. package/dist/serialization/resources/products/types/ProductSkuCreateSkuFieldDataEcSkuSubscriptionPlanInterval.d.ts +10 -0
  433. package/dist/serialization/resources/products/types/ProductSkuCreateSkuFieldDataEcSkuSubscriptionPlanInterval.js +31 -0
  434. package/dist/serialization/resources/products/types/ProductSkuCreateSkuFieldDataPrice.d.ts +14 -0
  435. package/dist/serialization/resources/products/types/ProductSkuCreateSkuFieldDataPrice.js +35 -0
  436. package/dist/serialization/resources/products/types/index.d.ts +11 -0
  437. package/dist/serialization/resources/products/types/index.js +11 -0
  438. package/dist/serialization/resources/users/client/requests/UsersUpdateRequest.d.ts +13 -0
  439. package/dist/serialization/resources/users/client/requests/UsersUpdateRequest.js +43 -0
  440. package/dist/serialization/resources/users/client/requests/index.d.ts +1 -0
  441. package/dist/serialization/resources/users/client/requests/index.js +3 -1
  442. package/dist/serialization/resources/users/types/UsersUpdateRequestData.d.ts +14 -0
  443. package/dist/serialization/resources/users/types/UsersUpdateRequestData.js +35 -0
  444. package/dist/serialization/resources/users/types/index.d.ts +1 -0
  445. package/dist/serialization/resources/users/types/index.js +1 -0
  446. package/dist/serialization/types/AssetFolderList.d.ts +1 -1
  447. package/dist/serialization/types/AssetFolderList.js +2 -2
  448. package/dist/serialization/types/CollectionItem.d.ts +1 -0
  449. package/dist/serialization/types/CollectionItem.js +1 -0
  450. package/dist/serialization/types/Dom.d.ts +14 -0
  451. package/dist/serialization/types/Dom.js +44 -0
  452. package/dist/serialization/types/ImageNode.d.ts +13 -0
  453. package/dist/serialization/types/ImageNode.js +34 -0
  454. package/dist/serialization/types/InvalidScopes.d.ts +16 -0
  455. package/dist/serialization/types/InvalidScopes.js +37 -0
  456. package/dist/serialization/types/Node.d.ts +16 -0
  457. package/dist/serialization/types/Node.js +46 -0
  458. package/dist/serialization/types/NodeType.d.ts +10 -0
  459. package/dist/serialization/types/NodeType.js +31 -0
  460. package/dist/serialization/types/NotEnterprisePlanSite.d.ts +16 -0
  461. package/dist/serialization/types/NotEnterprisePlanSite.js +48 -0
  462. package/dist/serialization/types/OauthScope.d.ts +1 -1
  463. package/dist/serialization/types/OauthScope.js +1 -0
  464. package/dist/serialization/types/ProductFieldData.d.ts +9 -2
  465. package/dist/serialization/types/ProductFieldData.js +9 -2
  466. package/dist/serialization/types/ProductFieldDataEcProductType.d.ts +10 -0
  467. package/dist/serialization/types/ProductFieldDataEcProductType.js +36 -0
  468. package/dist/serialization/types/ProductFieldDataTaxCategory.d.ts +10 -0
  469. package/dist/serialization/types/ProductFieldDataTaxCategory.js +61 -0
  470. package/dist/serialization/types/SiteActivityLogItem.d.ts +1 -1
  471. package/dist/serialization/types/SiteActivityLogItem.js +1 -1
  472. package/dist/serialization/types/SiteActivityLogItemUser.d.ts +13 -0
  473. package/dist/serialization/types/SiteActivityLogItemUser.js +34 -0
  474. package/dist/serialization/types/SkuFieldData.d.ts +8 -3
  475. package/dist/serialization/types/SkuFieldData.js +8 -3
  476. package/dist/serialization/types/SkuFieldDataCompareAtPrice.d.ts +13 -0
  477. package/dist/serialization/types/SkuFieldDataCompareAtPrice.js +34 -0
  478. package/dist/serialization/types/SkuFieldDataEcSkuBillingMethod.d.ts +10 -0
  479. package/dist/serialization/types/SkuFieldDataEcSkuBillingMethod.js +31 -0
  480. package/dist/serialization/types/SkuFieldDataEcSkuSubscriptionPlan.d.ts +14 -0
  481. package/dist/serialization/types/SkuFieldDataEcSkuSubscriptionPlan.js +46 -0
  482. package/dist/serialization/types/SkuFieldDataEcSkuSubscriptionPlanInterval.d.ts +10 -0
  483. package/dist/serialization/types/SkuFieldDataEcSkuSubscriptionPlanInterval.js +31 -0
  484. package/dist/serialization/types/SkuPropertyList.d.ts +3 -3
  485. package/dist/serialization/types/SkuPropertyList.js +3 -5
  486. package/dist/serialization/types/SkuPropertyListEnumItem.d.ts +3 -3
  487. package/dist/serialization/types/SkuPropertyListEnumItem.js +3 -3
  488. package/dist/serialization/types/TextNode.d.ts +13 -0
  489. package/dist/serialization/types/TextNode.js +34 -0
  490. package/dist/serialization/types/index.d.ts +14 -0
  491. package/dist/serialization/types/index.js +14 -0
  492. package/jest.config.js +5 -0
  493. package/package.json +6 -4
  494. package/serialization/resources/assets/client/requests/AssetsUpdateRequest.d.ts +12 -0
  495. package/serialization/resources/assets/client/requests/AssetsUpdateRequest.js +33 -0
  496. package/serialization/resources/assets/client/requests/index.d.ts +1 -0
  497. package/serialization/resources/assets/client/requests/index.js +3 -1
  498. package/serialization/resources/collections/resources/fields/client/requests/FieldCreate.d.ts +15 -0
  499. package/serialization/resources/collections/resources/fields/client/requests/FieldCreate.js +45 -0
  500. package/serialization/resources/collections/resources/fields/client/requests/index.d.ts +1 -0
  501. package/serialization/resources/collections/resources/fields/client/requests/index.js +3 -1
  502. package/serialization/resources/collections/resources/fields/index.d.ts +1 -0
  503. package/serialization/resources/collections/resources/fields/index.js +1 -0
  504. package/serialization/resources/collections/resources/fields/types/FieldCreateType.d.ts +10 -0
  505. package/serialization/resources/collections/resources/fields/types/FieldCreateType.js +45 -0
  506. package/serialization/resources/collections/resources/fields/types/index.d.ts +1 -0
  507. package/serialization/resources/collections/resources/fields/types/index.js +17 -0
  508. package/serialization/resources/collections/resources/index.d.ts +2 -1
  509. package/serialization/resources/collections/resources/index.js +3 -2
  510. package/serialization/resources/index.d.ts +3 -0
  511. package/serialization/resources/index.js +4 -1
  512. package/serialization/resources/pages/client/index.d.ts +1 -0
  513. package/serialization/resources/pages/client/index.js +17 -0
  514. package/serialization/resources/pages/client/requests/DomWrite.d.ts +12 -0
  515. package/serialization/resources/pages/client/requests/DomWrite.js +42 -0
  516. package/serialization/resources/pages/client/requests/index.d.ts +1 -0
  517. package/serialization/resources/pages/client/requests/index.js +5 -0
  518. package/serialization/resources/pages/index.d.ts +2 -0
  519. package/serialization/resources/pages/index.js +18 -0
  520. package/serialization/resources/pages/types/DomWriteNodesItem.d.ts +13 -0
  521. package/serialization/resources/pages/types/DomWriteNodesItem.js +34 -0
  522. package/serialization/resources/pages/types/index.d.ts +1 -0
  523. package/serialization/resources/pages/types/index.js +17 -0
  524. package/serialization/resources/products/client/requests/{ProductsCreateRequest.d.ts → ProductSkuCreate.d.ts} +4 -4
  525. package/{dist/serialization/resources/products/client/requests/ProductsCreateRequest.js → serialization/resources/products/client/requests/ProductSkuCreate.js} +6 -4
  526. package/serialization/resources/products/client/requests/index.d.ts +1 -1
  527. package/serialization/resources/products/client/requests/index.js +3 -3
  528. package/serialization/resources/products/types/ProductSkuCreateProduct.d.ts +18 -0
  529. package/serialization/resources/products/types/ProductSkuCreateProduct.js +50 -0
  530. package/serialization/resources/products/types/ProductSkuCreateProductFieldData.d.ts +20 -0
  531. package/serialization/resources/products/types/ProductSkuCreateProductFieldData.js +56 -0
  532. package/serialization/resources/products/types/ProductSkuCreateProductFieldDataEcProductType.d.ts +10 -0
  533. package/serialization/resources/products/types/ProductSkuCreateProductFieldDataEcProductType.js +36 -0
  534. package/serialization/resources/products/types/ProductSkuCreateProductFieldDataTaxCategory.d.ts +10 -0
  535. package/serialization/resources/products/types/ProductSkuCreateProductFieldDataTaxCategory.js +61 -0
  536. package/serialization/resources/products/types/ProductSkuCreateSku.d.ts +16 -0
  537. package/serialization/resources/products/types/ProductSkuCreateSku.js +48 -0
  538. package/serialization/resources/products/types/ProductSkuCreateSkuFieldData.d.ts +20 -0
  539. package/serialization/resources/products/types/ProductSkuCreateSkuFieldData.js +56 -0
  540. package/serialization/resources/products/types/ProductSkuCreateSkuFieldDataCompareAtPrice.d.ts +13 -0
  541. package/serialization/resources/products/types/ProductSkuCreateSkuFieldDataCompareAtPrice.js +34 -0
  542. package/serialization/resources/products/types/ProductSkuCreateSkuFieldDataEcSkuBillingMethod.d.ts +10 -0
  543. package/serialization/resources/products/types/ProductSkuCreateSkuFieldDataEcSkuBillingMethod.js +31 -0
  544. package/serialization/resources/products/types/ProductSkuCreateSkuFieldDataEcSkuSubscriptionPlan.d.ts +14 -0
  545. package/serialization/resources/products/types/ProductSkuCreateSkuFieldDataEcSkuSubscriptionPlan.js +46 -0
  546. package/serialization/resources/products/types/ProductSkuCreateSkuFieldDataEcSkuSubscriptionPlanInterval.d.ts +10 -0
  547. package/serialization/resources/products/types/ProductSkuCreateSkuFieldDataEcSkuSubscriptionPlanInterval.js +31 -0
  548. package/serialization/resources/products/types/ProductSkuCreateSkuFieldDataPrice.d.ts +14 -0
  549. package/serialization/resources/products/types/ProductSkuCreateSkuFieldDataPrice.js +35 -0
  550. package/serialization/resources/products/types/index.d.ts +11 -0
  551. package/serialization/resources/products/types/index.js +11 -0
  552. package/serialization/resources/users/client/requests/UsersUpdateRequest.d.ts +13 -0
  553. package/serialization/resources/users/client/requests/UsersUpdateRequest.js +43 -0
  554. package/serialization/resources/users/client/requests/index.d.ts +1 -0
  555. package/serialization/resources/users/client/requests/index.js +3 -1
  556. package/serialization/resources/users/types/UsersUpdateRequestData.d.ts +14 -0
  557. package/serialization/resources/users/types/UsersUpdateRequestData.js +35 -0
  558. package/serialization/resources/users/types/index.d.ts +1 -0
  559. package/serialization/resources/users/types/index.js +1 -0
  560. package/serialization/types/AssetFolderList.d.ts +1 -1
  561. package/serialization/types/AssetFolderList.js +2 -2
  562. package/serialization/types/CollectionItem.d.ts +1 -0
  563. package/serialization/types/CollectionItem.js +1 -0
  564. package/serialization/types/Dom.d.ts +14 -0
  565. package/serialization/types/Dom.js +44 -0
  566. package/serialization/types/ImageNode.d.ts +13 -0
  567. package/serialization/types/ImageNode.js +34 -0
  568. package/serialization/types/InvalidScopes.d.ts +16 -0
  569. package/serialization/types/InvalidScopes.js +37 -0
  570. package/serialization/types/Node.d.ts +16 -0
  571. package/serialization/types/Node.js +46 -0
  572. package/serialization/types/NodeType.d.ts +10 -0
  573. package/serialization/types/NodeType.js +31 -0
  574. package/serialization/types/NotEnterprisePlanSite.d.ts +16 -0
  575. package/serialization/types/NotEnterprisePlanSite.js +48 -0
  576. package/serialization/types/OauthScope.d.ts +1 -1
  577. package/serialization/types/OauthScope.js +1 -0
  578. package/serialization/types/ProductFieldData.d.ts +9 -2
  579. package/serialization/types/ProductFieldData.js +9 -2
  580. package/serialization/types/ProductFieldDataEcProductType.d.ts +10 -0
  581. package/serialization/types/ProductFieldDataEcProductType.js +36 -0
  582. package/serialization/types/ProductFieldDataTaxCategory.d.ts +10 -0
  583. package/serialization/types/ProductFieldDataTaxCategory.js +61 -0
  584. package/serialization/types/SiteActivityLogItem.d.ts +1 -1
  585. package/serialization/types/SiteActivityLogItem.js +1 -1
  586. package/serialization/types/SiteActivityLogItemUser.d.ts +13 -0
  587. package/serialization/types/SiteActivityLogItemUser.js +34 -0
  588. package/serialization/types/SkuFieldData.d.ts +8 -3
  589. package/serialization/types/SkuFieldData.js +8 -3
  590. package/serialization/types/SkuFieldDataCompareAtPrice.d.ts +13 -0
  591. package/serialization/types/SkuFieldDataCompareAtPrice.js +34 -0
  592. package/serialization/types/SkuFieldDataEcSkuBillingMethod.d.ts +10 -0
  593. package/serialization/types/SkuFieldDataEcSkuBillingMethod.js +31 -0
  594. package/serialization/types/SkuFieldDataEcSkuSubscriptionPlan.d.ts +14 -0
  595. package/serialization/types/SkuFieldDataEcSkuSubscriptionPlan.js +46 -0
  596. package/serialization/types/SkuFieldDataEcSkuSubscriptionPlanInterval.d.ts +10 -0
  597. package/serialization/types/SkuFieldDataEcSkuSubscriptionPlanInterval.js +31 -0
  598. package/serialization/types/SkuPropertyList.d.ts +3 -3
  599. package/serialization/types/SkuPropertyList.js +3 -5
  600. package/serialization/types/SkuPropertyListEnumItem.d.ts +3 -3
  601. package/serialization/types/SkuPropertyListEnumItem.js +3 -3
  602. package/serialization/types/TextNode.d.ts +13 -0
  603. package/serialization/types/TextNode.js +34 -0
  604. package/serialization/types/index.d.ts +14 -0
  605. package/serialization/types/index.js +14 -0
  606. package/tests/client.test.ts +11 -0
  607. package/api/resources/products/client/requests/ProductsCreateRequest.d.ts +0 -50
  608. package/dist/api/resources/products/client/requests/ProductsCreateRequest.d.ts +0 -50
  609. package/dist/oauth.d.ts +0 -27
  610. package/dist/oauth.js +0 -113
  611. package/oauth.d.ts +0 -27
  612. package/oauth.js +0 -113
  613. /package/api/resources/{products/client/requests/ProductsCreateRequest.js → assets/client/requests/AssetsUpdateRequest.js} +0 -0
  614. /package/{dist/api/resources/products/client/requests/ProductsCreateRequest.js → api/resources/collections/resources/fields/client/requests/FieldCreate.js} +0 -0
@@ -58,19 +58,21 @@ class Scripts {
58
58
  * @throws {@link Webflow.InternalServerError}
59
59
  *
60
60
  * @example
61
- * await webflow.pages.scripts.getCustomCode("page-id")
61
+ * await webflow.pages.scripts.getCustomCode("page_id")
62
62
  */
63
63
  getCustomCode(pageId, requestOptions) {
64
64
  var _a;
65
65
  return __awaiter(this, void 0, void 0, function* () {
66
66
  const _response = yield core.fetcher({
67
- url: (0, url_join_1.default)((_a = (yield core.Supplier.get(this._options.environment))) !== null && _a !== void 0 ? _a : environments.WebflowEnvironment.Default, `v2/pages/${pageId}/custom_code`),
67
+ url: (0, url_join_1.default)((_a = (yield core.Supplier.get(this._options.environment))) !== null && _a !== void 0 ? _a : environments.WebflowEnvironment.Default, `pages/${pageId}/custom_code`),
68
68
  method: "GET",
69
69
  headers: {
70
70
  Authorization: yield this._getAuthorizationHeader(),
71
71
  "X-Fern-Language": "JavaScript",
72
72
  "X-Fern-SDK-Name": "webflow-api",
73
- "X-Fern-SDK-Version": "2.0.0-beta",
73
+ "X-Fern-SDK-Version": "v2.1.1",
74
+ "X-Fern-Runtime": core.RUNTIME.type,
75
+ "X-Fern-Runtime-Version": core.RUNTIME.version,
74
76
  },
75
77
  contentType: "application/json",
76
78
  timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
@@ -128,19 +130,38 @@ class Scripts {
128
130
  * @throws {@link Webflow.InternalServerError}
129
131
  *
130
132
  * @example
131
- * await webflow.pages.scripts.upsertCustomCode("page-id", {})
133
+ * await webflow.pages.scripts.upsertCustomCode("page_id", {
134
+ * scripts: [{
135
+ * id: "cms_slider",
136
+ * location: Webflow.ScriptApplyLocation.Header,
137
+ * version: "1.0.0",
138
+ * attributes: {
139
+ * "my-attribute": "some-value"
140
+ * }
141
+ * }, {
142
+ * id: "alert",
143
+ * location: Webflow.ScriptApplyLocation.Header,
144
+ * version: "0.0.1"
145
+ * }, {
146
+ * id: "id",
147
+ * location: Webflow.ScriptApplyLocation.Header,
148
+ * version: "version"
149
+ * }]
150
+ * })
132
151
  */
133
152
  upsertCustomCode(pageId, request, requestOptions) {
134
153
  var _a;
135
154
  return __awaiter(this, void 0, void 0, function* () {
136
155
  const _response = yield core.fetcher({
137
- url: (0, url_join_1.default)((_a = (yield core.Supplier.get(this._options.environment))) !== null && _a !== void 0 ? _a : environments.WebflowEnvironment.Default, `v2/pages/${pageId}/custom_code`),
156
+ url: (0, url_join_1.default)((_a = (yield core.Supplier.get(this._options.environment))) !== null && _a !== void 0 ? _a : environments.WebflowEnvironment.Default, `pages/${pageId}/custom_code`),
138
157
  method: "PUT",
139
158
  headers: {
140
159
  Authorization: yield this._getAuthorizationHeader(),
141
160
  "X-Fern-Language": "JavaScript",
142
161
  "X-Fern-SDK-Name": "webflow-api",
143
- "X-Fern-SDK-Version": "2.0.0-beta",
162
+ "X-Fern-SDK-Version": "v2.1.1",
163
+ "X-Fern-Runtime": core.RUNTIME.type,
164
+ "X-Fern-Runtime-Version": core.RUNTIME.version,
144
165
  },
145
166
  contentType: "application/json",
146
167
  body: yield serializers.ScriptApplyList.jsonOrThrow(request, { unrecognizedObjectKeys: "strip" }),
@@ -199,19 +220,21 @@ class Scripts {
199
220
  * @throws {@link Webflow.InternalServerError}
200
221
  *
201
222
  * @example
202
- * await webflow.pages.scripts.deleteCustomCode("page-id")
223
+ * await webflow.pages.scripts.deleteCustomCode("page_id")
203
224
  */
204
225
  deleteCustomCode(pageId, requestOptions) {
205
226
  var _a;
206
227
  return __awaiter(this, void 0, void 0, function* () {
207
228
  const _response = yield core.fetcher({
208
- url: (0, url_join_1.default)((_a = (yield core.Supplier.get(this._options.environment))) !== null && _a !== void 0 ? _a : environments.WebflowEnvironment.Default, `v2/pages/${pageId}/custom_code`),
229
+ url: (0, url_join_1.default)((_a = (yield core.Supplier.get(this._options.environment))) !== null && _a !== void 0 ? _a : environments.WebflowEnvironment.Default, `pages/${pageId}/custom_code`),
209
230
  method: "DELETE",
210
231
  headers: {
211
232
  Authorization: yield this._getAuthorizationHeader(),
212
233
  "X-Fern-Language": "JavaScript",
213
234
  "X-Fern-SDK-Name": "webflow-api",
214
- "X-Fern-SDK-Version": "2.0.0-beta",
235
+ "X-Fern-SDK-Version": "v2.1.1",
236
+ "X-Fern-Runtime": core.RUNTIME.type,
237
+ "X-Fern-Runtime-Version": core.RUNTIME.version,
215
238
  },
216
239
  contentType: "application/json",
217
240
  timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
@@ -0,0 +1,9 @@
1
+ /**
2
+ * This file was auto-generated by Fern from our API Definition.
3
+ */
4
+ export interface DomWriteNodesItem {
5
+ /** Node UUID */
6
+ nodeId: string;
7
+ /** HTML content of the node */
8
+ text: string;
9
+ }
@@ -0,0 +1,5 @@
1
+ "use strict";
2
+ /**
3
+ * This file was auto-generated by Fern from our API Definition.
4
+ */
5
+ Object.defineProperty(exports, "__esModule", { value: true });
@@ -0,0 +1 @@
1
+ export * from "./DomWriteNodesItem";
@@ -0,0 +1,17 @@
1
+ "use strict";
2
+ var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
3
+ if (k2 === undefined) k2 = k;
4
+ var desc = Object.getOwnPropertyDescriptor(m, k);
5
+ if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
6
+ desc = { enumerable: true, get: function() { return m[k]; } };
7
+ }
8
+ Object.defineProperty(o, k2, desc);
9
+ }) : (function(o, m, k, k2) {
10
+ if (k2 === undefined) k2 = k;
11
+ o[k2] = m[k];
12
+ }));
13
+ var __exportStar = (this && this.__exportStar) || function(m, exports) {
14
+ for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
15
+ };
16
+ Object.defineProperty(exports, "__esModule", { value: true });
17
+ __exportStar(require("./DomWriteNodesItem"), exports);
@@ -30,21 +30,17 @@ export declare class Products {
30
30
  * @throws {@link Webflow.InternalServerError}
31
31
  *
32
32
  * @example
33
- * await webflow.products.list("site-id", {})
33
+ * await webflow.products.list("site_id", {})
34
34
  */
35
35
  list(siteId: string, request?: Webflow.ProductsListRequest, requestOptions?: Products.RequestOptions): Promise<Webflow.ProductAndSkUsList>;
36
36
  /**
37
- * Adding a new Product involves creating both a Product Item and a SKU Item, since a Product Item has to have, at minimum, a SKU Item.
37
+ * Creating a new Product involves creating both a Product and a SKU, since a Product Item has to have, at minimum, a single SKU.
38
38
  *
39
- * To create a new Product with multiple SKUs, you must:
39
+ * In order to create a Product with multiple SKUs - for example a T-shirt in sizes small, medium and large - you'll need to create `sku-properties`. In our T-shirt example, a single `sku-property` would be Color. Within that property, we'll need to list out the various colors a T-shirt could be as an array of `enum` values: `royal-blue`, `crimson-red`, and `forrest-green`.
40
40
  *
41
- * - Create the Product and Default SKU using this endpoint, making sure to add `sku-properties` in the product data.
42
- * - You can't add `sku-values` to the SKU yet, since there are no enum IDs created yet. When this endpoint returns, it will have IDs filled in for the `sku-properties` enums.
43
- * - With those IDs, update the default SKU with valid `sku-values` and create any additional SKUs (if needed), with valid `sku-values`.
44
- * - You can also create the Product without `sku-properties` and add them in later.
45
- * - If you add any `sku` properties, the default SKU will default to the first value of each option.
41
+ * Once, you've created a Product and its `sku-properties` with `enum` values, you can create your default SKU, which will automatically be a combination of the first `sku-properties` you've created. In our example, the default SKU will be a Royal Blue T-Shirt, because our first `enum` of our Color `sku-property` is Royal Blue. After you've created your product, you can create additional SKUs using the <a href="https://developers.webflow.com/reference/create-skus">Create SKU endpoint</a>
46
42
  *
47
- * Upon creation, the default product type will be `Advanced`. The product type is used to determine which Product and SKU fields are shown to users in the `Designer` and the `Editor`. Setting it to `Advanced` ensures that all Product and SKU fields will be shown. The product type can be edited in the `Designer` or the `Editor`.
43
+ * Upon creation, the default product type will be `Advanced`. The product type is used to determine which Product and SKU fields are shown to users in the `Designer` and the `Editor`. Setting it to `Advanced` ensures that all Product and SKU fields will be shown.
48
44
  *
49
45
  * Required scope | `ecommerce:write`
50
46
  * @throws {@link Webflow.BadRequestError}
@@ -56,46 +52,9 @@ export declare class Products {
56
52
  * @throws {@link Webflow.InternalServerError}
57
53
  *
58
54
  * @example
59
- * await webflow.products.create("site-id", {
60
- * publishStatus: Webflow.PublishStatus.Staging,
61
- * product: {
62
- * id: "580e63fc8c9a982ac9b8b745",
63
- * lastPublished: new Date("2023-03-17T18:47:35.560Z"),
64
- * lastUpdated: new Date("2023-03-17T18:47:35.560Z"),
65
- * createdOn: new Date("2023-03-17T18:47:35.560Z"),
66
- * isArchived: false,
67
- * isDraft: false,
68
- * fieldData: {
69
- * name: "My new item",
70
- * slug: "my-new-item",
71
- * skuProperties: [{
72
- * id: "ff42fee0113744f693a764e3431a9cc2",
73
- * name: "Color",
74
- * enum: [{
75
- * id: "64a74715c456e36762fc39a1",
76
- * name: "Royal Blue",
77
- * slug: "royal-blue"
78
- * }]
79
- * }]
80
- * }
81
- * },
82
- * sku: {
83
- * id: "580e63fc8c9a982ac9b8b745",
84
- * lastPublished: new Date("2023-03-17T18:47:35.560Z"),
85
- * lastUpdated: new Date("2023-03-17T18:47:35.560Z"),
86
- * createdOn: new Date("2023-03-17T18:47:35.560Z"),
87
- * fieldData: {
88
- * name: "My new item",
89
- * slug: "my-new-item",
90
- * price: {
91
- * value: 100,
92
- * unit: "USD"
93
- * }
94
- * }
95
- * }
96
- * })
55
+ * await webflow.products.create("site_id", {})
97
56
  */
98
- create(siteId: string, request: Webflow.ProductsCreateRequest, requestOptions?: Products.RequestOptions): Promise<Webflow.ProductAndSkUs>;
57
+ create(siteId: string, request?: Webflow.ProductSkuCreate, requestOptions?: Products.RequestOptions): Promise<Webflow.ProductAndSkUs>;
99
58
  /**
100
59
  * Retrieve a single product by its id. All of its SKUs will also be retrieved.
101
60
  *
@@ -109,7 +68,7 @@ export declare class Products {
109
68
  * @throws {@link Webflow.InternalServerError}
110
69
  *
111
70
  * @example
112
- * await webflow.products.get("site-id", "product-id")
71
+ * await webflow.products.get("site_id", "product_id")
113
72
  */
114
73
  get(siteId: string, productId: string, requestOptions?: Products.RequestOptions): Promise<Webflow.ProductAndSkUs>;
115
74
  /**
@@ -125,25 +84,46 @@ export declare class Products {
125
84
  * @throws {@link Webflow.InternalServerError}
126
85
  *
127
86
  * @example
128
- * await webflow.products.update("site-id", "product-id", {
129
- * publishStatus: Webflow.PublishStatus.Staging,
87
+ * await webflow.products.update("site_id", "product_id", {
130
88
  * product: {
131
89
  * id: "580e63fc8c9a982ac9b8b745",
132
- * lastPublished: new Date("2023-03-17T18:47:35.560Z"),
133
- * lastUpdated: new Date("2023-03-17T18:47:35.560Z"),
134
- * createdOn: new Date("2023-03-17T18:47:35.560Z"),
90
+ * lastPublished: new Date("2023-03-17T18:47:35.000Z"),
91
+ * lastUpdated: new Date("2023-03-17T18:47:35.000Z"),
92
+ * createdOn: new Date("2023-03-17T18:47:35.000Z"),
135
93
  * isArchived: false,
136
94
  * isDraft: false,
137
95
  * fieldData: {
138
- * name: "My new item",
139
- * slug: "my-new-item",
96
+ * name: "T-Shirt",
97
+ * slug: "t-shirt",
98
+ * description: "A plain cotton t-shirt.",
99
+ * shippable: true,
140
100
  * skuProperties: [{
141
- * id: "ff42fee0113744f693a764e3431a9cc2",
101
+ * id: "color",
142
102
  * name: "Color",
143
103
  * enum: [{
144
- * id: "64a74715c456e36762fc39a1",
104
+ * id: "royal-blue",
145
105
  * name: "Royal Blue",
146
106
  * slug: "royal-blue"
107
+ * }, {
108
+ * id: "crimson-red",
109
+ * name: "Crimson Red",
110
+ * slug: "crimson-red"
111
+ * }, {
112
+ * id: "forrest-green",
113
+ * name: "Forrst Green",
114
+ * slug: "forrest-green"
115
+ * }, {
116
+ * id: "id",
117
+ * name: "name",
118
+ * slug: "slug"
119
+ * }]
120
+ * }, {
121
+ * id: "Color",
122
+ * name: "Color",
123
+ * enum: [{
124
+ * id: "id",
125
+ * name: "name",
126
+ * slug: "slug"
147
127
  * }]
148
128
  * }]
149
129
  * }
@@ -166,20 +146,20 @@ export declare class Products {
166
146
  * @throws {@link Webflow.InternalServerError}
167
147
  *
168
148
  * @example
169
- * await webflow.products.createSku("site-id", "product-id", {
170
- * publishStatus: Webflow.PublishStatus.Staging,
149
+ * await webflow.products.createSku("site_id", "product_id", {
171
150
  * skus: [{
172
151
  * id: "580e63fc8c9a982ac9b8b745",
173
- * lastPublished: new Date("2023-03-17T18:47:35.560Z"),
174
- * lastUpdated: new Date("2023-03-17T18:47:35.560Z"),
175
- * createdOn: new Date("2023-03-17T18:47:35.560Z"),
152
+ * lastPublished: new Date("2023-03-17T18:47:35.000Z"),
153
+ * lastUpdated: new Date("2023-03-17T18:47:35.000Z"),
154
+ * createdOn: new Date("2023-03-17T18:47:35.000Z"),
176
155
  * fieldData: {
177
- * name: "My new item",
178
- * slug: "my-new-item",
156
+ * name: "Blue T-shirt",
157
+ * slug: "t-shirt-blue",
179
158
  * price: {
180
159
  * value: 100,
181
160
  * unit: "USD"
182
- * }
161
+ * },
162
+ * quantity: 10
183
163
  * }
184
164
  * }]
185
165
  * })
@@ -198,20 +178,20 @@ export declare class Products {
198
178
  * @throws {@link Webflow.InternalServerError}
199
179
  *
200
180
  * @example
201
- * await webflow.products.updateSku("site-id", "product-id", "sku-id", {
202
- * publishStatus: Webflow.PublishStatus.Staging,
181
+ * await webflow.products.updateSku("site_id", "product_id", "sku_id", {
203
182
  * sku: {
204
183
  * id: "580e63fc8c9a982ac9b8b745",
205
- * lastPublished: new Date("2023-03-17T18:47:35.560Z"),
206
- * lastUpdated: new Date("2023-03-17T18:47:35.560Z"),
207
- * createdOn: new Date("2023-03-17T18:47:35.560Z"),
184
+ * lastPublished: new Date("2023-03-17T18:47:35.000Z"),
185
+ * lastUpdated: new Date("2023-03-17T18:47:35.000Z"),
186
+ * createdOn: new Date("2023-03-17T18:47:35.000Z"),
208
187
  * fieldData: {
209
- * name: "My new item",
210
- * slug: "my-new-item",
188
+ * name: "Blue T-shirt",
189
+ * slug: "t-shirt-blue",
211
190
  * price: {
212
191
  * value: 100,
213
192
  * unit: "USD"
214
- * }
193
+ * },
194
+ * quantity: 10
215
195
  * }
216
196
  * }
217
197
  * })
@@ -62,7 +62,7 @@ class Products {
62
62
  * @throws {@link Webflow.InternalServerError}
63
63
  *
64
64
  * @example
65
- * await webflow.products.list("site-id", {})
65
+ * await webflow.products.list("site_id", {})
66
66
  */
67
67
  list(siteId, request = {}, requestOptions) {
68
68
  var _a;
@@ -76,13 +76,15 @@ class Products {
76
76
  _queryParams["limit"] = limit.toString();
77
77
  }
78
78
  const _response = yield core.fetcher({
79
- url: (0, url_join_1.default)((_a = (yield core.Supplier.get(this._options.environment))) !== null && _a !== void 0 ? _a : environments.WebflowEnvironment.Default, `v2/sites/${siteId}/products`),
79
+ url: (0, url_join_1.default)((_a = (yield core.Supplier.get(this._options.environment))) !== null && _a !== void 0 ? _a : environments.WebflowEnvironment.Default, `sites/${siteId}/products`),
80
80
  method: "GET",
81
81
  headers: {
82
82
  Authorization: yield this._getAuthorizationHeader(),
83
83
  "X-Fern-Language": "JavaScript",
84
84
  "X-Fern-SDK-Name": "webflow-api",
85
- "X-Fern-SDK-Version": "2.0.0-beta",
85
+ "X-Fern-SDK-Version": "v2.1.1",
86
+ "X-Fern-Runtime": core.RUNTIME.type,
87
+ "X-Fern-Runtime-Version": core.RUNTIME.version,
86
88
  },
87
89
  contentType: "application/json",
88
90
  queryParameters: _queryParams,
@@ -137,17 +139,13 @@ class Products {
137
139
  });
138
140
  }
139
141
  /**
140
- * Adding a new Product involves creating both a Product Item and a SKU Item, since a Product Item has to have, at minimum, a SKU Item.
142
+ * Creating a new Product involves creating both a Product and a SKU, since a Product Item has to have, at minimum, a single SKU.
141
143
  *
142
- * To create a new Product with multiple SKUs, you must:
144
+ * In order to create a Product with multiple SKUs - for example a T-shirt in sizes small, medium and large - you'll need to create `sku-properties`. In our T-shirt example, a single `sku-property` would be Color. Within that property, we'll need to list out the various colors a T-shirt could be as an array of `enum` values: `royal-blue`, `crimson-red`, and `forrest-green`.
143
145
  *
144
- * - Create the Product and Default SKU using this endpoint, making sure to add `sku-properties` in the product data.
145
- * - You can't add `sku-values` to the SKU yet, since there are no enum IDs created yet. When this endpoint returns, it will have IDs filled in for the `sku-properties` enums.
146
- * - With those IDs, update the default SKU with valid `sku-values` and create any additional SKUs (if needed), with valid `sku-values`.
147
- * - You can also create the Product without `sku-properties` and add them in later.
148
- * - If you add any `sku` properties, the default SKU will default to the first value of each option.
146
+ * Once, you've created a Product and its `sku-properties` with `enum` values, you can create your default SKU, which will automatically be a combination of the first `sku-properties` you've created. In our example, the default SKU will be a Royal Blue T-Shirt, because our first `enum` of our Color `sku-property` is Royal Blue. After you've created your product, you can create additional SKUs using the <a href="https://developers.webflow.com/reference/create-skus">Create SKU endpoint</a>
149
147
  *
150
- * Upon creation, the default product type will be `Advanced`. The product type is used to determine which Product and SKU fields are shown to users in the `Designer` and the `Editor`. Setting it to `Advanced` ensures that all Product and SKU fields will be shown. The product type can be edited in the `Designer` or the `Editor`.
148
+ * Upon creation, the default product type will be `Advanced`. The product type is used to determine which Product and SKU fields are shown to users in the `Designer` and the `Editor`. Setting it to `Advanced` ensures that all Product and SKU fields will be shown.
151
149
  *
152
150
  * Required scope | `ecommerce:write`
153
151
  * @throws {@link Webflow.BadRequestError}
@@ -159,59 +157,24 @@ class Products {
159
157
  * @throws {@link Webflow.InternalServerError}
160
158
  *
161
159
  * @example
162
- * await webflow.products.create("site-id", {
163
- * publishStatus: Webflow.PublishStatus.Staging,
164
- * product: {
165
- * id: "580e63fc8c9a982ac9b8b745",
166
- * lastPublished: new Date("2023-03-17T18:47:35.560Z"),
167
- * lastUpdated: new Date("2023-03-17T18:47:35.560Z"),
168
- * createdOn: new Date("2023-03-17T18:47:35.560Z"),
169
- * isArchived: false,
170
- * isDraft: false,
171
- * fieldData: {
172
- * name: "My new item",
173
- * slug: "my-new-item",
174
- * skuProperties: [{
175
- * id: "ff42fee0113744f693a764e3431a9cc2",
176
- * name: "Color",
177
- * enum: [{
178
- * id: "64a74715c456e36762fc39a1",
179
- * name: "Royal Blue",
180
- * slug: "royal-blue"
181
- * }]
182
- * }]
183
- * }
184
- * },
185
- * sku: {
186
- * id: "580e63fc8c9a982ac9b8b745",
187
- * lastPublished: new Date("2023-03-17T18:47:35.560Z"),
188
- * lastUpdated: new Date("2023-03-17T18:47:35.560Z"),
189
- * createdOn: new Date("2023-03-17T18:47:35.560Z"),
190
- * fieldData: {
191
- * name: "My new item",
192
- * slug: "my-new-item",
193
- * price: {
194
- * value: 100,
195
- * unit: "USD"
196
- * }
197
- * }
198
- * }
199
- * })
160
+ * await webflow.products.create("site_id", {})
200
161
  */
201
- create(siteId, request, requestOptions) {
162
+ create(siteId, request = {}, requestOptions) {
202
163
  var _a;
203
164
  return __awaiter(this, void 0, void 0, function* () {
204
165
  const _response = yield core.fetcher({
205
- url: (0, url_join_1.default)((_a = (yield core.Supplier.get(this._options.environment))) !== null && _a !== void 0 ? _a : environments.WebflowEnvironment.Default, `v2/sites/${siteId}/products`),
166
+ url: (0, url_join_1.default)((_a = (yield core.Supplier.get(this._options.environment))) !== null && _a !== void 0 ? _a : environments.WebflowEnvironment.Default, `sites/${siteId}/products`),
206
167
  method: "POST",
207
168
  headers: {
208
169
  Authorization: yield this._getAuthorizationHeader(),
209
170
  "X-Fern-Language": "JavaScript",
210
171
  "X-Fern-SDK-Name": "webflow-api",
211
- "X-Fern-SDK-Version": "2.0.0-beta",
172
+ "X-Fern-SDK-Version": "v2.1.1",
173
+ "X-Fern-Runtime": core.RUNTIME.type,
174
+ "X-Fern-Runtime-Version": core.RUNTIME.version,
212
175
  },
213
176
  contentType: "application/json",
214
- body: yield serializers.ProductsCreateRequest.jsonOrThrow(request, { unrecognizedObjectKeys: "strip" }),
177
+ body: yield serializers.ProductSkuCreate.jsonOrThrow(request, { unrecognizedObjectKeys: "strip" }),
215
178
  timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
216
179
  maxRetries: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries,
217
180
  });
@@ -275,19 +238,21 @@ class Products {
275
238
  * @throws {@link Webflow.InternalServerError}
276
239
  *
277
240
  * @example
278
- * await webflow.products.get("site-id", "product-id")
241
+ * await webflow.products.get("site_id", "product_id")
279
242
  */
280
243
  get(siteId, productId, requestOptions) {
281
244
  var _a;
282
245
  return __awaiter(this, void 0, void 0, function* () {
283
246
  const _response = yield core.fetcher({
284
- url: (0, url_join_1.default)((_a = (yield core.Supplier.get(this._options.environment))) !== null && _a !== void 0 ? _a : environments.WebflowEnvironment.Default, `v2/sites/${siteId}/products/${productId}`),
247
+ url: (0, url_join_1.default)((_a = (yield core.Supplier.get(this._options.environment))) !== null && _a !== void 0 ? _a : environments.WebflowEnvironment.Default, `sites/${siteId}/products/${productId}`),
285
248
  method: "GET",
286
249
  headers: {
287
250
  Authorization: yield this._getAuthorizationHeader(),
288
251
  "X-Fern-Language": "JavaScript",
289
252
  "X-Fern-SDK-Name": "webflow-api",
290
- "X-Fern-SDK-Version": "2.0.0-beta",
253
+ "X-Fern-SDK-Version": "v2.1.1",
254
+ "X-Fern-Runtime": core.RUNTIME.type,
255
+ "X-Fern-Runtime-Version": core.RUNTIME.version,
291
256
  },
292
257
  contentType: "application/json",
293
258
  timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
@@ -353,25 +318,46 @@ class Products {
353
318
  * @throws {@link Webflow.InternalServerError}
354
319
  *
355
320
  * @example
356
- * await webflow.products.update("site-id", "product-id", {
357
- * publishStatus: Webflow.PublishStatus.Staging,
321
+ * await webflow.products.update("site_id", "product_id", {
358
322
  * product: {
359
323
  * id: "580e63fc8c9a982ac9b8b745",
360
- * lastPublished: new Date("2023-03-17T18:47:35.560Z"),
361
- * lastUpdated: new Date("2023-03-17T18:47:35.560Z"),
362
- * createdOn: new Date("2023-03-17T18:47:35.560Z"),
324
+ * lastPublished: new Date("2023-03-17T18:47:35.000Z"),
325
+ * lastUpdated: new Date("2023-03-17T18:47:35.000Z"),
326
+ * createdOn: new Date("2023-03-17T18:47:35.000Z"),
363
327
  * isArchived: false,
364
328
  * isDraft: false,
365
329
  * fieldData: {
366
- * name: "My new item",
367
- * slug: "my-new-item",
330
+ * name: "T-Shirt",
331
+ * slug: "t-shirt",
332
+ * description: "A plain cotton t-shirt.",
333
+ * shippable: true,
368
334
  * skuProperties: [{
369
- * id: "ff42fee0113744f693a764e3431a9cc2",
335
+ * id: "color",
370
336
  * name: "Color",
371
337
  * enum: [{
372
- * id: "64a74715c456e36762fc39a1",
338
+ * id: "royal-blue",
373
339
  * name: "Royal Blue",
374
340
  * slug: "royal-blue"
341
+ * }, {
342
+ * id: "crimson-red",
343
+ * name: "Crimson Red",
344
+ * slug: "crimson-red"
345
+ * }, {
346
+ * id: "forrest-green",
347
+ * name: "Forrst Green",
348
+ * slug: "forrest-green"
349
+ * }, {
350
+ * id: "id",
351
+ * name: "name",
352
+ * slug: "slug"
353
+ * }]
354
+ * }, {
355
+ * id: "Color",
356
+ * name: "Color",
357
+ * enum: [{
358
+ * id: "id",
359
+ * name: "name",
360
+ * slug: "slug"
375
361
  * }]
376
362
  * }]
377
363
  * }
@@ -382,13 +368,15 @@ class Products {
382
368
  var _a;
383
369
  return __awaiter(this, void 0, void 0, function* () {
384
370
  const _response = yield core.fetcher({
385
- url: (0, url_join_1.default)((_a = (yield core.Supplier.get(this._options.environment))) !== null && _a !== void 0 ? _a : environments.WebflowEnvironment.Default, `v2/sites/${siteId}/products/${productId}`),
371
+ url: (0, url_join_1.default)((_a = (yield core.Supplier.get(this._options.environment))) !== null && _a !== void 0 ? _a : environments.WebflowEnvironment.Default, `sites/${siteId}/products/${productId}`),
386
372
  method: "PATCH",
387
373
  headers: {
388
374
  Authorization: yield this._getAuthorizationHeader(),
389
375
  "X-Fern-Language": "JavaScript",
390
376
  "X-Fern-SDK-Name": "webflow-api",
391
- "X-Fern-SDK-Version": "2.0.0-beta",
377
+ "X-Fern-SDK-Version": "v2.1.1",
378
+ "X-Fern-Runtime": core.RUNTIME.type,
379
+ "X-Fern-Runtime-Version": core.RUNTIME.version,
392
380
  },
393
381
  contentType: "application/json",
394
382
  body: yield serializers.ProductsUpdateRequest.jsonOrThrow(request, { unrecognizedObjectKeys: "strip" }),
@@ -457,20 +445,20 @@ class Products {
457
445
  * @throws {@link Webflow.InternalServerError}
458
446
  *
459
447
  * @example
460
- * await webflow.products.createSku("site-id", "product-id", {
461
- * publishStatus: Webflow.PublishStatus.Staging,
448
+ * await webflow.products.createSku("site_id", "product_id", {
462
449
  * skus: [{
463
450
  * id: "580e63fc8c9a982ac9b8b745",
464
- * lastPublished: new Date("2023-03-17T18:47:35.560Z"),
465
- * lastUpdated: new Date("2023-03-17T18:47:35.560Z"),
466
- * createdOn: new Date("2023-03-17T18:47:35.560Z"),
451
+ * lastPublished: new Date("2023-03-17T18:47:35.000Z"),
452
+ * lastUpdated: new Date("2023-03-17T18:47:35.000Z"),
453
+ * createdOn: new Date("2023-03-17T18:47:35.000Z"),
467
454
  * fieldData: {
468
- * name: "My new item",
469
- * slug: "my-new-item",
455
+ * name: "Blue T-shirt",
456
+ * slug: "t-shirt-blue",
470
457
  * price: {
471
458
  * value: 100,
472
459
  * unit: "USD"
473
- * }
460
+ * },
461
+ * quantity: 10
474
462
  * }
475
463
  * }]
476
464
  * })
@@ -479,13 +467,15 @@ class Products {
479
467
  var _a;
480
468
  return __awaiter(this, void 0, void 0, function* () {
481
469
  const _response = yield core.fetcher({
482
- url: (0, url_join_1.default)((_a = (yield core.Supplier.get(this._options.environment))) !== null && _a !== void 0 ? _a : environments.WebflowEnvironment.Default, `v2/sites/${siteId}/products/${productId}/skus`),
470
+ url: (0, url_join_1.default)((_a = (yield core.Supplier.get(this._options.environment))) !== null && _a !== void 0 ? _a : environments.WebflowEnvironment.Default, `sites/${siteId}/products/${productId}/skus`),
483
471
  method: "POST",
484
472
  headers: {
485
473
  Authorization: yield this._getAuthorizationHeader(),
486
474
  "X-Fern-Language": "JavaScript",
487
475
  "X-Fern-SDK-Name": "webflow-api",
488
- "X-Fern-SDK-Version": "2.0.0-beta",
476
+ "X-Fern-SDK-Version": "v2.1.1",
477
+ "X-Fern-Runtime": core.RUNTIME.type,
478
+ "X-Fern-Runtime-Version": core.RUNTIME.version,
489
479
  },
490
480
  contentType: "application/json",
491
481
  body: yield serializers.ProductsCreateSkuRequest.jsonOrThrow(request, { unrecognizedObjectKeys: "strip" }),
@@ -552,20 +542,20 @@ class Products {
552
542
  * @throws {@link Webflow.InternalServerError}
553
543
  *
554
544
  * @example
555
- * await webflow.products.updateSku("site-id", "product-id", "sku-id", {
556
- * publishStatus: Webflow.PublishStatus.Staging,
545
+ * await webflow.products.updateSku("site_id", "product_id", "sku_id", {
557
546
  * sku: {
558
547
  * id: "580e63fc8c9a982ac9b8b745",
559
- * lastPublished: new Date("2023-03-17T18:47:35.560Z"),
560
- * lastUpdated: new Date("2023-03-17T18:47:35.560Z"),
561
- * createdOn: new Date("2023-03-17T18:47:35.560Z"),
548
+ * lastPublished: new Date("2023-03-17T18:47:35.000Z"),
549
+ * lastUpdated: new Date("2023-03-17T18:47:35.000Z"),
550
+ * createdOn: new Date("2023-03-17T18:47:35.000Z"),
562
551
  * fieldData: {
563
- * name: "My new item",
564
- * slug: "my-new-item",
552
+ * name: "Blue T-shirt",
553
+ * slug: "t-shirt-blue",
565
554
  * price: {
566
555
  * value: 100,
567
556
  * unit: "USD"
568
- * }
557
+ * },
558
+ * quantity: 10
569
559
  * }
570
560
  * }
571
561
  * })
@@ -574,13 +564,15 @@ class Products {
574
564
  var _a;
575
565
  return __awaiter(this, void 0, void 0, function* () {
576
566
  const _response = yield core.fetcher({
577
- url: (0, url_join_1.default)((_a = (yield core.Supplier.get(this._options.environment))) !== null && _a !== void 0 ? _a : environments.WebflowEnvironment.Default, `v2/sites/${siteId}/products/${productId}/skus/${skuId}`),
567
+ url: (0, url_join_1.default)((_a = (yield core.Supplier.get(this._options.environment))) !== null && _a !== void 0 ? _a : environments.WebflowEnvironment.Default, `sites/${siteId}/products/${productId}/skus/${skuId}`),
578
568
  method: "PATCH",
579
569
  headers: {
580
570
  Authorization: yield this._getAuthorizationHeader(),
581
571
  "X-Fern-Language": "JavaScript",
582
572
  "X-Fern-SDK-Name": "webflow-api",
583
- "X-Fern-SDK-Version": "2.0.0-beta",
573
+ "X-Fern-SDK-Version": "v2.1.1",
574
+ "X-Fern-Runtime": core.RUNTIME.type,
575
+ "X-Fern-Runtime-Version": core.RUNTIME.version,
584
576
  },
585
577
  contentType: "application/json",
586
578
  body: yield serializers.ProductsUpdateSkuRequest.jsonOrThrow(request, { unrecognizedObjectKeys: "strip" }),