Publish a template document, or import a public catalog slug
Store a template document for this org (the kernel validates its schema and every `{{name}}` reference; a republish of the same slug bumps its version), or import a slug from the public catalog (cueframe-ai/cueframe-templates) as this org's copy. The document is capped at 1 MiB. With `dryRun: true` nothing is stored: the answer is 200 with the kernel's problems as data, for the document alone or, when `values`, `media` or `preset` are given, for those inputs bound against this org's media rows.
API key auth. Prefix cf_live_ for production orgs, cf_test_ for sandbox.
In: header
Request Body
application/json
TypeScript Definitions
Use the request body type in TypeScript.
Response Body
application/json
application/json
application/json
application/json
application/json
application/json
application/json
application/json
application/json
application/json
application/json
application/json
curl -X POST "https://example.com/v1/templates" \ -H "Content-Type: application/json" \ -d '{ "document": { "property1": null, "property2": null } }'{ "ok": true, "slug": "string", "problems": [ { "code": "string", "param": "string", "message": "string" } ]}{ "id": "string", "slug": "string", "name": "string", "version": -9007199254740991, "documentSha256": "string", "fromCatalog": true, "document": { "property1": null, "property2": null }, "createdAt": "string", "updatedAt": "string"}{ "error": { "code": "string", "message": "string", "contract": "string", "contractVersion": "string", "details": { "property1": null, "property2": null } }}{ "error": { "code": "string", "message": "string", "contract": "string", "contractVersion": "string", "details": { "property1": null, "property2": null } }}{ "x402Version": 2, "accepts": [ {} ], "error": "string"}{ "error": { "code": "string", "message": "string", "contract": "string", "contractVersion": "string", "details": { "property1": null, "property2": null } }}{ "error": { "code": "string", "message": "string", "contract": "string", "contractVersion": "string", "details": { "property1": null, "property2": null } }}{ "error": { "code": "string", "message": "string", "contract": "string", "contractVersion": "string", "details": { "property1": null, "property2": null } }}{ "error": { "code": "string", "message": "string", "contract": "string", "contractVersion": "string", "details": { "property1": null, "property2": null } }}{ "error": { "code": "string", "message": "string", "contract": "string", "contractVersion": "string", "details": { "property1": null, "property2": null } }}{ "error": { "code": "string", "message": "string", "contract": "string", "contractVersion": "string", "details": { "property1": null, "property2": null } }}{ "error": { "code": "string", "message": "string", "contract": "string", "contractVersion": "string", "details": { "property1": null, "property2": null } }}