Google Sheets: table row to label
The ready-made Google Apps Script adds a ShipPickup menu to the sheet. Select order rows, and the script will buy labels and write status, tracking, order number, price, and label link back to those rows.
Downloadable files
- google-sheets.gs Google Apps Script: table row to label
What you’ll need
- Google Sheet and access to Apps Script, nothing else (no servers needed).
- A ShipPickup account and a live API key (
sk_live_…) with the permissions specified in the instructions. The key is created in the dashboard under “API” and stored in your system settings or environment variable.
Step-by-step instructions
- Download
google-sheets.gs. In the sheet, open “Extensions”, “Apps Script”, paste the file content replacing the default code, and save. - Reload the sheet page: the ShipPickup menu appears. Choose “Set API key” and paste your live API key. It will be saved in script properties and won’t appear in files or cells.
- Select “Create sender sheet” and fill out the Sender sheet: your sender address.
- In the first row of the orders sheet, enter headers (see example below). Order doesn’t matter, extra columns don’t interfere. The script will add result columns itself.
- Select order rows, choose “Buy labels for selected rows” and grant script access on first run.
Example
Sheet
name | line1 | city | state | postal_code | country | phone | email | weight_g | length_mm | width_mm | height_mm | description | quantity | unit_value_centsImportant to know
- Rows with a filled
order_idwon’t be purchased again. The “Refresh tracking for selected rows” option updates status and tracking. - Label links open if you are logged into your ShipPickup account. Columns
weight_g,length_mm,width_mm,height_mm, andunit_value_centsare integers.
Files contain no keys or passwords: all secrets are set by you in environment settings. Do not publish files with your values.