2026
TikTok Auction Packer
A Chrome extension that turns a TikTok Shop packing-list PDF into a 4×6 thermal label with the real product name beside each sale number.
JavaScript, Chrome Extension (MV3), PDF.js, Canvas, Google Sheets, chrome.storage
TikTok Shop packing list
Sunday live · 4×6 · 203 DPI
| Sale | Printed | Looked up |
|---|---|---|
| 62 | SCREEN | S1: 500ML DESIRE |
| 63 | SCREEN 2 | S2: FAIRY 2.6L |
| 64 | SCREEN | S1: 150ML DIFFUSER |
| 67 | SCREEN 2 | S2: (no match) |
The problem
Sellers who run TikTok Live auctions get a packing-list PDF that only shows the buyer's Seller SKU (the auction sale number), not the product they won. Pickers are staring at 62 and guessing, or flipping between the PDF and a spreadsheet.
How it works
A Manifest V3 extension intercepts the packing-list PDF, renders it in its own viewer, and parses the table out of PDF.js text items. Each row is assigned to Live 1 or Live 2 from the title sitting in that row's vertical band. The sale number is looked up in the matching published Google Sheet CSV, then the product name is drawn beside the original row with an S1: or S2: prefix before the page is flattened for a thermal printer.
What it does
PDF intercept and viewer
A service worker watches TikTok packing-list URLs, including signed S3 links, and redirects the tab to a standalone viewer that renders the PDF at 4×6 inches, 203 DPI.
Row parsing
pdfParser.js reads the packing-list table from raw PDF text items. Row boundaries are the midpoint between consecutive sale-number Y positions, so the title stays bound to the correct sale even when baselines sit on different lines.
Live 1 vs Live 2 lookup
TikTok prints titles like SUNDAY LIVE – AS SEEN ON SCREEN or SCREEN 2. That string picks the sheet. Sale number goes to column A; the product name comes back from column B.
Thermal print path
Print output is rendered at 2×, dithered to black and white (luminance threshold 165), then downsampled to 812×1218 for a TSC 4×6 label. A leftover on-page overlay remains as fallback if the redirect does not fire.
Choices
Sheets stay the source of truth
Auction catalogues already live in Google Sheets. The extension fetches published CSV URLs and keeps those links in chrome.storage.local. No backend, no account sync.
Prefix every overlay
S1: and S2: are printed on purpose. If a row is routed to the wrong live, the picker sees it on the label instead of packing the wrong SKU.
Nothing leaves the browser
No analytics, no remote code. The only network call is the CSV fetch to Google's published sheet URL. PDF.js is bundled in the extension.
Still to do
- Tighter parser tests against more packing-list layouts
- Optional Chrome Web Store listing once the viewer is stable across Seller Center changes