KS
Killer-Skills

collection — how to use collection in Momentum CMS how to use collection in Momentum CMS, what is collection in Momentum CMS, collection setup guide, Momentum CMS collection alternative, collection vs custom data models, install collection in Momentum CMS, collection best practices for developers

v1.0.0
GitHub

About this Skill

Perfect for Developer Agents needing standardized collection creation for Momentum CMS Collection is a Momentum CMS feature that allows developers to create and manage data collections, defined in the libs/example-config/src/collections directory.

Features

Creates a new collection file at libs/example-config/src/collections/
Follows Momentum CMS project conventions for collection naming and location
Supports importing collections from @momentumcms/example-config/collections
Defines collections in a centralized location, avoiding individual app definitions
Uses the $ARGUMENTS variable to specify the collection name, such as posts or products

# Core Topics

DonaldMurillo DonaldMurillo
[0]
[0]
Updated: 3/7/2026

Quality Score

Top 5%
48
Excellent
Based on code quality & docs
Installation
SYS Universal Install (Auto-Detect)
Cursor IDE Windsurf IDE VS Code IDE
> npx killer-skills add DonaldMurillo/momentum-cms/collection

Agent Capability Analysis

The collection MCP Server by DonaldMurillo is an open-source Categories.community integration for Claude and other AI agents, enabling seamless task automation and capability expansion. Optimized for how to use collection in Momentum CMS, what is collection in Momentum CMS, collection setup guide.

Ideal Agent Persona

Perfect for Developer Agents needing standardized collection creation for Momentum CMS

Core Value

Empowers agents to generate new collection files following project conventions, utilizing Momentum CMS and importing from @momentumcms/example-config/collections, while adhering to specific collection locations like libs/example-config/src/collections/

Capabilities Granted for collection MCP Server

Generating new collection files for Momentum CMS projects
Standardizing collection creation across multiple example apps
Automating collection imports from @momentumcms/example-config/collections

! Prerequisites & Limits

  • Collections must be defined in libs/example-config/src/collections/
  • Individual apps should not define collections
  • Requires adherence to Momentum CMS project conventions
Project
SKILL.md
3.3 KB
.cursorrules
1.2 KB
package.json
240 B
Ready
UTF-8

# Tags

[No tags]
SKILL.md
Readonly

Generate Momentum CMS Collection

Create a new collection file following project conventions.

Arguments

  • $ARGUMENTS - Collection name (e.g., "posts", "products", "users")

Important: Collection Location

All collections are defined in libs/example-config/src/collections/. Both example apps (example-angular, example-analog) import from @momentumcms/example-config/collections. Never define collections in individual apps.

Steps

  1. Create the collection file at libs/example-config/src/collections/<name>.collection.ts

  2. Use this template:

typescript
1import { 2 defineCollection, 3 text, 4 richText, 5 number, 6 date, 7 checkbox, 8 select, 9 relationship, 10} from '@momentumcms/core'; 11 12export const <PascalName> = defineCollection({ 13 slug: '<kebab-name>', 14 15 admin: { 16 useAsTitle: 'title', // or 'name' - the field to display as title 17 defaultColumns: ['title', 'createdAt'], 18 group: 'Content', // Admin sidebar group 19 }, 20 21 access: { 22 read: () => true, 23 create: ({ req }) => !!req.user, 24 update: ({ req }) => req.user?.role === 'admin', 25 delete: ({ req }) => req.user?.role === 'admin', 26 }, 27 28 hooks: { 29 beforeChange: [], 30 afterChange: [], 31 }, 32 33 fields: [ 34 text('title', { required: true }), 35 // Add more fields as needed 36 ], 37});
  1. Export from libs/example-config/src/collections/index.ts:
typescript
1// Add import at top 2import { <PascalName> } from './<name>.collection'; 3 4// Add to the collections array 5export const collections: CollectionConfig[] = [ 6 // ... existing collections, 7 <PascalName>, 8]; 9 10// Add to named exports 11export { 12 // ... existing exports, 13 <PascalName>, 14};

Both example apps automatically pick up changes since they import from @momentumcms/example-config/collections.

  1. Remind user: if migration mode is enabled, run nx run <app>:migrate:generate after collection changes to create a migration file.

Field Types Available

Text Input Fields

  • text(name, options) - Short text with optional min/max length
  • textarea(name, options) - Multi-line text with optional rows
  • richText(name, options) - Rich text editor
  • email(name, options) - Email input
  • password(name, options) - Password input with optional min length

Numeric & Date Fields

  • number(name, options) - Numeric value with optional min/max/step
  • date(name, options) - Date/datetime picker

Boolean & Selection Fields

  • checkbox(name, options) - Boolean checkbox
  • select(name, { options: [...] }) - Dropdown select (supports hasMany)
  • radio(name, { options: [...] }) - Radio button group

Media & Files

  • upload(name, options) - File upload with MIME type filtering

Relationship & Data Fields

  • relationship(name, { collection: () => Ref }) - Reference to another collection (supports hasMany, polymorphic)
  • array(name, { fields: [...] }) - Array of nested fields
  • group(name, { fields: [...] }) - Nested object grouping
  • blocks(name, { blocks: [...] }) - Block-based content
  • json(name, options) - Raw JSON field
  • point(name, options) - Geolocation point
  • slug(name, { from: 'fieldName' }) - Auto-generated slug from another field

Layout Fields (non-data storing)

  • tabs(tabs: [...]) - Tabbed sections for organization
  • collapsible(label, { fields: [...] }) - Collapsible section
  • row(fields: [...]) - Horizontal row layout

Related Skills

Looking for an alternative to collection or building a Categories.community AI Agent? Explore these related open-source MCP Servers.

View All

widget-generator

Logo of f
f

widget-generator is an open-source AI agent skill for creating widget plugins that are injected into prompt feeds on prompts.chat. It supports two rendering modes: standard prompt widgets using default PromptCard styling and custom render widgets built as full React components.

149.6k
0
Design

chat-sdk

Logo of lobehub
lobehub

chat-sdk is a unified TypeScript SDK for building chat bots across multiple platforms, providing a single interface for deploying bot logic.

73.0k
0
Communication

zustand

Logo of lobehub
lobehub

The ultimate space for work and life — to find, build, and collaborate with agent teammates that grow with you. We are taking agent harness to the next level — enabling multi-agent collaboration, effortless agent team design, and introducing agents as the unit of work interaction.

72.8k
0
Communication

data-fetching

Logo of lobehub
lobehub

The ultimate space for work and life — to find, build, and collaborate with agent teammates that grow with you. We are taking agent harness to the next level — enabling multi-agent collaboration, effortless agent team design, and introducing agents as the unit of work interaction.

72.8k
0
Communication