Core ConceptsContent Types4 min read
Content Types
Content types define the structure of your content. Think of them as templates.
Creating a Content Type
- Navigate to Content Types in your project
- Click Create Content Type
- Enter a name (e.g., "Blog Post")
- The API ID is auto-generated (e.g.,
blogPost) - Add an optional description
- Click Create
Adding Fields
Each content type needs fields to store data:
- Click Add Field on your content type
- Select a field type (see below)
- Configure the field settings
- Click Save
Field Types
| Type | Description | Example Use |
|---|---|---|
| Text | Short text, single line | Title, name |
| Rich Text | Formatted text (WYSIWYG, stored as HTML) | Article body, bio |
| Markdown | Markdown source with toolbar + live preview | Docs, READMEs |
| Number | Integer or decimal | Price, quantity |
| Boolean | True/false toggle | Featured, active |
| Date | Date only (no time) | Birth date, event date |
| DateTime | Date with time | Publish date, timestamp |
| Time | Time of day (no date) | Opening hours |
| Validated email address | Author email | |
| URL | Validated web address | External link |
| Phone | Phone number | Contact number |
| Color | Color value (hex / rgba) | Theme color, label color |
| Slug | URL-friendly identifier | Page URL path |
| Select | Single choice from fixed options | Category, status |
| Multi-Select | Multiple choices from fixed options | Features, permissions |
| Tags | Free-form list of tags (any value) | Keywords, labels |
| Code | Code snippet with language selection | Embed snippets |
| Component | Group of nested fields, optionally repeatable | Hero block, FAQ list |
| Media | File upload reference | Hero image, documents |
| Reference | Link to another entry | Author, related posts |
| JSON | Flexible JSON data | Custom metadata |
| Location | Geographic coordinate { lat, lng, label? } | Store location, venue |
| Rating | Integer rating from 1 to a configurable max | Review score |
| Duration | Length of time, stored as whole seconds | Video length, run time |
| Money | Amount with ISO 4217 currency { amount, currency } | Price, budget |
| Address | Structured postal address (street, city, region, …) | Contact address |
| Date Range | Start and end dates { start, end } | Event window, promotion |
| Range | Numeric min/max { min, max } | Price range, capacity |
| Embed | Embeddable URL { url, provider?, title? } | YouTube/Vimeo video |
Location fields power geospatial queries — see the
$nearfilter in the Content Delivery API for radius / "near me" search.
Notes on specific types
- Markdown vs Rich Text — Rich Text uses a WYSIWYG editor and stores HTML; Markdown stores the raw Markdown you type (delivered verbatim by the API), so it round-trips losslessly. Choose Markdown when authors work in Markdown.
- Tags vs Multi-Select — Multi-Select restricts choices to a fixed option list; Tags lets editors enter any value (with optional autocomplete suggestions).
- Select / Multi-Select options — configure the choices in
settings.optionsas an array of{ label, value }objects — plain strings such as["Draft", "Published"]are rejected.labelis shown in the editor;valueis stored and returned by the API. For example:{ "options": [{ "label": "Draft", "value": "draft" }, { "label": "Published", "value": "published" }] }. - Code — stored as
{ code, language }; the API exposes it as aCodeBlockGraphQL type. Configure the available languages on the field. - Component — define the nested sub-fields on the field; enable Repeatable to let editors add multiple instances (e.g. an FAQ list). Sub-fields can be any type except Component (no nested components).
Field Settings
Each field can be configured with:
- Required: Must have a value
- Unique: No duplicate values allowed
- Localized: Different values per language (when enabled)
- Validation: Min/max length, patterns, ranges
Content Type Options
When creating a content type, you can choose:
- Collection: Multiple entries (e.g., blog posts, products)
- Single: Only one entry allowed (e.g., homepage, site settings)
Example: Blog Post Content Type
Text
Blog Post (Collection)
├── title (Text, required)
├── slug (Slug, required, unique)
├── content (Rich Text, required)
├── excerpt (Text, max 200 chars)
├── featuredImage (Media)
├── author (Reference → Author)
├── publishedAt (DateTime)
├── tags (Multi-Select)
└── featured (Boolean)Example: Site Settings (Singleton)
Text
Site Settings (Single)
├── siteName (Text, required)
├── tagline (Text)
├── logo (Media)
├── socialLinks (JSON)
└── maintenanceMode (Boolean)Editing Content Types
- Navigate to Content Types
- Click on the content type you want to edit
- Add, remove, or modify fields as needed
- Click Save
Note: Some changes (like removing fields) may affect existing content entries.
Deleting Content Types
Warning: This will delete all entries of this type.
- Navigate to Content Types
- Click the menu icon (⋮) on the content type
- Select Delete
- Confirm the deletion