Skip to content

Conversation

@waleedlatif1
Copy link
Collaborator

Summary

  • added collection, item, & site selectors for webflow

Type of Change

  • New feature

Testing

Tested manually

Checklist

  • Code follows project style guidelines
  • Self-reviewed my changes
  • Tests added/updated and passing
  • No new warnings introduced
  • I confirm that I have read and agree to the terms outlined in the Contributor License Agreement (CLA)

@vercel
Copy link

vercel bot commented Dec 14, 2025

The latest updates on your projects. Learn more about Vercel for GitHub.

1 Skipped Deployment
Project Deployment Review Updated (UTC)
docs Skipped Skipped Dec 14, 2025 3:05am

@greptile-apps
Copy link
Contributor

greptile-apps bot commented Dec 14, 2025

Greptile Overview

Greptile Summary

This PR adds comprehensive UI selectors for Webflow integration, enabling users to select sites, collections, and items through dropdown menus instead of manually entering IDs.

Key Changes:

  • Added three new selector types (webflow.sites, webflow.collections, webflow.items) to the selector registry with proper dependency chains
  • Converted API routes from GET to POST with improved credential authorization using authorizeCredentialUse and token refresh
  • Created new /api/tools/webflow/items endpoint for fetching collection items
  • Extended WebflowBaseParams to include siteId as a required parameter across all Webflow tools
  • Updated block configuration with both basic (selector dropdowns) and advanced (manual ID input) modes for site, collection, and item selection
  • Added proper validation in the params handler to ensure required IDs are present before operations
  • Updated documentation to reflect the new siteId requirement

Architecture:
The implementation follows the existing selector pattern used by other integrations (Jira, Linear, etc.) with cascading dependencies: credential → site → collection → item.

Confidence Score: 5/5

  • This PR is safe to merge - well-structured feature addition with proper authorization, validation, and follows existing patterns.
  • The code follows established patterns from other integrations (Jira, Linear), implements proper authorization via authorizeCredentialUse, includes comprehensive validation, and the previous siteId issue has been resolved per the thread.
  • No files require special attention.

Important Files Changed

File Analysis

Filename Score Overview
apps/sim/blocks/blocks/webflow.ts 5/5 Added site, collection, and item selectors with both basic (dropdown) and advanced (manual ID) modes. Proper validation and parameter handling for all Webflow operations.
apps/sim/hooks/selectors/registry.ts 5/5 Added three new selectors (webflow.sites, webflow.collections, webflow.items) with proper query key management and dependency handling.
apps/sim/app/api/tools/webflow/sites/route.ts 5/5 Changed from GET to POST, added proper credential authorization using authorizeCredentialUse and token refresh.
apps/sim/app/api/tools/webflow/collections/route.ts 5/5 Changed from GET to POST, added proper credential authorization and requires siteId to fetch collections.
apps/sim/app/api/tools/webflow/items/route.ts 5/5 New API endpoint to fetch Webflow items from a collection with client-side search filtering.
apps/sim/tools/webflow/types.ts 5/5 Added siteId to WebflowBaseParams, affecting all Webflow tool types.

Sequence Diagram

sequenceDiagram
    participant User
    participant Selector as UI Selectors
    participant Routes as API Routes
    participant Webflow

    User->>Selector: Pick credential
    Selector->>Routes: Fetch sites
    Routes->>Webflow: List sites
    Webflow-->>Routes: Sites data
    Routes-->>Selector: Formatted sites

    User->>Selector: Pick site
    Selector->>Routes: Fetch collections
    Routes->>Webflow: List collections for site
    Webflow-->>Routes: Collections data
    Routes-->>Selector: Formatted collections

    User->>Selector: Pick collection
    Selector->>Routes: Fetch items
    Routes->>Webflow: List items for collection
    Webflow-->>Routes: Items data
    Routes-->>Selector: Formatted items
Loading

Copy link
Contributor

@greptile-apps greptile-apps bot left a comment

Choose a reason for hiding this comment

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

Additional Comments (1)

  1. apps/sim/app/workspace/[workspaceId]/w/[workflowId]/components/panel/components/editor/components/sub-block/components/project-selector/project-selector-input.tsx, line 46-53 (link)

    style: Dead code: isLinear, linearCredential, and jiraCredential are no longer used after the credential resolution simplification.

10 files reviewed, 1 comment

Edit Code Review Agent Settings | Greptile

@waleedlatif1
Copy link
Collaborator Author

@greptile

Copy link
Contributor

@greptile-apps greptile-apps bot left a comment

Choose a reason for hiding this comment

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

17 files reviewed, 1 comment

Edit Code Review Agent Settings | Greptile

@waleedlatif1
Copy link
Collaborator Author

@greptile

Copy link
Contributor

@greptile-apps greptile-apps bot left a comment

Choose a reason for hiding this comment

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

17 files reviewed, no comments

Edit Code Review Agent Settings | Greptile

@waleedlatif1 waleedlatif1 merged commit c962e3b into staging Dec 14, 2025
10 checks passed
@waleedlatif1 waleedlatif1 deleted the feat/webflow branch December 14, 2025 03:14
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.

2 participants