Reject a submitted template with a note
Marks a submitted template as `rejected` and stores the reviewer's `note`, from which the author may edit and resubmit; the note is deliberately kept out of the workspace event ledger. Requires `templates:curate` in the owning workspace, and only a template currently in `submitted` may be rejected. Send an `Idempotency-Key` header to make retries safe; a replay within the window returns the original response.
Authorization
apiKey Workspace API key created in Workspace settings → API keys. Scopes on the key bound what it can read and write.
In: header
Path Parameters
Request Body
application/json
TypeScript Definitions
Use the request body type in TypeScript.
Response Body
application/json
application/json
application/json
curl -X POST "https://example.com/v1/workspaces/string/templates/string/reject" \ -H "Content-Type: application/json" \ -d '{ "note": "string" }'{ "data": { "id": "string", "workspaceId": "string", "name": "string", "description": "string", "cover": "string", "icon": "string", "kind": "folder", "sourceItemId": "string", "scope": "builtin", "visibility": "private", "reviewStatus": "draft", "installCount": 0, "author": { "workspaceId": "string", "name": "string", "icon": "string" }, "category": "string", "tags": [ "string" ], "inputs": [ { "id": "string", "kind": "database", "label": "string", "description": "string", "placeholder": "string", "required": true, "dependsOn": "string", "choices": [ { "value": "string", "label": "string" } ], "default": "string" } ], "version": 0, "manifest": { "version": 2, "inputs": [ { "id": "string", "kind": "database", "label": "string", "description": "string", "placeholder": "string", "required": true, "dependsOn": "string", "choices": [ { "value": "string", "label": "string" } ], "default": "string" } ], "rootSourceItemId": "string", "rootKind": "folder", "operations": [ { "type": "item.create", "sourceItemId": "string", "parentSourceItemId": "string", "title": "string", "icon": "string", "color": "string", "order": 0, "accessMode": "open", "locked": true, "archived": true, "metadata": {}, "kind": "folder", "sourceTargetId": "string" } ] }, "publishedAt": "string", "curatedAt": "string", "submittedAt": "string", "reviewNote": "string", "createdBy": "string", "createdAt": "string", "updatedAt": "string" }}{ "_tag": "ApiNotFound", "error": "not_found", "message": "That item does not exist, or this key cannot see it.", "status": 404}{ "_tag": "ApiNotFound", "error": "not_found", "message": "That item does not exist, or this key cannot see it.", "status": 404}Approve a submitted template
Marks a submitted template as `approved`, clearing its review note so the author can publish it. Requires `templates:curate` in the owning workspace, and only a template currently in `submitted` may be approved. Send an `Idempotency-Key` header to make retries safe; a replay within the window returns the original response.
Withdraw a template from the store
Returns a published template to workspace-only visibility and drops any curation, since the gallery reads curation through visibility. Accepts either `templates:publish` or `templates:curate` in the owning workspace, as there is no platform-wide curator role yet. Send an `Idempotency-Key` header to make retries safe; a replay within the window returns the original response.