Use when implementing or debugging NocoBase 3 template printing with DOCX, XLSX, or PPTX templates and business data, including record/list output, attachments, QR codes, or PDF conversion; ordinary browser page printing is outside this workflow.
npx skills add https://github.com/nocobase/nocobase --skill nocobase-app-plugin-template-print
Implement or debug an App-owned NocoBase 3 template-printing workflow that produces an authorized document or PDF from a DOCX, XLSX, or PPTX template and business data, with the selected feature branches verified in the intended viewer and deployment.
This package provides implementation guidance only. It exports no rendering service, route, database collection, or Client/Server plugin. The App or business plugin owns the feature you implement. There is no pre-existing template-print API to call after installing this package.
| Input | Required | Default | Validation | Clarification Question |
| -------------------- | ---------------------------------- | ------------------------------------------------------------------------------- | ---------------------------------------------------------------------------- | ----------------------------------------------------------------------------- |
| action | yes | implement for a new feature; debug when a concrete failure is reported | enum: implement, debug | "Should I implement the workflow or diagnose an existing one?" |
| format | yes | use the supplied template extension; otherwise start with docx | enum: docx, xlsx, pptx; must match the actual template | "Which template format must be supported?" |
| output | no | same-format document download; add pdf only when requested | enum: document, pdf, printable-pdf | "Should the result be the source format, a PDF download, or a printable PDF?" |
| data-scope | yes when business data is rendered | one record for a record request; otherwise ask before selecting a broader scope | enum: record, selected, current-page, all-filtered; explicit maximum | "Which records may be printed?" |
| template-ownership | no | fixed App-owned asset unless managed uploads are requested | enum: fixed-asset, managed-upload; separate manage/use permissions | "Is the template fixed by the App or managed by users?" |
| locale-timezone | no | the App's current locale and timezone | validate against the App contract before querying or formatting | "Which locale and timezone should labels and dates use?" |
The supplied template, App instructions, installed package versions, and existing business code are authoritative for details not listed here. If the user says "you decide", use a fixed DOCX asset, one representative record with its required child data, same-format document output, and one authorized download. Do not add XLSX, PPTX, PDF conversion, or managed template uploads in the same first slice unless requested.
Resolve the target App, actual template format, output mode, data scope, template ownership, authorization boundary, and converter prerequisites before adding or changing an endpoint, data query, schema, dependency, or file-processing path. If a required input is missing or ambiguous, stop and ask; do not mutate code or storage before the answer. Max clarification rounds: 2. Max questions per round: 3.
Inspect the target App's instructions, installed versions, server composition, business data access, file storage, and action UI. Use its available nocobase-app-development Skill for v3 composition; use the installed authentication, authorization, and file Skills when integrating those capabilities. If a referenced Skill is absent, inspect the installed package's public exports and existing App usage before choosing an API.
Determine these from the request, existing code, and supplied template; ask only about choices that materially change the result:
Read implementation.md before adding an endpoint or data query. Start with one requested format, a representative template, authorized data, and a downloadable result. Add template management or PDF conversion only when the requested workflow needs it.
| Reference | Load when | Purpose |
| ------------------------------------------------------- | ---------------------------------------------------------------------------- | ------------------------------------------------------------------------------------- |
| implementation.md | adding an endpoint, query, template store, or download flow | v3 ownership, authorization, data contract, uploads, and deployment boundaries |
| rendering.md | selecting dependencies, Carbone APIs, tags, or renderer adapters | renderer contract, data examples, and format-specific processing boundaries |
| office-processing.md | implementing images, attachments, QR codes, XLSX cell images, or PDF spacing | authorized image resolution, Office package processing, and conversion cleanup |
| verification.md | verifying an implemented branch | fixture matrix, permission cases, deployment checks, and structural/visual inspection |
High-impact actions include accepting or replacing managed templates, writing rendered files, invoking a converter, and adding a route or query that accesses private data.
Before any high-impact action, validate the template identity, actual file structure, authorized data scope, output limits, storage boundary, and converter configuration. Do not accept caller-provided filesystem paths or arbitrary renderer options. Use only documented renderer APIs and reject unsupported formats or processing branches explicitly.
For managed uploads, retain the previous revision until the replacement is validated; remove failed temporary files and read back the stored metadata and content identity after each write. For rendering and conversion, use per-job temporary paths and clean them up on success, failure, cancellation, and timeout without masking the primary error. If implementation scope changes materially, stop and ask for confirmation before proceeding.
Rollback guidance: restore the previous template revision, remove only the failed upload or job temporary files, and revert the route/query/dependency changes made for the current task. Never delete an existing user template or private output without an explicit target and confirmation.
Take nocobase/nocobase-app-plugin-template-print from the repository into ~/.claude/skills for personal
use, or into .claude/skills inside a project.
The agent identifies a skill by the name field in its header. Two skills with the
same name cannot sit side by side — one of them will be ignored.