# Shippit Shipping for GoCommerce — Open-Source Module

> Book Shippit deliveries from a GoCommerce order: API key, service band, authority to leave, kilograms and metres, the seven-day label link, and the limits.

- Canonical: https://kitcommerce.store/integrations/fulfill-shippit/
- Last updated: 2026-09-25

---

Shipping

## Shippit shipping for GoCommerce

A Go package that books an order with Shippit when an operator ships it, then fetches the label. You pick a service band; Shippit picks the courier, and the module records whichever one took the parcel.

- **Shipping** module
- **7** settings
- **9** tests
- **ext/fulfill-shippit**

### What it does

The module registers “shippit” as a fulfillment provider. An operator ships through the engine’s own POST /api/admin/create-fulfillment with the provider shippit — the engine keeps the order’s state and its events, and the module only talks to Shippit.

Shippit books and labels in two calls: POST /orders comes back with a tracking number, and GET /orders/{tracking}/label with a pre-signed URL to print. The booking is what matters — once it succeeds, in the package’s words, the parcel is Shippit’s problem — so a label that cannot be fetched is logged and the shipment still stands.

In the admin it describes itself as “Shippit’s carrier allocation, Australia and New Zealand: pick a service band and Shippit picks the courier.” The band is standard, express, priority, or plain_label for a store that books its own carrier and only wants the paperwork. No SDK: REST over Go’s standard library.

### Configuration

Two settings are required: the API key and a default service band. Set them in Config from your own main(), or leave Config empty and fill them in under Settings › Shipping providers.

*Shippit module settings — 7 settings, 2 required*

| Setting | Environment variable | Required | What it does |
| --- | --- | --- | --- |
| `APIKey` API key | `SHIPPIT_API_KEY` | Yes | A Shippit API key, sent as a bearer token. Staging takes a different key. |
| `CourierType` Service band | — | Yes | standard, express, priority or plain_label. Meta courier_type overrides it for one parcel. |
| `AuthorityToLeave` Authority to leave | — | No | Whether a courier may leave the parcel at the door when nobody answers. Off by default: it is the shopper’s call, and a storefront that asks passes the answer per shipment with meta authority_to_leave. |
| `DefaultWeightGrams` Default weight (grams) | — | No | Per unit, for a parcel holding a variant with no weight recorded. 500 by default. |
| `DefaultLengthMM, DefaultWidthMM, DefaultHeightMM` | — | No | The box sent when the engine has no unambiguous size, which is any parcel holding more than one unit. 150 × 150 × 100 mm by default. Go only. |
| `BaseURL` API base URL | — | No | Overrides https://app.shippit.com/api/3. Staging is https://app.staging.shippit.com/api/3, with its own key. |
| `Client` | — | No | Replaces the HTTP client, which otherwise times out after 30 seconds. Go only; not in the panel. |

The module reads its Config struct, not the environment. The variable names are the ones the package’s own example or the reference binary uses; in your own `main()` you choose where each value comes from. Where a setting has a panel label, the admin’s settings drawer can hold it too, and a value typed there wins over Config.

### Setting it up

1. **Get an API key** — In Shippit, create an API key — a staging key if you are trying it against Shippit’s staging host — and decide the service band to book by default.
2. **Install the module** — Import it and pass shippit.New to gocommerce.New, as below — or run the reference binary with -carriers, which installs every carrier module idle.
3. **Fill in the settings** — Key and service band, in Config or under Settings › Shipping providers, and authority to leave if the store’s default is yes. A value typed into the panel counts on the next shipment.
4. **Ship an order** — POST /api/admin/create-fulfillment with the order id and the provider shippit. The engine records the tracking number and label URL and moves the order to shipped, or to partial.

main.go

```
import (
	"os"

	"github.com/itswadesh/gocommerce/core"
	shippit "github.com/itswadesh/gocommerce/ext/fulfill-shippit"
)

app, err := gocommerce.New(cfg,
	shippit.New(shippit.Config{
		APIKey:      os.Getenv("SHIPPIT_API_KEY"),
		CourierType: "standard",
	}),
)
```

The package doc’s own example, with its imports; cfg is your gocommerce.Config. With an empty shippit.Config the module installs idle and waits for the panel. Import path `github.com/itswadesh/gocommerce/ext/fulfill-shippit`.

### How it works

- **Book, then fetch the label**

  The booking gives the tracking number; the label comes from a second call. A booking with no tracking number is an error. A label that cannot be fetched is logged, and the shipment is recorded without one.

- **A seven-day label link**

  Shippit’s label URL is pre-signed and expires after seven days. It is stored as it comes; the package says a store that needs it later fetches it again from Shippit rather than expecting the engine to hold a live link.

- **Kilograms and metres**

  Shippit reads kilograms and metres, so grams and millimetres are both divided by a thousand. A typical parcel’s sides are numbers below one — 0.305, not 30.5 — which the package calls worth reading twice.

- **One parcel, whatever is in it**

  The booking says one parcel. The engine has already resolved the lines, and telling Shippit three would book three boxes.

- **Per-parcel options**

  Meta can override courier_type, pass the shopper’s authority_to_leave, add delivery_instructions, or name a carrier with courier_allocation for a parcel already promised to one.

- **Carrier from the allocation**

  The carrier code is read from the courier Shippit allocated — eParcel and StarTrack track as Australia Post; FedEx, DHL, TNT, Aramex and UPS are recognised — so the tracking number gets the right link.

### What it does not do

Read these before an order depends on it. No store is known to run GoCommerce in production yet, so these come from the code, not from anyone’s experience.

- **No tracking updates** — No webhook and no stored state: delivery events in Shippit do not reach the order. Marking it delivered is still the operator’s job.
- **No cancel call** — There is no call to cancel a booking. Deleting the fulfillment in GoCommerce does not touch the order in Shippit.
- **The label link expires** — After seven days the stored label URL no longer works; the label has to be fetched again from Shippit.
- **A missing label is only logged** — If the label fetch fails, the shipment is recorded with no label URL and the failure is in the application log; the label then has to be printed from Shippit.
- **No contents sent** — The booking carries the parcel’s weight and size, the address and the order number — not the items in it or their values.
- **A guessed box for several items** — For anything but a single unit, the size sent is the configured default, not a measurement. The engine does not pack cartons.

FAQ

### Questions about the Shippit module

**Can I choose the courier?**

Shippit chooses within the service band by default. For a parcel an operator has already promised to one carrier, meta courier_allocation names it, and meta courier_type changes the band for that parcel.

**Why are my parcel’s sides smaller than one?**

Because Shippit reads metres. The engine keeps millimetres and the module divides by a thousand, so a 305 mm box goes as 0.305. Weight goes the same way, grams to kilograms.

**Can I use it without writing Go?**

Yes. The reference binary’s -carriers flag installs every carrier module with an empty Config. Switch Shippit on under Settings › Shipping providers and fill in the key and service band there.

**Is this a Shippit partnership?**

No. The module calls Shippit’s public API with a key you supply. Shippit does not endorse GoCommerce, and no store is known to run this module in production yet.

### Source

Everything on this page is read from [`ext/fulfill-shippit`](https://github.com/itswadesh/gocommerce/tree/main/ext/fulfill-shippit) in the GoCommerce repository, MIT licensed. When this page and the code disagree, the code is right and this page is out of date.Shippit is a trademark of its owner; this module talks to its public API and implies no endorsement. See [trademarks](https://kitcommerce.store/about/#trademarks).

- [ext/fulfill-shippit on GitHub](https://github.com/itswadesh/gocommerce/tree/main/ext/fulfill-shippit)
- [Shippit](https://www.shippit.com)
- [All GoCommerce modules](https://kitcommerce.store/integrations/)

### Try it against a store of your own

The one-command stack gives you GoCommerce’s API and admin on your own machine in minutes. Add this module to it and try it on test orders before a real one depends on it.

[Deploy in minutes](https://kitcommerce.store/#one-command) · [Read the module](https://github.com/itswadesh/gocommerce/tree/main/ext/fulfill-shippit) · [All integrations](https://kitcommerce.store/integrations/)
