Skip to content

Engine developer guide

An Engine is your app: whatever makes the image a customer wants printed, be it a template editor, a generative model, or a drawing tool. Pressline does not care how the image happens. It cares that you can answer three questions about a design and host the files you produce.

The division is deliberate and load-bearing. The Engine owns pixels; Pressline never renders, decodes or stores image bytes. It reads your file’s header to check it matches the Spec, then hands the provider your URL. That is why your files must stay reachable and unchanged for as long as an order might reference them.

  • The protocol — the three endpoints, the Printfile Spec Pressline derives from the provider, and the Spec Hash that identifies exactly one file. Start here.
  • Pre-rendering and hosting — why rendering at Finalize beats rendering at checkout, what Pressline validates when it fetches your file, and the rules your URLs must obey.
  • Rendering with @pressline/render — an optional helper that produces a file satisfying a Spec: exact dimensions, DPI stamped, sRGB declared, alpha per the rule. Works on Node and on Workers.
  • Conformance suite — run our tests against your Engine, in process, before you wire it to anything.
  • AI-assisted Engines — what changes when a render takes thirty seconds instead of thirty milliseconds.

If you want a worked example rather than a specification, the repository’s apps/sample-engine is a small, complete Engine built to be copied.