Skip to main content

Glossary

Shared vocabulary across the SDK, the API, and these docs.

  • Channel — a registered storefront hostname; the unit of partner identity, branding, and commission. Passed to Treatink.init({ channel }). GET /v1/channel returns its metadata.
  • Publishable keypk_test_ / pk_live_. Browser-safe; catalog + assets. The only key type the browser bundle may use.
  • Secret keysk_test_ / sk_live_. Server-only; orders, shipments, webhooks. Never in the browser.
  • Cutout / template / frame — the same thing: a label design, a transparent PNG whose transparency reveals the photo beneath it. SDK public term: template (tk.templates), identified by a cutout-label id (cut_…).
  • Cutout mask — the frame PNG's own alpha channel. It is the mask, applied at draw time. No separate vector mask is decoded at runtime.
  • Label zone — normalized {x,y,width,height} marking where the printed label sits on a product mockup image. Used for display placement only; it does not clamp editing.
  • Canvas — the fixed 900 × 1200 editing/print space. Editing happens here; the print composite is this canvas.
  • Transform — the photo's { x, y, scale, rotation } in canvas space. Self-contained context for print re-render.
  • Composite — the rendered photo + cutout overlay + text. Print composite = the 900 × 1200 canvas (the printed file). Display composite = the preview for cart/thumbnail (previewUrl) — the product mockup with the label composited into the label zone.
  • Personalization text — the on-label text (typically the pet's name). SDK field personalizationText; per-cutout vertical placement via pet_name_positiondefault | top | upper | bottom.
  • Asset — the API's uploaded file object (POST /v1/assets, role = source / rendered). Referenced by order line items (source_asset_id, rendered_asset_id).
  • Draft — the SDK's locally persisted reference record for a saved personalization (localStorage, no image bytes).
  • Fixtures mode — the SDK's bundled, contract-faithful backend simulation. The default mode; lets you integrate against a bundled demo catalog with no backend or keys.
  • Transport — the single seam between the SDK and any backend; HttpTransport (live) or FixtureTransport (fixtures). See Architecture.
  • Low-res flag — boolean warning when the photo is upscaled beyond ~105% of native onto the print canvas. Warns, does not block.
  • Session — a concept from an earlier API design that does not exist in the SDK: the backend is asset-based, so there is no tk.sessions namespace. The designer's save orchestrates assets directly.