Template data model

Updated:

A saved design template: a blank product with artwork placed on it

View field support, webhooks, and list parameters for each integration on the Supported Integrations page.

FieldTypeRequiredDescription
idstringNo
created_atstring (date-time)No(ISO-8601 / YYYY-MM-DDTHH:MM:SSZ format)
updated_atstring (date-time)No(ISO-8601 / YYYY-MM-DDTHH:MM:SSZ format)
namestringNo
descriptionstringNo
product_idstringNoThe PrintingProduct ID of the blank product
preview_urlstringNoMockup or preview image URL
variant_identifiersstring[]NoIdentifiers of the product variants this template is available for
placementsPrintingPlacement[]NoPrint areas used by this template
placements[].codestringNoPlacement key used when attaching a print file (eg. front, back)
placements[].namestringNoDisplay name
placements[].techniquestringNoPrint technique or decoration method code for this placement (eg. dtg, embroidery)
placements[].widthnumberNoWidth of the print area, in unit
placements[].heightnumberNoHeight of the print area, in unit
placements[].unitenumNoUnit of width and height Values: PIXEL, MILLIMETER, CENTIMETER, INCH, OTHER
placements[].dpinumberNoPrint resolution for the given width and height
placements[].additional_price_amountnumberNoExtra cost when this placement is printed
metadataPrintingMetadata[]No
metadata[].idstringNoThe ID of the custom field definition (from the metadata/metadata endpoint).
metadata[].slugstringNoThe integration's API name (key) of an existing custom field.
metadata[].valueobjectNoThe field's value, typed by format.
metadata[].namespacestringNo
metadata[].formatenumNoThe data type of the custom field, which determines how value is formatted. Values: TEXT, NUMBER, DATE, BOOLEAN, FILE, TEXTAREA, SINGLE_SELECT, MULTIPLE_SELECT, MEASUREMENT, PRICE, YES_NO, CURRENCY, URL
metadata[].extra_dataobjectNo

TypeScript

TypeScript
export type PrintingTemplate = {
	id?: string;
	created_at?: string-time; // (ISO-8601 / YYYY-MM-DDTHH:MM:SSZ format)
	updated_at?: string-time; // (ISO-8601 / YYYY-MM-DDTHH:MM:SSZ format)
	name?: string;
	description?: string;
	product_id?: string; // The PrintingProduct ID of the blank product
	preview_url?: string; // Mockup or preview image URL
	variant_identifiers?: string[]; // Identifiers of the product variants this template is available for
	placements?: []; // Print areas used by this template
	metadata?: [];
	raw?: any; // Raw data from integration
} 

Zod

Zod
import { z } from 'zod';

export const ZodPrintingTemplate = z.object({
	id: z.string().optional(),
	created_at: z.string-time().optional().describe("(ISO-8601 / YYYY-MM-DDTHH:MM:SSZ format)"),
	updated_at: z.string-time().optional().describe("(ISO-8601 / YYYY-MM-DDTHH:MM:SSZ format)"),
	name: z.string().optional(),
	description: z.string().optional(),
	product_id: z.string().optional().describe("The PrintingProduct ID of the blank product"),
	preview_url: z.string().optional().describe("Mockup or preview image URL"),
	variant_identifiers: z.array().optional().describe("Identifiers of the product variants this template is available for"),
	placements: z.array().optional().describe("Print areas used by this template"),
	metadata: z.array().optional(),

});

Python

Python
import dataclasses

@dataclasses.dataclass
class PrintingTemplate:
	id: Optional[str]
	"""(ISO-8601 / YYYY-MM-DDTHH:MM:SSZ format)"""
	created_at: Optional[str]
	"""(ISO-8601 / YYYY-MM-DDTHH:MM:SSZ format)"""
	updated_at: Optional[str]
	name: Optional[str]
	description: Optional[str]
	"""The PrintingProduct ID of the blank product"""
	product_id: Optional[str]
	"""Mockup or preview image URL"""
	preview_url: Optional[str]
	"""Identifiers of the product variants this template is available for"""
	variant_identifiers: Optional[List[List[str]]]
	"""Print areas used by this template"""
	placements: Optional[PropertyPrintingTemplatePlacements]
	metadata: Optional[PropertyPrintingTemplateMetadata]
Are we missing anything? Let us know
Was this page helpful?