X Enterprises
fastify-x-signwell

xsignwell.templates.get

Fetch a single SignWell template by ID.

xsignwell.templates.get

Fetch a single template by its SignWell ID. Returns the full template object including name, fields, and recipient placeholders.

Signature

fastify.xsignwell.templates.get(templateId: string): Promise<Object>

Params

NameTypeRequiredDescription
templateIdstringYesThe SignWell template ID.

Returns

The full template object including id, name, fields[], and recipients[].

Throws

  • [xSignwell] templates.get: templateId (string) is required — if templateId is missing.
  • Re-throws SignWell API errors with statusCode and signwellError properties.

Examples

Fetch a template by ID

const template = await fastify.xsignwell.templates.get("tmpl_abc123");
console.log(template.name); // "NDA Template"
console.log(template.recipients); // [{ id: "signer_1", name: "Customer" }]

See also


AI Context

package: "@xenterprises/fastify-xsignwell"
method: fastify.xsignwell.templates.get(templateId)
use-when: Fetch a single SignWell template by ID to inspect its name, fields, and recipients
returns: Full template object with id, name, fields[], recipients[]
Copyright © 2026