@spree/docs 0.1.218 → 0.1.220

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -9721,6 +9721,8 @@ paths:
9721
9721
  height:
9722
9722
  width:
9723
9723
  depth:
9724
+ weight_unit: lb
9725
+ dimensions_unit: in
9724
9726
  minimum_order_quantity: 1
9725
9727
  order_multiple: 1
9726
9728
  purchase_unit: unit
@@ -15133,6 +15135,10 @@ components:
15133
15135
  depth:
15134
15136
  type: number
15135
15137
  nullable: true
15138
+ weight_unit:
15139
+ type: string
15140
+ dimensions_unit:
15141
+ type: string
15136
15142
  minimum_order_quantity:
15137
15143
  type: number
15138
15144
  order_multiple:
@@ -15188,6 +15194,8 @@ components:
15188
15194
  - height
15189
15195
  - width
15190
15196
  - depth
15197
+ - weight_unit
15198
+ - dimensions_unit
15191
15199
  - minimum_order_quantity
15192
15200
  - order_multiple
15193
15201
  - purchase_unit
@@ -118,6 +118,77 @@ A method is priced one of two ways, and the choice is per method:
118
118
  A carrier-priced method returns one option per service, so a single "Carrier
119
119
  rates" method can offer Ground, 2-Day and Overnight as separate choices.
120
120
 
121
+ ## Packaging
122
+
123
+ Every quote needs to know what the goods travel in. A carrier charges by
124
+ dimensional weight as well as actual weight, so the size of the box matters to
125
+ the price, and the empty box's own weight has to be added to what it holds —
126
+ otherwise every parcel is quoted light.
127
+
128
+ Package types are that vocabulary: the box parcels ship in, and for wholesale,
129
+ the cartons products are packed into and the pallets or containers an order
130
+ leaves on.
131
+
132
+ ```typescript Admin SDK
133
+ await adminClient.packageTypes.create({
134
+ name: 'Standard mailer',
135
+ kind: 'box',
136
+ length: 30, width: 20, height: 15, dimensions_unit: 'cm',
137
+ weight: 0.4, weight_unit: 'kg',
138
+ default: true,
139
+ })
140
+ ```
141
+
142
+ One row is marked `default`, and that is the box quotes are built on. Marking
143
+ another one default demotes the first, so there is never more than one.
144
+
145
+ Measurements are optional individually, which is how a merchant records what
146
+ they know. A box with no dimensions still contributes its weight; a box with
147
+ nothing measured contributes nothing, and dimensional pricing has nothing to
148
+ work from.
149
+
150
+ > **NOTE:** Deleting the default box is refused, and so is switching its flag off when
151
+ > nothing else would take it. Both would leave quotes with no size and no tare,
152
+ > which under-prices bulky parcels silently rather than failing.
153
+
154
+ ### On a marketplace
155
+
156
+ A seller packs their own goods, in their own boxes, from their own warehouse.
157
+ So packaging has an owner: rows created by the operator are the marketplace's,
158
+ and each seller has their own.
159
+
160
+ A parcel is quoted with the box belonging to whoever's warehouse it left,
161
+ falling back to the marketplace's when a seller has not recorded one. Sellers
162
+ manage theirs through the Seller API, and can also pack products into the
163
+ marketplace's cartons — those they read but cannot change.
164
+
165
+ ```typescript Seller SDK
166
+ // Their own packaging — what the seller panel's settings page lists.
167
+ const { data: mine } = await sellerClient.packageTypes.list({ owner: 'mine' })
168
+
169
+ // Their own plus the marketplace's, which is what a carton picker wants.
170
+ const { data: available } = await sellerClient.packageTypes.list()
171
+
172
+ available.forEach((row) => {
173
+ row.name
174
+ row.editable // false on the marketplace's own rows
175
+ row.default // this seller's default box
176
+ })
177
+ ```
178
+
179
+ A seller's settings page asks for `owner: 'mine'`. A list mixing both owners
180
+ reads as "packaging is configured" while the seller has recorded nothing of
181
+ their own, which makes the shipping-box requirement look broken rather than
182
+ outstanding. Where a seller genuinely benefits from the marketplace's rows —
183
+ choosing the carton a product is packed into — the unfiltered list is what
184
+ the picker reads.
185
+
186
+ Because the fallback keeps checkout working, a seller who never opens the page
187
+ would quietly ship with someone else's measurements. The **shipping box**
188
+ onboarding requirement is what asks them for it: it is satisfied by a default
189
+ box of their own with all three dimensions and a weight recorded. See
190
+ [sellers](sellers.md#onboarding-requirements).
191
+
121
192
  ## Related
122
193
 
123
194
  - [Fulfillments](fulfillments.md) — what happens to the parcel afterwards
@@ -85,7 +85,7 @@ Requirements come in three flavours, which is what lets one mechanism cover very
85
85
  | **Attested** | The seller confirms something — accepting terms |
86
86
  | **Verified** | The seller submits something and the marketplace rules on it — a document, an operator review |
87
87
 
88
- Shipped out of the box: accepting terms, completing the profile, a billing address, a returns address, and a minimum number of products. Also available are generic document upload, attestation, operator review, and required custom fields.
88
+ Shipped out of the box: accepting terms, completing the profile, a billing address, a returns address, a way to ship, the box they ship in, and a minimum number of products. Also available are generic document upload, attestation, operator review, and required custom fields.
89
89
 
90
90
  A seller sees their checklist and its progress:
91
91
 
@@ -197,7 +197,7 @@ await sellerClient.orders.fulfillments.fulfill(orderId, fulfillmentId, {
197
197
  })
198
198
  ```
199
199
 
200
- Sellers can manage their profile, invite their own team, list and submit products, see and fulfil their orders, manage their stock locations, and work through onboarding. They cannot see other sellers, the marketplace's own catalog, or anything belonging to the store at large.
200
+ Sellers can manage their profile, invite their own team, list and submit products, see and fulfil their orders, manage their stock locations, delivery methods and packaging, and work through onboarding. They cannot see other sellers, the marketplace's own catalog, or anything belonging to the store at large.
201
201
 
202
202
  What a seller's staff may do is governed by [roles](staff-roles.md) owned by the seller — the same permission system as the back office, with a narrower set of keys, so a seller role can never reach store settings.
203
203
 
@@ -206,5 +206,6 @@ What a seller's staff may do is governed by [roles](staff-roles.md) owned by the
206
206
  - [Commissions](commissions.md) — rates, rules, and what the marketplace charges
207
207
  - [Products](products.md#seller-submissions) — the listing review flow
208
208
  - [Orders](orders.md) — orders and their statuses
209
+ - [Delivery setup](delivery-setup.md#on-a-marketplace) — how a seller's goods ship, and what they ship in
209
210
  - [Staff & Roles](staff-roles.md) — how seller teams are governed
210
211
  - [Seller API](../../api-reference/seller-api/introduction.md) — the full endpoint reference
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@spree/docs",
3
- "version": "0.1.218",
3
+ "version": "0.1.220",
4
4
  "description": "Spree Commerce developer documentation for AI agents and local reference",
5
5
  "type": "module",
6
6
  "license": "CC-BY-4.0",