riddleTemplate_get
Reads a single template, by default INCLUDING its build configuration - the same "build" shape riddle_get returns and the riddle_builder_ tools accept. This is how a template is adapted rather than copied: edit the returned "build" (change the wording, swap questions, add or remove blocks) and build it with the riddle_builder_ tool of the template's "type", passing this template's id as "templateId" so the new Riddle is still recorded as coming from it. The design comes along too: "preset" carries the template's preset settings and its palette; "preset.paletteValues" - what that palette looks like - is included whenever the palette is not an unmodified built-in one, so a custom (or customized built-in) palette rebuilds into the same design directly. A template still on an unmodified built-in palette has no "paletteValues" instead of a partial one - "preset.palette" already names it in full (e.g. "Forest"), and its actual colors/fonts/etc. come from the riddle://reference/palette/built-in-palettes resource (match by "name"), never from a silently missing key. Passing "templateId" additionally starts the new Riddle out on the template's whole preset - layout included - with your build config applied on top of it. If you are not changing anything, use riddleTemplate_use instead - it is one call and copies the template as a whole. Returns {id, title, type, category, isPublic, isQuickCreate, blocksCount, image, icon, createdAt, riddle, build, nextBlockId, warnings}; a template whose content has no build-configuration equivalent comes back with an empty "build" and a warning saying so - use riddleTemplate_use for those.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| id | Yes | The ID of the template, as returned by riddleTemplate_list or riddleTemplate_publicList. | |
| omit | No | Leaves parts of the response out. The only value with anything to leave out here is "build.omittedDefaults": every block then loses its "omittedDefaults" map (the properties left out for still being at their default, with the value each one is at), for a much smaller response. Nothing is lost by it: the same defaults are stated in riddle://reference/riddle-defaults/<riddle type> and riddle://reference/block-defaults/<block type> - and a value read there must not be resent as the property either way. Same parameter as riddle_get's; its section values do not apply here, this envelope has no such sections. | |
| includeBuildConfig | No | Whether to read the template as a build configuration. Defaults to true, which is the point of this tool; false returns only the template's metadata, a far smaller response. |