Skip to content

Conversation

@viratatwebflow
Copy link
Collaborator

Similar to DE Tools, this PR introduces updates to Data Tools. Instead of maintaining separate tools for each Data API, we’ve consolidated them by type. For example, the site tool can now be used to list sites, publish, or get site details.

jamesmosier and others added 23 commits September 11, 2025 15:47
docs: Add Designer MCP Installation Instructions
docs: update setup instructions for Webflow MCP Bridge App
revise Cursor config for official remote MCP support
Duplication instruction removed
Local Installation Documentation
Added TypeScript types for text and image content, along with a unified ToolResponse type. Introduced utility functions for creating text and image content, and for formatting tool responses. This improves type safety and clarity in handling different response formats.
Copy link
Collaborator

@zmcnellis zmcnellis left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Made a pass through the consolidation changes and overall looks good!

);
return formatResponse(response);
for (const action of actions) {
if (action.list_components) {
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

might be cleaner as a switch statement?

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks for pointing that out. A switch-case isn’t ideal for this pattern since it can’t handle multiple operations per action. However, I’ve removed the else if chain that was preventing other properties from being checked. I fixed it by switching to independent if statements instead, this way, all properties are properly evaluated.

ComponentPropertyUpdateSchema
} from "../schemas";
import { formatErrorResponse, formatResponse } from "../utils";
import { Content, formatErrorResponse, textContent, toolResponse } from "../utils";
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
import { Content, formatErrorResponse, textContent, toolResponse } from "../utils";
import { type Content, formatErrorResponse, textContent, toolResponse } from "../utils";

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Done!

Updated the CMS tool to enhance TypeScript type definitions for function arguments and responses, ensuring better clarity and maintainability. Consolidated import statements and improved formatting for better readability. This refactor aligns with recent updates across other tools for a unified codebase.
@viratatwebflow viratatwebflow merged commit 51f7fff into sai Oct 22, 2025
6 checks passed
@viratatwebflow viratatwebflow deleted the data-tool-consolidation branch October 22, 2025 16:21
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants