$npx -y skills add webflow/webflow-skills --skill cms-collection-setupCreate a new CMS collection in Webflow with specified fields and relationships. Use when setting up blog posts, products, team members, portfolios, or other content types with custom fields.
| 1 | # CMS Collection Setup |
| 2 | |
| 3 | Create a new CMS collection with custom fields, relationships, and proper configuration. |
| 4 | |
| 5 | ## Important Note |
| 6 | |
| 7 | **ALWAYS use Webflow MCP tools for all operations:** |
| 8 | - Use Webflow MCP's `webflow_guide_tool` to get best practices before starting |
| 9 | - Use Webflow MCP's `data_sites_tool` with action `list_sites` to identify available sites |
| 10 | - Use Webflow MCP's `data_sites_tool` with action `get_site` to retrieve site details and plan limits |
| 11 | - Use Webflow MCP's `data_cms_tool` with action `get_collection_list` to check for naming conflicts |
| 12 | - Use Webflow MCP's `data_cms_tool` with action `create_collection` to create the collection |
| 13 | - Use Webflow MCP's `data_cms_tool` with action `create_collection_static_field` to create static fields |
| 14 | - Use Webflow MCP's `data_cms_tool` with action `create_collection_option_field` to create option fields |
| 15 | - Use Webflow MCP's `data_cms_tool` with action `create_collection_reference_field` to create reference/multi-reference fields |
| 16 | - Use Webflow MCP's `data_cms_tool` with action `get_collection_details` to verify collection was created correctly |
| 17 | - DO NOT use any other tools or methods for Webflow operations |
| 18 | - All tool calls must include the required `context` parameter (15-25 words, third-person perspective) |
| 19 | |
| 20 | ## Instructions |
| 21 | |
| 22 | ### Phase 1: Site Selection & Discovery |
| 23 | 1. **Get site information**: Use Webflow MCP's `data_sites_tool` with action `list_sites` to identify target site |
| 24 | 2. **Confirm site**: Ask user to select site if multiple available |
| 25 | 3. **Check plan limits**: Use Webflow MCP's `data_sites_tool` with action `get_site` to verify collection limits |
| 26 | 4. **List existing collections**: Use Webflow MCP's `data_cms_tool` with action `get_collection_list` to check for conflicts |
| 27 | 5. **Validate naming**: Ensure new collection name doesn't conflict with existing |
| 28 | |
| 29 | ### Phase 2: Requirements Gathering |
| 30 | 6. **Get collection details**: Ask user for: |
| 31 | - Collection display name (e.g., "Blog Posts") |
| 32 | - Singular name (e.g., "Blog Post") |
| 33 | - Optional: Custom slug (default: auto-generated from display name) |
| 34 | 7. **Get field definitions**: For each field, gather: |
| 35 | - Field name (e.g., "Author Name", "Publish Date") |
| 36 | - Field type (Text, Rich Text, Image, Option, Reference, etc.) |
| 37 | - Required vs optional |
| 38 | - Any validation rules or help text |
| 39 | 8. **Identify relationships**: Determine if collection needs: |
| 40 | - Reference fields (one-to-many relationships) |
| 41 | - Multi-reference fields (many-to-many relationships) |
| 42 | - Option fields (controlled vocabulary) |
| 43 | |
| 44 | ### Phase 3: Schema Validation & Planning |
| 45 | 9. **Validate field types**: Check all field types are supported |
| 46 | 10. **Check field limits**: Ensure within Webflow limits: |
| 47 | - Max fields per collection: varies by plan |
| 48 | - Max 5 multi-reference fields per collection |
| 49 | 11. **Plan creation order**: Organize fields by dependency: |
| 50 | - Create collections in order if references exist |
| 51 | - Create referenced collections first |
| 52 | - Create option fields before reference fields |
| 53 | 12. **Generate preview**: Show complete schema with all fields |
| 54 | |
| 55 | ### Phase 4: User Approval |
| 56 | 13. **Show complete preview**: Display: |
| 57 | - Collection name and slug |
| 58 | - All fields with types and properties |
| 59 | - Any relationships to other collections |
| 60 | - Plan limit verification |
| 61 | 14. **Validate schema**: Check for common issues: |
| 62 | - Missing required fields (name, slug always required) |
| 63 | - Invalid field types |
| 64 | - Reference to non-existent collections |
| 65 | - Exceeding plan limits |
| 66 | 15. **Request confirmation**: Wait for explicit "create" approval |
| 67 | |
| 68 | ### Phase 5: Collection Creation |
| 69 | 16. **Create collection**: Use Webflow MCP's `data_cms_tool` with action `create_collection` with: |
| 70 | - Display name |
| 71 | - Singular name |
| 72 | - Optional slug |
| 73 | 17. **Capture collection ID**: Save for field creation |
| 74 | 18. **Show progress**: Report collection created successfully |
| 75 | |
| 76 | ### Phase 6: Field Creation |
| 77 | 19. **Create fields in order**: For each field: |
| 78 | - Use appropriate creation tool based on type |
| 79 | - Static fields: `data_cms_tool` with action `create_collection_static_field` |
| 80 | - Option fields: `data_cms_tool` with action `create_collection_option_field` |
| 81 | - Reference fields: `data_cms_tool` with action `create_collection_reference_field` |
| 82 | 20. **Set field properties**: |
| 83 | - Display name |
| 84 | - Required flag |
| 85 | - Help text (if provided) |
| 86 | - Validation rules (if applicable) |
| 87 | 21. **Show progress**: Report each field created |
| 88 | 22. **Handle errors**: If field creation fails, report and continue |
| 89 | |
| 90 | ### Phase 7: Verification & Reporting |
| 91 | 23. **Verify collection**: Use Webflow MCP's `data_cms_tool` with action `get_collection_details` to retrieve full schema |
| 92 | 24. **Confirm all fields**: Check that all requested fields were created |
| 93 | 25. **Generate report**: |