Actions26
- Block Actions
- Collection Actions
- Daily Note Actions
- Document Actions
- Folder Actions
- Task Actions
Collection → Get Collection Schema
AI-generatedSummary
Retrieve the schema definition of a specified Craft collection to understand its data structure and validation rules.
Inputs
- Collection (required) — Select or enter the collection ID obtained from the GET /collections endpoint, either by choosing from a list of collections or entering the ID manually.
- Schema Options — Specify the schema format to return: either 'JSON Schema Items' for validation schema of the collection's items (default) or 'Schema Structure' for the editable schema layout.
Output shape
a JSON object containing the schema of the specified collection in the chosen format.
The output schema format depends on the selected 'Format' option; by default, it returns item validation schemas. Errors result in node execution failure unless 'Continue on Fail' is enabled.
Examples
Example 1: Retrieve the JSON schema for items in a selected collection
Set the Collection parameter to a valid collection identifier. Leave 'Format' as the default 'JSON Schema Items'. The output JSON provides validation details for items in that collection.
Example 2: Retrieve the editable schema structure of a collection
Set the Collection parameter to a valid collection ID. Set 'Format' to 'Schema Structure'. The output JSON represents the editable structure of the collection's schema.