Print receipts automatically from a webhook
When an order or payment event fires, print a receipt with no human in the loop. Receive the webhook in your backend, forward the data to ReceiptKit's print API, and a designed receipt prints on your thermal printer instantly.
Webhook in, receipt out
Most platforms — storefronts, payment processors, booking systems, your own POS — can send a webhook when something happens. Printing a receipt from that event is a two-step flow: your backend receives the webhook, then calls ReceiptKit's print API with the fields your template needs.
Because rendering happens on a bridge next to the printer, your handler only sends a small JSON payload — the receipt prints the instant it arrives, and the design lives in a template you can change any time without redeploying code.
A print in your webhook handler
Receive the event, map the fields, call the print API. Here it is as a serverless route handler.
1// Example: a webhook handler that prints a receipt on every new order. 2export async function POST(req) { 3 const order = await req.json(); 4 5 await fetch('https://www.receiptkit.io/api/bridge/print', { 6 method: 'POST', 7 headers: { 8 'Authorization': 'Bearer rk_live_xxxxx', 9 'Content-Type': 'application/json'10 },11 body: JSON.stringify({12 printerEndpoint: 'tcp:00:11:62:32:5a:2a',13 templateId: 'your-template-id',14 data: {15 orderNumber: order.number,16 items: order.line_items,17 total: order.total18 }19 })20 });2122 return new Response('ok');23}Printing at high volume? Skip the HTTP hop.
Webhooks are server-side, so the HTTP call above is the natural fit. If you're printing at high volume, use the SDK's receiptkit/server module to publish over a shared MQTT connection — trimming the HTTP round-trip for even lower latency. Read the SDK docs →
Any event that fires a webhook
E-commerce orders
Fire on Shopify, WooCommerce, or any store's order webhook to auto-print a packing slip or receipt the moment a sale comes in.
Payment events
Print a receipt when a Stripe payment succeeds — hook payment_intent.succeeded or checkout.session.completed and print in the handler.
Kitchen & order tickets
Turn order-created events from a custom POS into instant kitchen tickets on a thermal printer in the back of house.
Bookings & confirmations
Print a confirmation slip when a reservation, appointment, or ticket is booked — any event that can send a webhook can print.
Built for hands-off printing
No human in the loop
The webhook fires, your handler calls the print API, and the receipt prints. No dashboard clicks, no manual export — fully automatic.
Works with any webhook source
If a platform can POST JSON to a URL, you can print from it. Receive the webhook in your backend, map the fields, and forward to ReceiptKit.
Map fields once
Design a template with named fields, then map each webhook's payload to those fields in your handler. Change the design later without touching code.
Proven in production
ReceiptKit prints thousands of real receipts from a live POS at Family Hardware. Read the case study →
Common questions
How do I print a receipt from a webhook?
Point the webhook at a small handler in your backend (a serverless function or an API route). In the handler, read the event payload, map the fields you need, and POST them to ReceiptKit's print API with your API key. The receipt prints instantly.
Can I call ReceiptKit directly from the source platform's webhook?
Usually you'll want a thin handler in between so you can verify the webhook signature and reshape the payload to match your template's fields. That handler is just a few lines — receive the event, then call the print API.
Does this work with Shopify, Stripe, and WooCommerce?
Yes. Any platform that sends webhooks works — Shopify order webhooks, Stripe payment events, WooCommerce order hooks, or your own custom events. You control which event triggers the print in your handler.
How fast does it print after the webhook fires?
Sub-second once your handler makes the call. ReceiptKit pushes the job over MQTT to a bridge on the printer's network, which renders locally and prints immediately.
Do I need to verify the webhook first?
You should verify the source platform's webhook signature in your handler before printing, so only genuine events trigger a receipt. Then forward the validated data to the print API.
Wire up your first webhook print
Design a template, install the free bridge, and print from any webhook with a single API call.