⚠️ Work in progress — createCMS is pre-1.0 and not production-ready (not tested in production). Expect breaking changes.
createCMS
Reference

Templates

Per-property default values, via cms.api.templates.

A template is a default value for a block property in a given collection and block type. Template strings can contain {{key}} variables, resolved when applied. Templates are keyed by (collection, blockType, propertyKey). Methods live under cms.api.templates.

MethodHTTPInputReturns
listTemplatesGETquery: { collection?, blockType? }{ templates }
getTemplateGETquery: { id }{ template }
createTemplatePOSTbody: { collection, blockType, propertyKey, template, description? }{ template }
updateTemplatePOSTbody: { id, template?, description? }{ template }
deleteTemplatePOSTbody: { id }{ deleted }
resolveTemplatePOSTbody: { template }{ resolved }
getTemplateDefaultsGETquery: { collection, blockType }{ defaults }

Creating a duplicate (collection, blockType, propertyKey) throws TEMPLATE_KEY_EXISTS.