Skip to main content
Glama
webflow

Webflow

Official
by webflow

collections_items_update_items

Update existing items in Webflow CMS collections as drafts to modify content before publishing changes.

Instructions

Update existing items in a CMS collection as drafts.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
collection_idYesUnique identifier for the Collection.
requestYes

Implementation Reference

  • The inline handler function for the 'collections_items_update_items' tool. It calls the Webflow API's updateItems method to update collection items as drafts and formats the response or error.
    async ({ collection_id, request }) => {
      try {
        const response = await getClient().collections.items.updateItems(
          collection_id,
          request,
          requestOptions
        );
        return formatResponse(response);
      } catch (error) {
        return formatErrorResponse(error);
      }
    }
  • Registers the 'collections_items_update_items' tool on the MCP server, specifying its title, description, input schema, and inline handler function.
      "collections_items_update_items",
      {
        title: "Update Collection Items",
        description: "Update existing items in a CMS collection as drafts.",
        inputSchema: z.object({
          collection_id: z
            .string()
            .describe("Unique identifier for the Collection."),
          request: WebflowCollectionsItemsUpdateItemsRequestSchema,
        }),
      },
      async ({ collection_id, request }) => {
        try {
          const response = await getClient().collections.items.updateItems(
            collection_id,
            request,
            requestOptions
          );
          return formatResponse(response);
        } catch (error) {
          return formatErrorResponse(error);
        }
      }
    );
  • Zod schema defining the structure of the request body for updating collection items, consisting of an optional array of items each with an ID and field data.
    export const WebflowCollectionsItemsUpdateItemsRequestSchema = z.object({
      items: z.array(CollectionItemWithIdInputSchema).optional(),
    });

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/webflow/mcp-server'

If you have feedback or need assistance with the MCP directory API, please join our Discord server