js-webflow-api icon indicating copy to clipboard operation
js-webflow-api copied to clipboard

updateItem not working

Open gitinthehole opened this issue 6 months ago • 3 comments

Hi there, We're trying to update an item but we keep getting an error: An error occurred while updating item in Webflow collection JsonError: Missing required key "id"

Our code is as follows

console.info(`itemId:`, itemId)
const updatedItem = await webflow.collections.items.updateItem(process.env.WEBFLOW_COLLECTION_ID, itemId, itemInfo)
console.info(`updatedItem:`, updatedItem)

We've verified that itemId is valid.

Please advise. Thanks much in advance.

gitinthehole avatar Aug 07 '24 12:08 gitinthehole