Skip to content
Back to search

bpost-label

SkillWorks with Claude CodeGitHub

Build bpost parcel orders (guest or signed-in on parcel.bpost.be) from a Shopify order or an address pasted in chat, stop for review, then hand back the bpost basket link or a MultiSafepay checkout link. Use when the user asks for bpost labels/orders, to ship a Shopify order with bpost, to quote bpost parcel prices, or to turn an address into a payable bpost cart without paying inside the agent.

Safety scan

A static text scan, not a guarantee. Select the badge to see what was scanned and every finding.

Checked today
Badge for your README
findsafeskills safety rating

Markdown

[![findsafeskills safety rating](/api/listings/c1sc0c0--starterslabo-bpost/badge.svg)](/listings/c1sc0c0--starterslabo-bpost)

HTML

<a href="/listings/c1sc0c0--starterslabo-bpost"><img src="/api/listings/c1sc0c0--starterslabo-bpost/badge.svg" alt="findsafeskills safety rating" /></a>

Install

i

Install instructions from the README

As written by the repo's author. findsafeskills has not verified these steps.

Clone this repo **as the skill folder** (`SKILL.md` at the root):

# Cursor — this project
git clone https://github.com/c1sc0c0/starterslabo-bpost.git .cursor/skills/starterslabo-bpost

# Cursor — all projects
git clone https://github.com/c1sc0c0/starterslabo-bpost.git ~/.cursor/skills/starterslabo-bpost

# Claude Code — this project
git clone https://github.com/c1sc0c0/starterslabo-bpost.git .claude/skills/starterslabo-bpost

Start a new agent chat so the skill is picked up. The skill id in `SKILL.md` is **`bpost-label`** (the repo is `starterslabo-bpost`, following the other skill repos). No packaging step, no third-party Python packages — stdlib only, Python 3.10+.

cd .cursor/skills/starterslabo-bpost     # or ~/.cursor/skills/starterslabo-bpost
cp sender.example.yaml sender.yaml
$EDITOR sender.yaml                     # the return address printed on every label

Credentials for the signed-in mode live in the **macOS Keychain**:

security add-generic-password -s scout_bpost -a email -w 'you@example.com' -U
security add-generic-password -s scout_bpost -a password -w 'your-bpost-password' -U

python3 .cursor/skills/starterslabo-bpost/scripts/bpost_order.py login     # signs in, stores cookies
python3 .cursor/skills/starterslabo-bpost/scripts/bpost_order.py whoami    # check it is still valid

`login` writes `.bpost-session` (mode 600, gitignored). On first login it also finishes bpost's account-type registration as **private**, which removes the "Voor mezelf / Voor mijn bedrijf" modal that otherwise covers the cart.

Skip all of that and everything still works as a guest — you just lose the plain basket URL.

What was scanned

The files the safety scan read, as written by the repository's author and shown as plain text. Lines with a finding are marked.

SKILL.md · Manifest · 133 lines
  1. ---
  2. name: bpost-label
  3. description: >-
  4. Build bpost parcel orders (guest or signed-in on parcel.bpost.be) from a
  5. Shopify order or an address pasted in chat, stop for review, then
  6. hand back the bpost basket link or a MultiSafepay checkout link. Use when the
  7. user asks for bpost labels/orders, to ship a Shopify order with bpost, to
  8. quote bpost parcel prices, or to turn an address into a payable bpost cart
  9. without paying inside the agent.
  10. ---
  11. # bpost — orders from a Shopify order or a pasted address
  12. Unofficial. Not affiliated with bpost. Chrome/agent side: no bpost login is required for the guest
  13. flow; the signed-in flow uses Keychain credentials.
  14. **The skill never pays.** It builds the cart, stops, and hands the human a bpost basket link (signed in)
  15. or a hosted checkout link (on request).
  16. ## Workflow
  17. ```
  18. Progress:
  19. - [ ] 1. Get the shipment source: Shopify order number, or the address pasted in chat
  20. - [ ] 2. Quote (no writes)
  21. - [ ] 3. Dry run (real draft, real price, deleted again; guest order, cart untouched)
  22. - [ ] 4. Create -> prints REVIEW, nothing payable
  23. - [ ] 5. Hand over https://parcel.bpost.be/nl/basket (signed in) or a seeded tab (guest)
  24. - [ ] 6. `pay <id>` only if a portable link is explicitly wanted
  25. ```
  26. **Step 5 is the default handoff, not step 6.** With a session the order sits on the account's
  27. `order-in-progress`, so the plain basket URL works on any device. Only mint a MultiSafepay link when the
  28. human asks for a URL (phone, another device, later).
  29. ## Addresses pasted in chat
  30. Pass the text through `--to`, verbatim, commas or newlines, and add the weight:
  31. ```bash
  32. python3 scripts/bpost_order.py \
  33. --to "Jane Doe, Beispielweg 5, 67655 Kaiserslautern, Germany" --weight 9.52
  34. ```
  35. The parser takes the postcode line as zip+city, the line with a house number as street (+ `bus`/`box`),
  36. matches the country name against bpost's catalog (nl/en/fr/de), and treats the remainder as the name.
  37. Belgian addresses get canonicalised via bpost's proofing API (`--no-normalize` to skip). If the paste is
  38. ambiguous, echo the parsed plan back to the human before creating anything.
  39. Ask for anything missing: weight (required), delivery type (defaults to pickup point in BE), and the
  40. email for tracking.
  41. ## Shopify orders
  42. ```bash
  43. python3 scripts/bpost_order.py --shopify 1002 --split line
  44. ```
  45. `--split line` = one parcel per line item (matches one label per carton), `--split single` = whole order
  46. in one parcel. Quote both when the order has several cartons; the gap is real (2 cartons to DE: €33.00
  47. vs €42.20). Weight comes from the line items, so never ask for it.
  48. ## Commands
  49. | Command | Effect |
  50. |---|---|
  51. | `create` (default) | build the order, print REVIEW, **nothing payable** |
  52. | `create --quote` | price only, nothing created |
  53. | `create --dry-run` | draft order, real price, then deleted (forced to a guest order) |
  54. | `pay <orderId>` | mint the hosted checkout link |
  55. | `open <orderId>` | write a printable HTML mirror of the basket |
  56. | `review <orderId>` | read-only re-print |
  57. | `login` / `whoami` | Keychain sign-in / session check |
  58. ## Setup
  59. Once per machine:
  60. ```bash
  61. cp sender.example.yaml sender.yaml # return address
  62. security add-generic-password -s scout_bpost -a email -w 'you@example.com' -U
  63. security add-generic-password -s scout_bpost -a password -w '…' -U
  64. python3 scripts/bpost_order.py login
  65. ```
  66. `login` posts the bpost Ping form, follows the OAuth callback, stores `parcel.bpost.be` cookies in
  67. `.bpost-session` (mode 600, gitignored) and completes the account-type registration as **private** when
  68. bpost reports it incomplete — without that, a "Voor mezelf / Voor mijn bedrijf" modal covers the cart.
  69. If bpost asks for a one-time code, `login` prompts on stdin: run it in a terminal, not from the agent.
  70. Never print the password or the cookie. No `-w` echo, no `cat .bpost-session`, no logs.
  71. ## Delivery and weight
  72. | `--delivery` | Recipient gets | Notes |
  73. |---|---|---|
  74. | `pickup` (default) | pickup point near their postcode | domestic only |
  75. | `address` | home delivery | required for non-BE |
  76. | `locker` | bpost Bbox | domestic only |
  77. `--pickup "EIERMARKT"` or a point id narrows the choice; otherwise the nearest point is used and printed
  78. in the plan so the human can veto it before anything is created.
  79. WARRANTY (insurance, €1.55/parcel, cover up to €500) is **on by default for Belgian parcels** —
  80. `--no-insurance` opts out. bpost does not offer it abroad: international parcels are built uninsured
  81. with a note, and an explicit `--insurance` for a non-BE destination is an error.
  82. Weight bands: 0-2 / 2-5 / 5-10 / 10-20 / 20-30 kg (`DOM_*` domestic, `INT_*` international). Over 30 kg
  83. is rejected — split the parcel or use the `order-ship-mode` skill. The product line is the cheapest one
  84. that supports country + destination + band (`--product-line` overrides); international ECONOMY is often
  85. limited to 0-2 kg.
  86. ## Guardrails
  87. - Quote, then dry run, then create. A created order is a real (unpaid) bpost order that expires.
  88. - Do not mint a payment link unless the human asked (`pay` or `--pay-link`).
  89. - Never open, pay, shorten or re-host the payment link. Never drive the payment page.
  90. - If the cart is emptied in the browser, bpost keeps an empty `order-in-progress` that shadows new
  91. orders; `create` deletes it first — do not "fix" it by creating more orders.
  92. - Recipient email is the customer's; bpost sends them tracking from it.
  93. ## Troubleshooting
  94. | Symptom | Cause | Fix |
  95. |---|---|---|
  96. | cart empty in the browser | signed into another bpost account, or an older session | `whoami`, compare email; re-run `login` |
  97. | "Voor mezelf / Voor mijn bedrijf" modal | account registration incomplete | re-run `login` (it completes it as private) |
  98. | new order not in the cart | stale empty in-progress order | `create` clears it; otherwise delete the empty order |
  99. | `bpost login failed: We didn't recognize…` | wrong Keychain password | update the Keychain item |
  100. | session rejected, commands continue as guest | expired session | `python3 … login` |
  101. Files: [README.md](README.md) (usage) · [reference.md](reference.md) (API map) ·
  102. `sender.yaml` (return address) · `records/` (order JSON + review sheets).
README.md · README · 137 lines
  1. # bpost — parcel orders from a Shopify order or a pasted address
  2. Unofficial. Not affiliated with bpost.
  3. Builds a bpost **Verzendplatform** cart (guest or signed in), stops before payment, and gives you
  4. either the bpost basket link or a MultiSafepay checkout link. Written for a small Belgian shop's daily shipping.
  5. The skill **never pays** and never sees card data: the money step happens on bpost's own payment screen
  6. or on the hosted checkout page the payment link opens.
  7. ## Why it is built this way
  8. `parcel.bpost.be` is an Angular SPA. The cart lives server-side under an `orderId`, but the SPA only
  9. reads that id from `sessionStorage`. A guest cart therefore has **no shareable URL** — `/nl/basket`,
  10. `/nl/basket/<id>`, `/nl/order/<id>`, `/nl/checkout/<id>`, `/nl/pay?orderId=` all fail (verified).
  11. Signed in, the cart is the account's `order-in-progress`, so `https://parcel.bpost.be/nl/basket` just
  12. works — laptop, phone, anywhere. That is the recommended mode. Details and the full API map:
  13. [reference.md](reference.md).
  14. ## Install
  15. Clone this repo **as the skill folder** (`SKILL.md` at the root):
  16. ```bash
  17. # Cursor — this project
  18. git clone https://github.com/c1sc0c0/starterslabo-bpost.git .cursor/skills/starterslabo-bpost
  19. # Cursor — all projects
  20. git clone https://github.com/c1sc0c0/starterslabo-bpost.git ~/.cursor/skills/starterslabo-bpost
  21. # Claude Code — this project
  22. git clone https://github.com/c1sc0c0/starterslabo-bpost.git .claude/skills/starterslabo-bpost
  23. ```
  24. Start a new agent chat so the skill is picked up. The skill id in `SKILL.md` is **`bpost-label`** (the
  25. repo is `starterslabo-bpost`, following the other skill repos). No packaging step, no third-party Python
  26. packages — stdlib only, Python 3.10+.
  27. ```bash
  28. cd .cursor/skills/starterslabo-bpost # or ~/.cursor/skills/starterslabo-bpost
  29. cp sender.example.yaml sender.yaml
  30. $EDITOR sender.yaml # the return address printed on every label
  31. ```
  32. Credentials for the signed-in mode live in the **macOS Keychain**:
  33. ```bash
  34. security add-generic-password -s scout_bpost -a email -w 'you@example.com' -U
  35. security add-generic-password -s scout_bpost -a password -w 'your-bpost-password' -U
  36. python3 .cursor/skills/starterslabo-bpost/scripts/bpost_order.py login # signs in, stores cookies
  37. python3 .cursor/skills/starterslabo-bpost/scripts/bpost_order.py whoami # check it is still valid
  38. ```
  39. `login` writes `.bpost-session` (mode 600, gitignored). On first login it also finishes bpost's
  40. account-type registration as **private**, which removes the "Voor mezelf / Voor mijn bedrijf" modal
  41. that otherwise covers the cart.
  42. Skip all of that and everything still works as a guest — you just lose the plain basket URL.
  43. ## Quickstart
  44. ```bash
  45. B=.cursor/skills/starterslabo-bpost/scripts/bpost_order.py
  46. # price only (no order created)
  47. python3 $B --shopify 1002 --quote
  48. # create the order, stop before payment
  49. python3 $B --shopify 1002 --split line
  50. # same, from an address pasted straight out of a chat or a webshop
  51. python3 $B --to "Jane Doe, Beispielweg 5, 67655 Kaiserslautern, Germany" --weight 9.52
  52. # hand over a checkout link only when a URL is actually needed
  53. python3 $B pay orderId-…
  54. # review sheet (printable HTML mirror of the bpost basket)
  55. python3 $B open orderId-…
  56. ```
  57. ## Address paste
  58. Any of these work — commas, newlines, or both:
  59. ```
  60. Jane Doe
  61. Beispielweg 5
  62. 67655 Kaiserslautern
  63. Germany
  64. ```
  65. ```
  66. Jan Peeters, Voorbeeldstraat 51 bus 3, 2000 Antwerpen, België
  67. ```
  68. The parser finds the postcode line, the street + house number (including `bus`/`box`/`bte`), the country
  69. (full names in nl/en/fr/de, resolved against bpost's own country catalog), and treats what is left as
  70. the name. Belgian addresses are then canonicalised through bpost's address proofing API.
  71. Weight is required with `--to` (`--weight 9.52`, kg). Delivery type defaults to pickup point for
  72. Belgian addresses; use `--delivery address` or `--delivery locker`.
  73. Belgian parcels get bpost's WARRANTY cover **by default** (€1.55 per parcel, up to €500 of goods), because
  74. an uninsured parcel is the expensive mistake. `--no-insurance` opts out. bpost does not offer the option
  75. abroad, so international shipments are built uninsured with a one-line note; forcing `--insurance` there
  76. is an error rather than a silent no-op.
  77. ## Commands
  78. | Command | What it does |
  79. |---|---|
  80. | `--shopify 1002` | build from a Shopify order (`--split line` = parcel per carton, `--split single` = one parcel) |
  81. | `--to "<address>"` | build from a pasted address |
  82. | `--json file.json` | build from a batch file |
  83. | `--insurance` / `--no-insurance` | WARRANTY cover — **on by default for Belgian parcels**, +€1.55, up to €500; `--no-insurance` to opt out |
  84. | `--quote` | price only, nothing created |
  85. | `--dry-run` | real draft, real price, then deleted (guest order, never touches your cart) |
  86. | `pay <id>` | mint the MultiSafepay checkout link |
  87. | `open <id>` | write `review-<id>.html`, a printable mirror of the basket |
  88. | `review <id>` | print the order as bpost has it |
  89. | `login` / `whoami` | keychain sign-in, session check |
  90. Records land in `records/<orderId>.json` next to the skill (gitignored); override with
  91. `BPOST_OUTPUT_DIR` or `output_dir:` in `config.yaml`.
  92. ## Notes
  93. - Shopify access: set `SHOPIFY_SHOP` and `SHOPIFY_ADMIN_TOKEN`, or store an admin token in Keychain
  94. under `SHOPIFY_KEYCHAIN_SERVICE` (default `scout_shopify`, accounts `api` or `client_id` +
  95. `client_secret`).
  96. - `--guest` forces an anonymous cart, `--cookie` overrides the session for one run,
  97. `BPOST_SESSION` / `--keychain-service` point somewhere else.
  98. - Emptying the cart in the browser leaves an empty in-progress order behind; `create` clears it first,
  99. because bpost keeps pointing at it otherwise.
  100. - See [SKILL.md](SKILL.md) for the agent workflow and guardrails, [reference.md](reference.md) for the
  101. reverse-engineered API.

Ratings and comments

Sign in to rate this skill.

Sign in

Free to use. If it’s helped, pass it on.